> On 28. Nov 2019, at 12:05, Ulrich Goebel wrote:
>
> Hi,
>
> I have to call commands from inside a python skript. These commands are in
> fact other python scripts. So I made
>
>os.system('\.Test.py')
>
> That works.
>
> Now I tried to use
>
>supprocess.call(['.\', 'test.py'])
[
Ulrich Goebel writes:
> Hi,
>
> I have to call commands from inside a python skript. These commands are
> in fact other python scripts. So I made
>
> os.system('\.Test.py')
>
> That works.
In a string \. is the same as . So this should execute the command '.Test.py'.
Is that really what you
Sorry for the wrong spelling. In fact
subprocess.call('./Test.py')
works.
The raising error was my error too, using ['./', 'Test.py'] instead of
'./Test.py'
Sorry...
Am 28.11.19 um 11:05 schrieb Ulrich Goebel:
Hi,
I have to call commands from inside a python skript. These commands are
Ulrich Goebel wrote:
> Hi,
>
> I have to call commands from inside a python skript. These commands are
> in fact other python scripts. So I made
>
> os.system('\.Test.py')
>
> That works.
>
> Now I tried to use
>
> supprocess.call(['.\', 'test.py'])
Remember to use cut and paste fo
For completeness I will note that Windows is completely different. The
plain exit status (1 for typical command failures) appears in the
os.system result rather than a wait-encoded value. And, incidentally, an
MSVC program which calls abort() will return an exit status of 3. A
process that terminat
On Fri, Jun 12, 2015, at 09:54, Ian Kelly wrote:
> Exit code 0 traditionally means success. The exit status is two bytes,
> with
> the low-order byte normally containing the exit code and the high-order
> byte containing the signal that caused the program to exit.
That's backwards. The signal (or
On Jun 12, 2015 7:54 AM, "Ian Kelly" wrote:
>
> On Jun 12, 2015 7:21 AM, "Grawburg" wrote:
> >
> > I have a piece of code written for a Raspberry Pi with no explanation
for two of the lines -- and I can't find an explanation I understand.
> >
> > Here are the lines:
> > if os.system('modprobe --f
On 2015-06-12, Ben Finney wrote:
> There is no standardisation of exit status values between different
> programs. The best one can say is “exit status 0 means success”.
> Anything further is specific to particular programs and is not
> universal.
>
> You'll need to see the documentation for ‘mod
On Jun 12, 2015 7:21 AM, "Grawburg" wrote:
>
> I have a piece of code written for a Raspberry Pi with no explanation for
two of the lines -- and I can't find an explanation I understand.
>
> Here are the lines:
> if os.system('modprobe --first-time -q w1_gpio') ==0
>
> if os.system('modprobe -q w1
Grawburg wrote:
> I have a piece of code written for a Raspberry Pi with no explanation for
> two of the lines -- and I can't find an explanation I understand.
>
> Here are the lines:
> if os.system('modprobe --first-time -q w1_gpio') ==0
>
> if os.system('modprobe -q w1_gpio') == 256:
>
>
>
On 2015-06-12, Grawburg wrote:
> I have a piece of code written for a Raspberry Pi with no explanation for two
> of the lines -- and I can't find an explanation I understand.
>
> Here are the lines:
> if os.system('modprobe --first-time -q w1_gpio') ==0
>
> if os.system('modprobe -q w1_gpio') ==
Grawburg writes:
> if os.system('modprobe --first-time -q w1_gpio') ==0
>
> if os.system('modprobe -q w1_gpio') == 256:
>
> I know what the 'modprobe...' is, it's the 0 and the 256 I don't get.
> Where do these numbers come from?
They are integer literals, they come from the source code.
The st
On 05Apr2013 16:36, Chris Rebert wrote:
| No need for third-party code, just use the std lib:
| http://docs.python.org/2/library/pipes.html#pipes.quote
| http://docs.python.org/3/library/shlex.html#shlex.quote
Ah, handy. I must say its quote quoting is kind of verbose, though.
| (But yeah, best
On Fri, Apr 5, 2013 at 3:00 PM, Cameron Simpson wrote:
> On 01Apr2013 20:26, John Gordon wrote:
> | In <0c9717ca-52dd-49ce-8102-e14328838...@googlegroups.com> cev...@gmail.com
> writes:
> | > someip = '192.168.01.01'
> | > var1 = 'lynx -dump http://' + someip +
> '/cgi-bin/.log&.submit=+++G
On 01Apr2013 20:26, John Gordon wrote:
| In <0c9717ca-52dd-49ce-8102-e14328838...@googlegroups.com> cev...@gmail.com
writes:
| > someip = '192.168.01.01'
| > var1 = 'lynx -dump http://' + someip +
'/cgi-bin/.log&.submit=+++Go%21+++ > junk'
|
| '&' is a special character in shell commands.
In <0c9717ca-52dd-49ce-8102-e14328838...@googlegroups.com> cev...@gmail.com
writes:
> someip = '192.168.01.01'
> var1 = 'lynx -dump http://' + someip + '/cgi-bin/.log&.submit=+++Go%21+++
> > junk'
'&' is a special character in shell commands. You'll need to quote or
escape it.
Try this:
On Tue, Apr 2, 2013 at 6:22 AM, wrote:
> var1 = 'lynx -dump http://' + someip + '/cgi-bin/.log&.submit=+++Go%21+++
> > junk'
> lynx -dump 'http://192.168.01.01/cgi-bin/.log&.submit=+++Go%21+++ > junk'
The problem is the &, which splits the command. Note how your manual
execution puts
On 01/03/2013 16:23, Jaiky wrote:
it is running in view..
When replying can you please ensure we have the complete context,
otherwise we have to spend time looking, thanks.
--
Cheers.
Mark Lawrence
--
http://mail.python.org/mailman/listinfo/python-list
in django inviroment..
--
http://mail.python.org/mailman/listinfo/python-list
it is running in view..
--
http://mail.python.org/mailman/listinfo/python-list
On Fri, Mar 1, 2013, at 09:24 AM, Roy Smith wrote:
> In article <4fcc93b7-3be9-416f-a2d4-bdc6cba21...@googlegroups.com>,
> Jaiky wrote:
>
> [a lot of code involving ssh and paramiko]
>
> Here's a few general suggestions:
>
> 1) Try to reduce this to the smallest possible amount of code which
In article <4fcc93b7-3be9-416f-a2d4-bdc6cba21...@googlegroups.com>,
Jaiky wrote:
[a lot of code involving ssh and paramiko]
Here's a few general suggestions:
1) Try to reduce this to the smallest possible amount of code which
demonstrates the problem. You gave us a page full of complicated s
On 18Dec2012 05:39, Dave Angel wrote:
| On 12/18/2012 05:27 AM, Hans Mulder wrote:
| > On 18/12/12 06:10:43, photonym...@gmail.com wrote:
| >> I hope I understand the question... but shouldn't you wait for the process
to complete before exiting?
| >>
| >> Something like:
| >>
| >> pid = subproces
On 17/12/12 21:56:50, py_genetic wrote:
> /usr/local/Calpont/mysql/bin/mysql
> --defaults-file=/usr/local/Calpont/mysql/my.cnf -u root myDB <
> /home/myusr/jobs/APP_JOBS/JOB_XXX.SQL > /home/myusr/jobs/APP_JOBS/JOB_XXX.TXT
If you're trying to interact with a MySQL database, then
you should really
Solved the issue, by injecting the query into the cmd line. Shell script
worked fine as if I was cutting and pasting to the prompt. Seems to still be
something with the subprocess receiving and exit code before or when the query
finishes, just when I ask to to read from the .SQL file.
example
Can you trim content and interleave your response (instead of
top-posting) please?
On 18 December 2012 18:26, py_genetic wrote:
> HOWEVER...
>
> when using this command from before no dice
>
> /usr/local/Calpont/mysql/bin/mysql
> --defaults-file=/usr/local/Calpont/mysql/my.cnf -u root myDB <
Oscar I can confirm this behavior from terminal.
AND this works as well, simulating exactly what I'm doing permissions wise, and
calling sudo python test.py below
f1 = open('TESTDIR/file1.txt', 'w')
f1.write('some test here\n')
f1.close()
cmd1 = 'cat < TESTDIR/file1.txt > TESTDIR/file2.txt'
P
On 18/12/12 11:39:56, Dave Angel wrote:
> On 12/18/2012 05:27 AM, Hans Mulder wrote:
>> On 18/12/12 06:10:43, photonym...@gmail.com wrote:
>>> I hope I understand the question... but shouldn't you wait for the process
>>> to complete before exiting?
>>>
>>> Something like:
>>>
>>> pid = subprocess
On 12/18/2012 05:27 AM, Hans Mulder wrote:
> On 18/12/12 06:10:43, photonym...@gmail.com wrote:
>> I hope I understand the question... but shouldn't you wait for the process
>> to complete before exiting?
>>
>> Something like:
>>
>> pid = subprocess.Popen(...)
>> pid.wait()
>>
>> Otherwise, it'll
On 18/12/12 06:10:43, photonym...@gmail.com wrote:
> I hope I understand the question... but shouldn't you wait for the process to
> complete before exiting?
>
> Something like:
>
> pid = subprocess.Popen(...)
> pid.wait()
>
> Otherwise, it'll exit before the background process is done.
Why w
I hope I understand the question... but shouldn't you wait for the process to
complete before exiting?
Something like:
pid = subprocess.Popen(...)
pid.wait()
Otherwise, it'll exit before the background process is done.
--
http://mail.python.org/mailman/listinfo/python-list
On 17 December 2012 20:56, py_genetic wrote:
> Oscar, seems you may be correct. I need to run this program as a superuser.
> However, after some more tests with simple commands... I seem to be working
> correctly from any permission level in python Except for the output write
> command f
Oscar, seems you may be correct. I need to run this program as a superuser.
However, after some more tests with simple commands... I seem to be working
correctly from any permission level in python Except for the output write
command from the database to a file. Which runs fine if I past
On 17 December 2012 16:39, py_genetic wrote:
> Thanks for verifying this for me Steven. I'm glad you are seeing it work.
> It's really the strangest thing.
>
> The issue seems to be with the " > outfile.txt" portion of the command.
>
> The actual command is running a query on a verticalDB and d
Thanks for verifying this for me Steven. I'm glad you are seeing it work.
It's really the strangest thing.
The issue seems to be with the " > outfile.txt" portion of the command.
The actual command is running a query on a verticalDB and dumping the result.
The EXACT command run from the comm
Thanks! I am using .txt extensions. Sorry for being a little vague.
--
http://mail.python.org/mailman/listinfo/python-list
py_genetic writes:
> Example of the issue for arguments sake:
>
> Platform Ubuntu server 12.04LTS, python 2.7
>
> Say file1.txt has "hello world" in it.
^
Here, you speak of "file1.txt" (note the extension ".txt")
> subprocess.Popen("cat < file1 > file2", shell = True)
> subprocess
On Fri, 14 Dec 2012 10:13:38 -0800, py_genetic wrote:
> Example of the issue for arguments sake:
>
> Platform Ubuntu server 12.04LTS, python 2.7
>
> Say file1.txt has "hello world" in it.
>
> subprocess.Popen("cat < file1 > file2", shell = True)
> subprocess.call("cat < file1 > file2", shell =
On Apr 20, 6:51 am, Yigit Turgut wrote:
> On Apr 19, 11:02 pm, "Steve" wrote:
>
> > > "Yigit Turgut" wrote in message
> > >news:b9a8bb28-3003-4a36-86fb-339ef697b...@i2g2000vbd.googlegroups.com...
> > > When I use os.system() function, script waits for termination of the
>
> > windows that is ope
On Fri, Apr 20, 2012 at 8:51 PM, Yigit Turgut wrote:
> On Apr 19, 11:02 pm, "Steve" wrote:
>> > "Yigit Turgut" wrote in message
>> >news:b9a8bb28-3003-4a36-86fb-339ef697b...@i2g2000vbd.googlegroups.com...
>> > When I use os.system() function, script waits for termination of the
>>
>> windows tha
On Apr 19, 11:02 pm, "Steve" wrote:
> > "Yigit Turgut" wrote in message
> >news:b9a8bb28-3003-4a36-86fb-339ef697b...@i2g2000vbd.googlegroups.com...
> > When I use os.system() function, script waits for termination of the
>
> windows that is opened by os.system() to continue thus throwing errors
>
"Yigit Turgut" wrote in message
news:b9a8bb28-3003-4a36-86fb-339ef697b...@i2g2000vbd.googlegroups.com...
When I use os.system() function, script waits for termination of the
windows that is opened by os.system() to continue thus throwing errors
and etc. How can i tell Python to let it go and
On Thursday, April 19, 2012 11:09:22 AM UTC-7, Yigit Turgut wrote:
> When I use os.system() function, script waits for termination of the
> windows that is opened by os.system() to continue thus throwing errors
> and etc. How can i tell Python to let it go and keep on with the next
> execution afte
On 19/04/2012 19:09, Yigit Turgut wrote:
When I use os.system() function, script waits for termination of the
windows that is opened by os.system() to continue thus throwing errors
and etc. How can i tell Python to let it go and keep on with the next
execution after os.system() ?
Try using the
On 8/13/11 1:15 AM, Nobody wrote:
On Fri, 12 Aug 2011 22:49:32 -0400, Kevin Walzer wrote:
I'm developing a Tkinter app for a Windows customer, and the app bundles
several command-line tools (ported from Unix). I call out to these
console tools from the Tkinter app via os.system(). However, in t
On Fri, 12 Aug 2011 22:49:32 -0400, Kevin Walzer wrote:
> I'm developing a Tkinter app for a Windows customer, and the app bundles
> several command-line tools (ported from Unix). I call out to these
> console tools from the Tkinter app via os.system(). However, in the
> frozen version of my ap
On Jan 10, 1:01 pm, Carl Banks wrote:
> On Jan 10, 8:29 am, Tim wrote:
>
>
>
>
>
>
>
>
>
> > On Jan 7, 11:24 am, Tim wrote:
>
> > > hi, I'm using a 3rd-party python program that uses the python logging
> > > facility and also makes calls to os.system. I'm trying to capture its
> > > output to a
On Jan 10, 8:29 am, Tim wrote:
> I think I may have included too much fluff in my original question.
> The main thing I wonder is whether I can attach a log handler to
> stdout in such a way that os.system calls will write to that handler
> instead of the console.
--
http://mail.python.org/mailma
On Jan 10, 8:29 am, Tim wrote:
> On Jan 7, 11:24 am, Tim wrote:
>
>
>
>
>
> > hi, I'm using a 3rd-party python program that uses the python logging
> > facility and also makes calls to os.system. I'm trying to capture its
> > output to a file.
>
> > In my own code, I've taken control of the logge
On Jan 7, 11:24 am, Tim wrote:
> hi, I'm using a 3rd-party python program that uses the python logging
> facility and also makes calls to os.system. I'm trying to capture its
> output to a file.
>
> In my own code, I've taken control of the loggers that are setup in
> the other program by removing
In message , Peter Kleiweg
wrote:
> How do I set the string encoding for os.system to anything other then
> UTF-8?
Works for me (on Debian Unstable):
l...@theon:~> echo $LC_ALL
en_NZ.utf8
l...@theon:~> python3.1
Python 3.1.2 (r312:79147, May 8 2010, 13:27:06)
[GCC 4.4.4] o
>> For the moment, you can encode the string explicitly, and pass a byte
>> string.
>
> That doesn't work
I only have 3.1.2 to test at the moment. I suggest trying to use the
subprocess module instead.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
Martin v. Loewis schreef op de 27e dag van de zomermaand van het jaar 2010:
> Am 25.06.2010 17:13, schrieb Peter Kleiweg:
> > How do I set the string encoding for os.system to anything other then UTF-8?
>
> You shouldn't have to set it, as it should use your locale's encoding.
> In 3.1.2, it will
Am 25.06.2010 17:13, schrieb Peter Kleiweg:
> How do I set the string encoding for os.system to anything other then UTF-8?
You shouldn't have to set it, as it should use your locale's encoding.
In 3.1.2, it will.
For the moment, you can encode the string explicitly, and pass a byte
string.
Regar
Lie Ryan wrote:
> On 01/13/10 04:59, r0g wrote:
>> so you may want to look into pythons core GUI library, TKL.
>
> I know Tk and Tcl has been close since their childhood; did they get
> married too?
Whoops... yes Tk/Tcl, it seems they had become one in my head only!
:)
Roger.
--
http://mail.py
On 01/13/10 04:59, r0g wrote:
> so you may want to look into pythons core GUI library, TKL.
I know Tk and Tcl has been close since their childhood; did they get
married too?
--
http://mail.python.org/mailman/listinfo/python-list
Zabin wrote:
> Hey everyone!
>
> I am a new python programmer. I am trying to get the general file
> functionality with options of save and save as working. These save
> functions save a folder with multiple files. Upon using the os.system
> copy function- if my destination directory has files wit
Zabin wrote:
> Thanks for the pointersi had a look around and found the site:
>
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-
us/xcopy.mspx?mfr=true
>
> to disable the prompt- i needed to include /y as below:
> os.system ('xcopy /s %s %s /y ' % (dirExe, dirnam
On Jan 12, 11:31 am, Jeremy Sanders wrote:
> Zabin wrote:
> > Thanks for the pointersi had a look around and found the site:
>
> http://www.microsoft.com/resources/documentation/windows/xp/all/prodd...
> us/xcopy.mspx?mfr=true
>
>
>
> > to disable the prompt- i needed to include /y as below:
>
On Mon, Jan 11, 2010 at 2:00 PM, Zabin wrote:
> and just wondering- whats the drawback of using os.system() command
Forgetting to properly escape your input. Simple example:
filename = "foo bar.txt"
os.system("rm "+filename) # uh-oh, we deleted 'foo' and 'bar.txt' instead
The `subprocess` modu
On Jan 12, 10:23 am, Chris Rebert wrote:
> On Mon, Jan 11, 2010 at 12:43 PM, Zabin wrote:
> > Hey everyone!
>
> > I am a new python programmer. I am trying to get the general file
> > functionality with options of save and save as working. These save
> > functions save a folder with multiple file
On Mon, Jan 11, 2010 at 12:43 PM, Zabin wrote:
> Hey everyone!
>
> I am a new python programmer. I am trying to get the general file
> functionality with options of save and save as working. These save
> functions save a folder with multiple files. Upon using the os.system
> copy function- if my d
2010/1/11 Zabin :
> Hey everyone!
>
> I am a new python programmer. I am trying to get the general file
> functionality with options of save and save as working. These save
> functions save a folder with multiple files. Upon using the os.system
> copy function- if my destination directory has files
On Mon, Oct 19, 2009 at 2:14 PM, Bryan Irvine wrote:
> I'm a python n00b and so pardon me in advance if this is really stupid
> question.
>
> I have my suspicions but why does the following not work the way I'm
> anticipating it will?
>
> (python 2.4.4)
>
import os
if (os.system('echo t
On Mon, Oct 19, 2009 at 11:14 AM, Bryan Irvine wrote:
> I'm a python n00b and so pardon me in advance if this is really stupid
> question.
>
> I have my suspicions but why does the following not work the way I'm
> anticipating it will?
>
> (python 2.4.4)
>
import os
if (os.system('echo
Bryan Irvine wrote:
I'm a python n00b and so pardon me in advance if this is really stupid
question.
I have my suspicions but why does the following not work the way I'm
anticipating it will?
(python 2.4.4)
import os
if (os.system('echo test')):
...print 'success'
... else:
...prin
eryone.
> To: python-list@python.org
> From: gagsl-...@yahoo.com.ar
> Subject: Re: os.system in a service
> Date: Thu, 6 Aug 2009 05:35:57 -0300
>
> En Thu, 06 Aug 2009 03:59:13 -0300, Diez B. Roggisch
> escribió:
> > Gabriel Genellina schrieb:
> >> En Wed,
En Thu, 06 Aug 2009 03:59:13 -0300, Diez B. Roggisch
escribió:
Gabriel Genellina schrieb:
En Wed, 05 Aug 2009 13:07:39 -0300, Lawrence Wong
escribió:
I wrote a program which runs a .bat file using os.system like:
'os.system(pathToBatFile)' and everything was good. Then I decided to
tu
Gabriel Genellina schrieb:
En Wed, 05 Aug 2009 13:07:39 -0300, Lawrence Wong
escribió:
I wrote a program which runs a .bat file using os.system like:
'os.system(pathToBatFile)' and everything was good. Then I decided to
turn my program into a service as opposed to being run with the
comman
En Wed, 05 Aug 2009 13:07:39 -0300, Lawrence Wong
escribió:
I wrote a program which runs a .bat file using os.system like:
'os.system(pathToBatFile)' and everything was good. Then I decided to
turn my program into a service as opposed to being run with the command
prompt showing. When
I ended up going with this:
http://code.activestate.com/recipes/440554/
seems to feed me new lines of output atleast before the subprocess
finishes, with some adjustment of the time delays. I'll guess I'll
just be packing winpy into the installer. Or something.
--
http://mail.python.org/mailma
Nate wrote:
Thanks for your response. Related to this talk about shells, maybe you
could point me towards a resource where I could read about how windows
commands are processed w/w/o shells? I guess I assumed all subprocess
commands were intepreted by the same thing, cmd.exe., or perhaps the
she
In message , Christian
Heimes wrote:
> The subprocess doesn't use the shell ...
It can if you tell it to.
--
http://mail.python.org/mailman/listinfo/python-list
Nate wrote:
> Thanks for your response. Related to this talk about shells, maybe you
> could point me towards a resource where I could read about how windows
> commands are processed w/w/o shells? I guess I assumed all subprocess
> commands were intepreted by the same thing, cmd.exe., or perhaps t
On Jun 21, 3:49 pm, Christian Heimes wrote:
> Nate wrote:
> > gmapcreator = subprocess.Popen("java -Xms128M -Xmx512M -jar
> > gmapcreator.jar -dfile=censettings.xml", stdin=subprocess.PIPE,
> > stdout=subprocess.PIPE, stderr=subprocess.PIPE)
>
> Try this:
>
> gmapcreator = subprocess.Popen(
>
Nate wrote:
> gmapcreator = subprocess.Popen("java -Xms128M -Xmx512M -jar
> gmapcreator.jar -dfile=censettings.xml", stdin=subprocess.PIPE,
> stdout=subprocess.PIPE, stderr=subprocess.PIPE)
Try this:
gmapcreator = subprocess.Popen(
["java", "-Xms128M", "-Xmx512M", "-jar", "gmapcreator.jar",
On Jun 21, 2:12 pm, Chris Rebert wrote:
> On Sun, Jun 21, 2009 at 10:12 AM, Nate wrote:
> > I get different behavior with os.system and subprocess (no surprise
> > there I guess), but I was hoping for some clarification, namely why.
>
> > If I type this directly into the command window:
>
> > java
On Sun, Jun 21, 2009 at 10:12 AM, Nate wrote:
> I get different behavior with os.system and subprocess (no surprise
> there I guess), but I was hoping for some clarification, namely why.
>
> If I type this directly into the command window:
>
> java -Xms128M -Xmx512M -jar gmapcreator.jar -dfile=cens
On Thu, Feb 5, 2009 at 6:00 AM, Youri Lammers
wrote:
> Ok,
>
> I want to run a program called 'muscle' with my python script,
> muscle uses the following command:
> 'muscle.exe -in filename -out filename'
> so far I got:
>
> import os
> args = ['-in filename', '-out filename']
As Christian indire
On 2009-02-05, Christian Heimes wrote:
> Youri Lammers schrieb:
>> Ok,
>>
>> I want to run a program called 'muscle' with my python script,
>> muscle uses the following command:
>> 'muscle.exe -in filename -out filename'
>> so far I got:
>>
>> import os
>> args = ['-in filename', '-out filenam
Youri Lammers schrieb:
> Ok,
>
> I want to run a program called 'muscle' with my python script,
> muscle uses the following command:
> 'muscle.exe -in filename -out filename'
> so far I got:
>
> import os
> args = ['-in filename', '-out filename']
> os.system('E:\Programs\muscle\muscle.exe args
Depends on what operating system you are using. The list of possible
commands would be unbounded, if not truly infinite.
> From: Dennis van Oosterhout [mailto:de.slotenzwem...@gmail.com]
>
> Hi there! I was searching for a way to clear the 'DOS screen'/command
> screen etc. and found that os.s
On Thu, 25 Dec 2008 13:11:09 +0100
"Dennis van Oosterhout" wrote:
> Btw...does that mean that system('cls') only works on Windows...or to
> say it otherwise: the program isn't platform independant?
Exactly - sort of. Unless, of course, you have a program called "cls"
installed on other platforms
Hi Dennis,
print dir(os.system)
print os.__dict__
might help
Bye,
Ron.
From: Dennis van Oosterhout [mailto:de.slotenzwem...@gmail.com]
Sent: Thursday, December 25, 2008 12:22
To: python-list@python.org
Subject: os.system('cls')
Hi there! I was searching
2008/12/25 Dennis van Oosterhout :
Hello Arno,
thanks for the explanation! I have one more question: on the python
site it says it's better to replace the system commands by subprocess
and Popen.
Now I searched for some good example for my specific case (as I have
no idea how it should work
On Thu, Dec 25, 2008 at 7:11 AM, Dennis van Oosterhout <
de.slotenzwem...@gmail.com> wrote:
> Btw...does that mean that system('cls') only works on Windows...or to
> say it otherwise: the program isn't platform independant?
>
>
Yes.
--
http://mail.python.org/mailman/listinfo/python-list
On 25 dec 2008, at 12:56, Dennis van Oosterhout wrote:
Hello Arno,
thanks for the explanation! I have one more question: on the python
site it says it's better to replace the system commands by subprocess
and Popen.
Now I searched for some good example for my specific case (as I have
no idea h
On 25 dec 2008, at 11:22, Dennis van Oosterhout wrote:
Hi there! I was searching for a way to clear the 'DOS screen'/
command screen etc. and found that os.system('cls') works for this.
I was just wondering where I can find al the commands which can be
used for os.system(). I searched with
Btw...does that mean that system('cls') only works on Windows...or to
say it otherwise: the program isn't platform independant?
2008/12/25 Dennis van Oosterhout :
> Hello Arno,
>
> thanks for the explanation! I have one more question: on the python
> site it says it's better to replace the system
Hello Arno,
thanks for the explanation! I have one more question: on the python
site it says it's better to replace the system commands by subprocess
and Popen.
Now I searched for some good example for my specific case (as I have
no idea how it should work and I don't get it any clearer by reading
Blubaugh, David A. wrote:
> Thank You!!
>
> I am still new to Python!!
>
> David Blubaugh
As you've already noticed, plenty of folks here on the list are ready
help you out with issues the crop up as you learn python. So keep on
asking questions as you need assistance.
In the future, please
Blubaugh, David A. wrote:
To All,
I have been attempting to execute the following program within the
Python environment:
Myprogram.exe, which means this is an executable file!!
I would usually execute this program (with the appropriate arguments) by
going to following directory within MS-DOS
Yes,
I new it was a directory issue. I am new to Python.
Thank You
David Blubaugh
-Original Message-
From: Martin Walsh [mailto:[EMAIL PROTECTED]
Sent: Tuesday, September 30, 2008 1:42 PM
To: python-list@python.org
Subject: Re: OS.SYSTEM ERROR !!!
Blubaugh, David A. wrote:
>
Thank You!!
I am still new to Python!!
David Blubaugh
-Original Message-
From: Christian Heimes [mailto:[EMAIL PROTECTED]
Sent: Tuesday, September 30, 2008 2:08 PM
To: python-list@python.org
Subject: Re: OS.SYSTEM ERROR !!!
Blubaugh, David A. wrote:
> To All,
>
>
[EMAIL PROTECTED] wrote:
I would add the following line right before your call to os.system:
os.chdir(r'C:\myprogramfolder\run')
I wouldn't. os.chdir() tends to introduce all sorts of trouble. It's a
quick n'dirty hack for a small script but no solution for a large
program or library.
Chri
Blubaugh, David A. wrote:
> To All,
>
> I have been attempting to execute the following program within the
> Python environment:
>
> However, when I would try to execute the following lines of source code
> within a python script file:
>
> import os
>
> os.system(r"C:\myprogramfolder\run\Mypr
Blubaugh, David A. wrote:
To All,
I have been attempting to execute the following program within the
Python environment:
Myprogram.exe, which means this is an executable file!!
I would usually execute this program (with the appropriate arguments) by
going to following directory within MS-DOS
On Sep 30, 1:21 pm, "Blubaugh, David A." <[EMAIL PROTECTED]> wrote:
> I would usually execute this program (with the appropriate arguments) by
> going to following directory within MS-DOS (Windows XP):
>
> C:\myprogramfolder\run> Myprogram.exe 1 1 acc 0
[snip]
> import os
>
> os.system(r"C:\myprogr
Blubaugh, David A. wrote:
> To All,
>
>
> I have been attempting to execute the following program within the
> Python environment:
>
> Myprogram.exe, which means this is an executable file!!
>
> I would usually execute this program (with the appropriate arguments) by
> going to following direc
iu2 wrote:
Hi guys
I do
os.system('ls &> e')
On one linux machine it emits ls output to the file e as expected.
On another linux machine it emits ls to the standard output, and
nothing to e!
Both machines run Fedora linux.
The command "ls &> e" entered at the shell (no python) behaves ok on
b
1 - 100 of 183 matches
Mail list logo