[sage-devel] Re: preparser is affecting commands like 'cd', 'mv', etc.

2011-01-17 Thread Eviatar
I submitted a patch for this a few days ago: http://trac.sagemath.org/sage_trac/ticket/10611 On Jan 17, 3:00 pm, Niles wrote: > Is the following a known bug? > > sage: cd tmp0-50/ > [Errno 2] No such file or directory: 'tmp0-Integer(50)/' > > of course it works fine if I put quotes around the fi

[sage-devel] Re: preparser is affecting commands like 'cd', 'mv', etc.

2011-01-17 Thread Eviatar
Never mind, the patch doesn't fix that issue, although it does make it regard cd as a keyword. -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at htt

[sage-devel] Re: preparser is affecting commands like 'cd', 'mv', etc.

2011-01-17 Thread Eviatar
Never mind, the patch doesn't fix that issue, although it does make it regard cd as a keyword. -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at htt

[sage-devel] Re: preparser is affecting commands like 'cd', 'mv', etc.

2011-01-18 Thread Keshav Kini
On Jan 19, 12:11 am, Jeroen Demeyer wrote: > On 2011-01-18 00:00, Niles wrote: > > > Is the following a known bug? > > > sage: cd tmp0-50/ > > [Errno 2] No such file or directory: 'tmp0-Integer(50)/' > > In my opinion, writing such code without quotes is a bad habit anyway. > Remember that you are

[sage-devel] Re: preparser is affecting commands like 'cd', 'mv', etc.

2011-01-18 Thread Niles
On Jan 18, 11:42 am, Keshav Kini wrote: > On Jan 19, 12:11 am, Jeroen Demeyer wrote: > > > > In my opinion, writing such code without quotes is a bad habit anyway. > > Remember that you are writing Python, not a shell script.  Because of > > this, I don't really consider the above an issue. > >

[sage-devel] Re: preparser is affecting commands like 'cd', 'mv', etc.

2011-01-19 Thread Niles
On Jan 18, 1:00 pm, Mike Hansen wrote: > If you just want to run "system" commands, just use the IPython > command for that: > >  !mv tmp0-50/output-02*.png some-other-directory/ Ah -- I didn't know about that. Thanks! Niles -- To post to this group, send an email to sage-devel@googlegroups.

[sage-devel] Re: preparser is affecting commands like 'cd', 'mv', etc.

2011-01-19 Thread mhampton
I don't like to assume the existence of IPython for portability reasons, so I usually just use something like err = os.system('mv tmp0-50/output-02*.png some-other-directory') A little more to type I guess, but safer I think. -Marshall On Jan 19, 6:33 am, Niles wrote: > On Jan 18, 1:00 pm, Mike

Re: [sage-devel] Re: preparser is affecting commands like 'cd', 'mv', etc.

2011-01-18 Thread Willem Jan Palenstijn
On Tue, Jan 18, 2011 at 08:42:07AM -0800, Keshav Kini wrote: > On Jan 19, 12:11?am, Jeroen Demeyer wrote: > > On 2011-01-18 00:00, Niles wrote: > > > > > Is the following a known bug? > > > > > sage: cd tmp0-50/ > > > [Errno 2] No such file or directory: 'tmp0-Integer(50)/' > > > > In my opinion,

Re: [sage-devel] Re: preparser is affecting commands like 'cd', 'mv', etc.

2011-01-18 Thread Mike Hansen
On Tue, Jan 18, 2011 at 9:57 AM, Niles wrote: > Fair enough -- I was afraid this might be the answer.  I asked about > the non-proper syntax because I don't know how to do globbing > properly.  Is there a proper syntax for the following? > > sage: mv tmp0-50/output-02*.png some-other-directory/ >