Re: Running manage.py commands in Windows Power Shell
Hi, I (and all my other teammates) are have been developing in windows with standard Python (+ Django + lot of other interesting stuff) in WinXP, Vista, Win7. To keep everyone on same line, we use TCC/LE (Take Command Console/LE) which is augmented CMD. Has lot of nice features. And it's free. On Sun, Mar 18, 2012 at 6:32 PM, Dennis Lee Bieberwrote: > On Sun, 18 Mar 2012 02:14:15 -0700 (PDT), orschiro > declaimed the following in > gmane.comp.python.django.user: > > > Is this the case for the ActivePython package? > > Since I don't have a non-ActiveState install anywhere to compare > against... > > -=-=-=-=-=- > Windows PowerShell > Copyright (C) 2009 Microsoft Corporation. All rights reserved. > > PS E:\UserData\Wulfraed\My Documents> ./test.py > test > > PS E:\UserData\Wulfraed\My Documents> python test.py > test > > PS E:\UserData\Wulfraed\My Documents> .\test.py > test > > PS E:\UserData\Wulfraed\My Documents> > > PS E:\UserData\Wulfraed\My Documents> get-host > > > Name : ConsoleHost > Version : 2.0 > InstanceId : 253c9466-5541-4737-b974-5b376fd39caa > UI : > System.Management.Automation.Internal.Host.InternalHostUserInterface > CurrentCulture : en-US > CurrentUICulture : en-US > PrivateData : Microsoft.PowerShell.ConsoleHost+ConsoleColorProxy > IsRunspacePushed : False > Runspace : System.Management.Automation.Runspaces.LocalRunspace > > > > PS E:\UserData\Wulfraed\My Documents> > -=-=-=-=-=- > > WinXP (on which I had to download PowerShell as it isn't standard), > running from a semi-privileged (so-called "power user") account. > -- >Wulfraed Dennis Lee Bieber AF6VN >wlfr...@ix.netcom.comHTTP://wlfraed.home.netcom.com/ > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To post to this group, send email to django-users@googlegroups.com. > To unsubscribe from this group, send email to > django-users+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/django-users?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Running manage.py commands in Windows Power Shell
After testing the Python distribution of ActiveState I have to confirm that with that version I smoothly can run .\test.py in PowerShell without having the cmd window to pop up. Overall I can only recommend all Windows users to prefer this one over the default one. Regards On Mar 18, 10:14 am, orschirowrote: > Hello Sam, > > Let's assume we're having the following script test.py containing > nothing more than a print statement and a raw_input. > > > print "Test" > raw_input() > > > When I launch test.py in PowerShell like that: > > PS C:\Users\Robert> .\test.py > > Then C:\Python27\python.exe is launched in a new cmd window that runs > test.py. > > When I launch test.py in PowerShell like that: > > PS C:\Users\Robert> python test.py > > Then the script is launched inside PowerShell. Exactly this should > happen also when I only type .\test.py. > > Is this the case for the ActivePython package? > > Regards, > > Robert > > On Mar 15, 10:54 am, Sam Lai wrote: > > > > > > > > > On 15 March 2012 04:35, orschiro wrote: > > > > Hello, > > > > I have a question which is based on the discussion here: > > > >http://groups.google.com/group/django-users/browse_thread/thread/2333... > > > > I'm working on Windows 7 with the PowerShell. Python 2.7 and the path > > > to django-admin.py is stored in my PATH variable. > > > > After creating a project I can make use of the various manage.py > > > commands in my PowerShell. However, only in the following way: > > > > 'python manage.py runserver' > > > > If I only type '.\manage.py runserver' then a new CMD window is opened > > > running again 'python manage.py runserver'. That is, the command is > > > forwarded to the CMD shell which opens it with the Python > > > interpreter. > > > > Is there any way to tell the PowerShell to interpret the command given > > > within the shell instead of launching a CMD window? > > > For me, both ways execute within PowerShell's shell. I do have > > ActiveState ActivePython installed instead of the Python distribution > > from python.org though; I find the ActiveState distribution integrates > > much better with Windows than python.org's. > > > That said, I can't really explain why you're seeing what you're seeing > > though. Does it happen if you just do '.\test.py' where test.py just > > contains simple Python commands like a couple of print statements? > > > > Regards, > > > > Robert > > > > -- > > > You received this message because you are subscribed to the Google Groups > > > "Django users" group. > > > To post to this group, send email to django-users@googlegroups.com. > > > To unsubscribe from this group, send email to > > > django-users+unsubscr...@googlegroups.com. > > > For more options, visit this group > > > athttp://groups.google.com/group/django-users?hl=en. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Running manage.py commands in Windows Power Shell
Hello Sam, Let's assume we're having the following script test.py containing nothing more than a print statement and a raw_input. print "Test" raw_input() When I launch test.py in PowerShell like that: PS C:\Users\Robert> .\test.py Then C:\Python27\python.exe is launched in a new cmd window that runs test.py. When I launch test.py in PowerShell like that: PS C:\Users\Robert> python test.py Then the script is launched inside PowerShell. Exactly this should happen also when I only type .\test.py. Is this the case for the ActivePython package? Regards, Robert On Mar 15, 10:54 am, Sam Laiwrote: > On 15 March 2012 04:35, orschiro wrote: > > > > > > > > > > > Hello, > > > I have a question which is based on the discussion here: > > >http://groups.google.com/group/django-users/browse_thread/thread/2333... > > > I'm working on Windows 7 with the PowerShell. Python 2.7 and the path > > to django-admin.py is stored in my PATH variable. > > > After creating a project I can make use of the various manage.py > > commands in my PowerShell. However, only in the following way: > > > 'python manage.py runserver' > > > If I only type '.\manage.py runserver' then a new CMD window is opened > > running again 'python manage.py runserver'. That is, the command is > > forwarded to the CMD shell which opens it with the Python > > interpreter. > > > Is there any way to tell the PowerShell to interpret the command given > > within the shell instead of launching a CMD window? > > For me, both ways execute within PowerShell's shell. I do have > ActiveState ActivePython installed instead of the Python distribution > from python.org though; I find the ActiveState distribution integrates > much better with Windows than python.org's. > > That said, I can't really explain why you're seeing what you're seeing > though. Does it happen if you just do '.\test.py' where test.py just > contains simple Python commands like a couple of print statements? > > > > > > > > > Regards, > > > Robert > > > -- > > You received this message because you are subscribed to the Google Groups > > "Django users" group. > > To post to this group, send email to django-users@googlegroups.com. > > To unsubscribe from this group, send email to > > django-users+unsubscr...@googlegroups.com. > > For more options, visit this group > > athttp://groups.google.com/group/django-users?hl=en. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Running manage.py commands in Windows Power Shell
On 15 March 2012 04:35, orschirowrote: > Hello, > > I have a question which is based on the discussion here: > > http://groups.google.com/group/django-users/browse_thread/thread/2333f5dc8d0674f0 > > I'm working on Windows 7 with the PowerShell. Python 2.7 and the path > to django-admin.py is stored in my PATH variable. > > After creating a project I can make use of the various manage.py > commands in my PowerShell. However, only in the following way: > > 'python manage.py runserver' > > If I only type '.\manage.py runserver' then a new CMD window is opened > running again 'python manage.py runserver'. That is, the command is > forwarded to the CMD shell which opens it with the Python > interpreter. > > Is there any way to tell the PowerShell to interpret the command given > within the shell instead of launching a CMD window? For me, both ways execute within PowerShell's shell. I do have ActiveState ActivePython installed instead of the Python distribution from python.org though; I find the ActiveState distribution integrates much better with Windows than python.org's. That said, I can't really explain why you're seeing what you're seeing though. Does it happen if you just do '.\test.py' where test.py just contains simple Python commands like a couple of print statements? > Regards, > > Robert > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To post to this group, send email to django-users@googlegroups.com. > To unsubscribe from this group, send email to > django-users+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/django-users?hl=en. > -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Running manage.py commands in Windows Power Shell
On Wed, Mar 14, 2012 at 6:53 PM, orschirowrote: > Hello Tom, > > I'm aware of that. But do not get me wrong. I only use Power Shell to > run the commands, for nothing more. > > it is simply more comfortable for me than CMD. > > By running Python on Windows you mean the Python IDLE? > > Regards > No, I meant that you will not get much help with launching python applications via powershell here, because the people on this list are django developers, and in general do not use powershell. Cheers Tom -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Running manage.py commands in Windows Power Shell
Hello Tom, I'm aware of that. But do not get me wrong. I only use Power Shell to run the commands, for nothing more. it is simply more comfortable for me than CMD. By running Python on Windows you mean the Python IDLE? Regards On Mar 14, 6:51 pm, Tom Evanswrote: > On Wed, Mar 14, 2012 at 5:35 PM, orschiro wrote: > > Hello, > > > I have a question which is based on the discussion here: > > >http://groups.google.com/group/django-users/browse_thread/thread/2333... > > > I'm working on Windows 7 with the PowerShell. Python 2.7 and the path > > to django-admin.py is stored in my PATH variable. > > > After creating a project I can make use of the various manage.py > > commands in my PowerShell. However, only in the following way: > > > 'python manage.py runserver' > > > If I only type '.\manage.py runserver' then a new CMD window is opened > > running again 'python manage.py runserver'. That is, the command is > > forwarded to the CMD shell which opens it with the Python > > interpreter. > > > Is there any way to tell the PowerShell to interpret the command given > > within the shell instead of launching a CMD window? > > > Regards, > > > Robert > > You might also want to ask on a powershell or windows forum. > > Whilst you are trying to do stuff with django, you're looking for > python users who run windows (most don't) and use powershell instead > of python to write scripts. I'd imagine that is a very small subset, > particularly on this list. > > Cheers > > Tom -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Re: Running manage.py commands in Windows Power Shell
On Wed, Mar 14, 2012 at 5:35 PM, orschirowrote: > Hello, > > I have a question which is based on the discussion here: > > http://groups.google.com/group/django-users/browse_thread/thread/2333f5dc8d0674f0 > > I'm working on Windows 7 with the PowerShell. Python 2.7 and the path > to django-admin.py is stored in my PATH variable. > > After creating a project I can make use of the various manage.py > commands in my PowerShell. However, only in the following way: > > 'python manage.py runserver' > > If I only type '.\manage.py runserver' then a new CMD window is opened > running again 'python manage.py runserver'. That is, the command is > forwarded to the CMD shell which opens it with the Python > interpreter. > > Is there any way to tell the PowerShell to interpret the command given > within the shell instead of launching a CMD window? > > Regards, > > Robert > You might also want to ask on a powershell or windows forum. Whilst you are trying to do stuff with django, you're looking for python users who run windows (most don't) and use powershell instead of python to write scripts. I'd imagine that is a very small subset, particularly on this list. Cheers Tom -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Running manage.py commands in Windows Power Shell
Hello, I have a question which is based on the discussion here: http://groups.google.com/group/django-users/browse_thread/thread/2333f5dc8d0674f0 I'm working on Windows 7 with the PowerShell. Python 2.7 and the path to django-admin.py is stored in my PATH variable. After creating a project I can make use of the various manage.py commands in my PowerShell. However, only in the following way: 'python manage.py runserver' If I only type '.\manage.py runserver' then a new CMD window is opened running again 'python manage.py runserver'. That is, the command is forwarded to the CMD shell which opens it with the Python interpreter. Is there any way to tell the PowerShell to interpret the command given within the shell instead of launching a CMD window? Regards, Robert -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.