Use pip instead of python setup.py develop in CLI for plugin install

Apparently python setup.py develop tries to re-install all scripts
provided by plugins (maybe only under Windows?). Since that includes
OctoPrint's own executable, things will explode with an access denied
error there. Switching over to pip install -e . fixes that, and also
is more conform with the install approach the plugin will take in
production anyhow.
This commit is contained in:
Gina Häußge 2017-04-06 18:09:32 +02:00
parent 09d1025dfc
commit 41e9d96815

View file

@ -204,7 +204,7 @@ class OctoPrintDevelCommands(click.MultiCommand):
click.echo("This doesn't look like an OctoPrint plugin folder")
sys.exit(1)
self.command_caller.call([sys.executable, "setup.py", "develop"], cwd=path)
self.command_caller.call([sys.executable, "-m", "pip", "install", "-e", "."], cwd=path)
return command