<div dir="ltr"><div><div>Thanks Enrico that does seem to work on the file I have <br><br>using bin/python "%f" and %p as my working directory.<br><br></div>I can't however get a working version of a /bin/sh -c %p/bin/activate; python %f style virtualenv command. I have tried many versions but just can't get it working. This one finds activate and the file but fails.<br>
<br>/bin/sh -c /home/sayth/Projects/Test/bin/activate; python file1.py (in directory: /home/sayth/Projects/Test)<br>Traceback (most recent call last):<br>  File "file1.py", line 3, in <module><br>    import django<br>
ImportError: No module named django<br>Compilation failed.<br><br></div>Sayth<br><div><br><br><div><div></div></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Sun, Feb 2, 2014 at 10:02 PM, Enrico Tröger <span dir="ltr"><<a href="mailto:enrico.troeger@uvena.de" target="_blank">enrico.troeger@uvena.de</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">On 02/02/14 01:12, Sayth Renshaw wrote:<br>
> OK using vanilla virtualenv(no wrapper) and with built in project from<br>
> geany I have ~/Projects/Test/bin/activate for virtualenv.<br>
><br>
> The project is open and so %p as working directory works perfectly, however<br>
> it returns error on source /bin/sh:1 :source "not found.<br>
><br>
> Updated the command to source bin/activate; python "%f" as thats the usual<br>
> command line activation. still same error.<br>
<br>
</div>I'm afraid I wasn't clear enough about what I meant:<br>
Instead of using the 'bin/activate' script at all, just use the Python<br>
interpreter in the virtualenv's bin directory as this should know the<br>
paths already.<br>
<br>
Something like this could be your build command:<br>
<br>
%p/env/bin/python "%f"<br>
<br>
(provided that your virtualenv is called 'env' in the project directory)<br>
<div class="HOEnZb"><div class="h5"><br>
Regards,<br>
Enrico<br>
<br>
--<br>
Get my GPG key from <a href="http://www.uvena.de/pub.asc" target="_blank">http://www.uvena.de/pub.asc</a><br>
<br>
</div></div><br>_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.geany.org">Users@lists.geany.org</a><br>
<a href="https://lists.geany.org/cgi-bin/mailman/listinfo/users" target="_blank">https://lists.geany.org/cgi-bin/mailman/listinfo/users</a><br>
<br></blockquote></div><br></div>