On Fri, Aug 26, 2011 at 9:40 AM, Paul Grenyer wrote:
> Hi
>
> > What does your if __name__ == "__main__": look like? Or, if you don't
> have
> > that, can you share your entry script?
>
> Yep:
>
> if __name__ == '__main__':
>unittest.main()
>
> --
> Thanks
> Paul
>
>
You'd probably want t
Hi
> I don't regard that as a hack.
Each to their own. :-)
If nothing else, it's not very portable.
> It is quite unusual for a program to have a
> command line switch for setting the working directory, at least for
> non-GUI-programs. Usually the working directory is set in the context of the
Hi
> What does your if __name__ == "__main__": look like? Or, if you don't have
> that, can you share your entry script?
Yep:
if __name__ == '__main__':
unittest.main()
--
Thanks
Paul
Paul Grenyer
e: paul.gren...@gmail.com
b: paulgrenyer.blogspot.com
t: pjgrenyer
_
Am 26.08.2011 16:56, schrieb Paul Grenyer:
Yeah, that feels like quite a hack. It's odd you can't set the working
directory for the python executable.
Hi Paul,
I don't regard that as a hack. It is quite unusual for a program to have
a command line switch for setting the working directory
On Fri, Aug 26, 2011 at 7:56 AM, Paul Grenyer wrote:
> Yeah, that feels like quite a hack. It's odd you can't set the working
> directory for the python executable.
It's not that odd - very few console programs let you set their
working directory from the command line. If you need temporarily
swi
On Fri, Aug 26, 2011 at 8:09 AM, Paul Grenyer wrote:
> Hi
>
> > Can you show the console output that makes you think it's pulling the
> second
> > argument as a python file to execute?
>
> Sure!
>
> Here's my commandline that works:
>
> DirList\3rdparty\IronPython\ipy.exe
> DirList\AcceptanceTests
Hi
> Can you show the console output that makes you think it's pulling the second
> argument as a python file to execute?
Sure!
Here's my commandline that works:
DirList\3rdparty\IronPython\ipy.exe DirList\AcceptanceTests\acceptance_tests.py
Then if I add a parameter:
DirList\3rdparty\IronPyt
On Fri, Aug 26, 2011 at 7:56 AM, Paul Grenyer wrote:
> Hi Peter
>
> > if you are running windows:
> >
> > if you end up in the wrong directory after failure you could use
> > sub-batch-files (call .bat ) and in that sub-batch-files you
> could
> > use the command setlocal. Then environment
Hi Peter
> if you are running windows:
>
> if you end up in the wrong directory after failure you could use
> sub-batch-files (call .bat ) and in that sub-batch-files you could
> use the command setlocal. Then environment and working directory are
> restored on return from the batch file.
Hi Paul,
if you are running windows:
if you end up in the wrong directory after failure you could use
sub-batch-files (call .bat ) and in that sub-batch-files you
could use the command setlocal. Then environment and working directory
are restored on return from the batch file.
Peter
HI
Ok, I'm trying a different approach where I pass in the path the to
file I want to work on. However, I can't get the command line syntax
right:
ipy.exe acceptance_test.py ../bin/release/DirList
It keeps treating the second parameter as python file. What's the
correct syntax?
--
Thanks
Paul
Hi, Paul,
Von: ironpython-users-bounces+m.schaber=3s-software@python.org
> On Fri, Aug 26, 2011 at 8:42 AM, Markus Schaber software.com> wrote:
> > Von: ironpython-users-bounces+m.schaber=3s-software@python.org
> >> Is it possible to set the working directory at the command line?
> >> Goo
Hi
On Fri, Aug 26, 2011 at 8:42 AM, Markus Schaber
wrote:
> Hi,
>
> Von: ironpython-users-bounces+m.schaber=3s-software@python.org
>> Is it possible to set the working directory at the command line?
>> Google isn't helping me. What I want is:
>>
>> ipy.exe mypy.py.
>
> Why don't you use the
Hi,
Von: ironpython-users-bounces+m.schaber=3s-software@python.org
> Is it possible to set the working directory at the command line?
> Google isn't helping me. What I want is:
>
> ipy.exe mypy.py.
Why don't you use the command line methods for changing the directory?
e. G. in bash, you co
Hi All
Is it possible to set the working directory at the command line?
Google isn't helping me. What I want is:
ipy.exe mypy.py.
--
Thanks
Paul
Paul Grenyer
e: paul.gren...@gmail.com
b: paulgrenyer.blogspot.com
t: pjgrenyer
___
Ironpython-users mai
15 matches
Mail list logo