473,394 Members | 1,750 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Yes, this is a python question,and a serious one at that (moving to Win XP)

For unfortunate reasons, I'm considering switching back to Win XP
(from OS X) as my "main" system. Windows has so many annoyances that
I can only compare it to driving in the Bay Area at rush hour (OS X
is like driving in Portland at rush hour--not as bad, but getting
there), but there are really only a couple of things that are really,
absolutely preventing me from making the switch. Number one is the
lack of a decent command line and command-line environment, and I'm
wondering (hoping) if perhaps someone has written a "Python shell"--
something that will look like a regular shell, let users type in
commands, maybe have some of the nice features of bash etc. like tab
completion, etc, and will then execute an underlying python script
when the command is entered. I'm not thinking of IDLE, but something
that is really aimed more at being a system terminal, not a Python-
specific terminal.

Yes, I know that Cygwin is out there, but last I looked, they still
went through the Win command-line window, which imposes a lot of
restrictions.

More generally, has anyone written any python programs to administer
various Win settings for which one must otherwise delve deep into
mazes of twisty little dialogs, all alike? Or to help out with other
annoyances? I know there are a lot of general utilities, but if
they're in Python, I can also use them as a starting base for my own
needs.

Finally, a significant incentive in doing this is that I could avoid
a lot of installation hassle, since virtually everything has at least
a decent installation package for Win. (I'd hoped this would happen
for OS X, but it never has). Can anyone think of important python-
related packages (release level, not cutting edge alphas) for which
this might not be the case?

Many thanks,
Ken
Oct 13 '05 #1
16 2201
What I can point you to is not Python, but embedding it in Python
is a question of executing one line of Python code triggering its
execution.
I think you will be fascinated by its features and ease of use and
how well it is suited to fit into your needs:
http://www.autoitscript.com/autoit3/index.php
With it you will start to see, that forcing to obey to Windows way
of doing things has not only bad sides.

Is there something similar for another OSs-es (especially Linux)?

Claudio

"Kenneth McDonald" <ke****************@sbcglobal.net> schrieb im Newsbeitrag
news:ma*************************************@pytho n.org...
For unfortunate reasons, I'm considering switching back to Win XP
(from OS X) as my "main" system. Windows has so many annoyances that
I can only compare it to driving in the Bay Area at rush hour (OS X
is like driving in Portland at rush hour--not as bad, but getting
there), but there are really only a couple of things that are really,
absolutely preventing me from making the switch. Number one is the
lack of a decent command line and command-line environment, and I'm
wondering (hoping) if perhaps someone has written a "Python shell"--
something that will look like a regular shell, let users type in
commands, maybe have some of the nice features of bash etc. like tab
completion, etc, and will then execute an underlying python script
when the command is entered. I'm not thinking of IDLE, but something
that is really aimed more at being a system terminal, not a Python-
specific terminal.

Yes, I know that Cygwin is out there, but last I looked, they still
went through the Win command-line window, which imposes a lot of
restrictions.

More generally, has anyone written any python programs to administer
various Win settings for which one must otherwise delve deep into
mazes of twisty little dialogs, all alike? Or to help out with other
annoyances? I know there are a lot of general utilities, but if
they're in Python, I can also use them as a starting base for my own
needs.

Finally, a significant incentive in doing this is that I could avoid
a lot of installation hassle, since virtually everything has at least
a decent installation package for Win. (I'd hoped this would happen
for OS X, but it never has). Can anyone think of important python-
related packages (release level, not cutting edge alphas) for which
this might not be the case?

Many thanks,
Ken

Oct 13 '05 #2
Kenneth McDonald a écrit :
For unfortunate reasons, I'm considering switching back to Win XP (from
OS X) as my "main" system. Windows has so many annoyances that I can
only compare it to driving in the Bay Area at rush hour (OS X is like
driving in Portland at rush hour--not as bad, but getting there), but
there are really only a couple of things that are really, absolutely
preventing me from making the switch. Number one is the lack of a
decent command line and command-line environment, and I'm wondering
(hoping) if perhaps someone has written a "Python shell"-- something
that will look like a regular shell, let users type in commands, maybe
have some of the nice features of bash etc. like tab completion, etc,
and will then execute an underlying python script when the command is
entered. I'm not thinking of IDLE, but something that is really aimed
more at being a system terminal, not a Python- specific terminal.

Yes, I know that Cygwin is out there, but last I looked, they still
went through the Win command-line window, which imposes a lot of
restrictions.

More generally, has anyone written any python programs to administer
various Win settings for which one must otherwise delve deep into mazes
of twisty little dialogs, all alike? Or to help out with other
annoyances? I know there are a lot of general utilities, but if they're
in Python, I can also use them as a starting base for my own needs.

Finally, a significant incentive in doing this is that I could avoid a
lot of installation hassle, since virtually everything has at least a
decent installation package for Win. (I'd hoped this would happen for
OS X, but it never has). Can anyone think of important python- related
packages (release level, not cutting edge alphas) for which this might
not be the case?

Many thanks,
Ken


Last time I checked, you could install a native win32gui version of rxvt
with cygwin. This would give you a better terminal window than that
crappy thing you get in XP.
Oct 14 '05 #3
> Kenneth McDonald a écrit :
For unfortunate reasons, I'm considering switching back to Win XP (from
OS X) as my "main" system. Windows has so many annoyances that I can
only compare it to driving in the Bay Area at rush hour (OS X is like
driving in Portland at rush hour--not as bad, but getting there), but
there are really only a couple of things that are really, absolutely
preventing me from making the switch. Number one is the lack of a
decent command line and command-line environment, and I'm wondering
(hoping) if perhaps someone has written a "Python shell"-- something
that will look like a regular shell, let users type in commands, maybe
have some of the nice features of bash etc. like tab completion, etc,
and will then execute an underlying python script when the command is
entered. I'm not thinking of IDLE, but something that is really aimed
more at being a system terminal, not a Python- specific terminal.

Yes, I know that Cygwin is out there, but last I looked, they still
went through the Win command-line window, which imposes a lot of
restrictions.


You can look at ipython: http://ipython.scipy.org. Its 'pysh' profile does
much of what you describe, and has a dedicated following of win32 users
precisely for your usage case. It gets installed to your start menu under
win32 as a separate entry from the 'raw' ipython.

Stop by the users list if you have further questions.

Cheers,

f

Oct 14 '05 #4
On Fri, 14 Oct 2005 12:37:25 +0200, Christophe <ch*************@free.fr> wrote:
Kenneth McDonald a écrit :
For unfortunate reasons, I'm considering switching back to Win XP (from
OS X) as my "main" system. Windows has so many annoyances that I can .... Yes, I know that Cygwin is out there, but last I looked, they still
went through the Win command-line window, which imposes a lot of
restrictions.
.... Last time I checked, you could install a native win32gui version of rxvt
with cygwin. This would give you a better terminal window than that
crappy thing you get in XP.


Last time /I/ checked (two years ago or so) that rxvt looked nice enough,
but was impossible to use in practice. I cannot remember /what/ the problem
was -- possibly it was that it could only run CygWin-compiled commands, or
something vital only worked with CygWin-compiled commands. Google probably
knows more.

I wouldn't be surprised if this has improved since then, or if someone else
has come up with a serious Win32 terminal. There is surely a need for one!

/Jorgen

--
// Jorgen Grahn <jgrahn@ Ph'nglui mglw'nafh Cthulhu
\X/ algonet.se> R'lyeh wgah'nagl fhtagn!
Oct 15 '05 #5
Hi Claudio,
I fully agree with you. I already used AutoIt 3 but when I moved to
Linux I wasn't able to find anything similar.
I moved also to Python for its power but also if it is called a
scripting language it doesn't simply interact with graphical
applications. As a last resort I tried DCOP (Desktop COmmunication
Protocol) to at least interact
(also from Python) with KDE applications. But even there it is
impossible to send a simulated keystroke to a running KDE application
(for ex. the konqueror browser).
Also if I will not switch back to Windows, when I have macro and
automation problems I am obliged to use XP (I have double boot...).
Bye.

Oct 17 '05 #6
Jorgen Grahn wrote:
On Fri, 14 Oct 2005 12:37:25 +0200, Christophe <ch*************@free.fr> wrote:
Kenneth McDonald a écrit :
For unfortunate reasons, I'm considering switching back to Win XP (from
OS X) as my "main" system. Windows has so many annoyances that I can ... Yes, I know that Cygwin is out there, but last I looked, they still
went through the Win command-line window, which imposes a lot of
restrictions.

...
Last time I checked, you could install a native win32gui version of rxvt
with cygwin. This would give you a better terminal window than that
crappy thing you get in XP.


Last time /I/ checked (two years ago or so) that rxvt looked nice enough,
but was impossible to use in practice. I cannot remember /what/ the problem
was -- possibly it was that it could only run CygWin-compiled commands, or
something vital only worked with CygWin-compiled commands. Google probably
knows more.


Cygwin comes with a fully-functioning X server, from which you can run
just about any terminal program you like. For awhile, I was using
Konsole, but KDE on Cygwin is a bit slow and buggy. Recently I switched
to "mrxvt", which is like "rxvt" but with tab support and keyboard
shortcuts almost identical to Konsole. It's easy to compile for Cygwin,
and so far I'm really enjoying the improved speed. Here's my .mrxvtrc:

mrxvt*bottomTabbar: true
mrxvt*scrollBar: false
mrxvt*font: neep-alt-bold-14
mrxvt*boldFont: neep-alt-bold-14
mrxvt*foreground: snow
mrxvt*background: black
mrxvt*geometry: 80x40
mrxvt*saveLines: 65535
mrxvt*hotkey*Dummy: Ctrl+Shift+underscore

I like my tabs at the bottom, Konsole-style, and don't really like
scrollbars on terminals. I use the Neep Alt font, which is nice for
coding because it makes 'l', '|', '1', etc. all look different, and I
like thick console fonts. I was a Fixedsys diehard for a long time. The
"saveLines" variable lets you increase the scrollback buffer
(shift-PgUp/Down) pretty high - I have it maxxed out. And that last
line tells mrxvt to ignore C-_, which is undo in emacs. There are still
a few other keyboard bindings that I'd like to turn off at some point.

One drawback of mrxvt is that it doesn't support UTF-8. I don't do much
multi-language stuff, but on most Linux distributions the manpages are
in UTF-8, so you get garbage characters unless you fiddle with your
LANG/LOCALE settings.

Oh yeah, and to keep this on topic, Cygwin's Python works just fine in
mrxvt, though the native Windows version doesn't work so well. It
doesn't print any output, which I think is due to buffering... however,
I tend to use PythonWin for interactive development, and emacs with M-x
shell to actually test and run (native) Python scripts. I'm pretty
happy with it, overall.

Dave

Oct 17 '05 #7
Hmm. I'm not sure what bothered you about cygwin, but if it has been
awhile it's worth another look. For me it makes windows tolerable, and
even productive.

I'm scared more by your thoughts of transitioning from OS-X to windows.
I've seen a bit of OS-X and am slowly be warmed up to it as an option
for my next machine by some folks here. What is causing you problems
with it ( enough to swtich to windows-wow.)?

Oct 18 '05 #8
The shell that comes with MSys (from the MinGW guys). Is pretty good, although
it does have a bit of a problem with stdout output before a process exits, ie
it will hold back output until the process exits.

As a bonus, the file system is a little more sane, and if you are interested
in compiling software that is not open source, you are not tied to the Cygwin
DLL which is GPLed.

I have given up on Cygwin in favour of the tools that come with MSys because
they seem slightly better suited to the windows environment.

-Chris

On Sat, Oct 15, 2005 at 08:45:17AM +0000, Jorgen Grahn wrote:
On Fri, 14 Oct 2005 12:37:25 +0200, Christophe <ch*************@free.fr> wrote:
Kenneth McDonald a ?crit :
For unfortunate reasons, I'm considering switching back to Win XP (from
OS X) as my "main" system. Windows has so many annoyances that I can ... Yes, I know that Cygwin is out there, but last I looked, they still
went through the Win command-line window, which imposes a lot of
restrictions.

...
Last time I checked, you could install a native win32gui version of rxvt
with cygwin. This would give you a better terminal window than that
crappy thing you get in XP.


Last time /I/ checked (two years ago or so) that rxvt looked nice enough,
but was impossible to use in practice. I cannot remember /what/ the problem
was -- possibly it was that it could only run CygWin-compiled commands, or
something vital only worked with CygWin-compiled commands. Google probably
knows more.

I wouldn't be surprised if this has improved since then, or if someone else
has come up with a serious Win32 terminal. There is surely a need for one!

/Jorgen

--
// Jorgen Grahn <jgrahn@ Ph'nglui mglw'nafh Cthulhu
\X/ algonet.se> R'lyeh wgah'nagl fhtagn!
--
http://mail.python.org/mailman/listinfo/python-list

Oct 18 '05 #9
Chris Lambacher wrote:
The shell that comes with MSys (from the MinGW guys). Is pretty good, although
it does have a bit of a problem with stdout output before a process exits, ie
it will hold back output until the process exits.

As a bonus, the file system is a little more sane, and if you are interested
in compiling software that is not open source, you are not tied to the Cygwin
DLL which is GPLed.


Worth mentioning here that cygwin's gcc does allow a -mno-cygwin
compile-time flag to not link against the cygwin dll. Cygwin's
packaging system also includes the MinGW development libraries as an
easily installable option, for compiling against mingw's stuff; I've
done it for Python extensions, in fact.
Oct 19 '05 #10
Try 4NT (http://www.jpsoft.com). It is like cmd on steroids. I've
been using it for years and it is the *only* thing that makes powerful
batch files possible on Windows. It has a slew of features, including
batch file debugging.

Oct 19 '05 #11
The OP is obviously a troll. Or he doesn't realize that you can use any shell
in OSX as the user default. I used OSX for 4 years and had to go 100% Linux
because of my employer. OSX is the best of Linux and Windows--anybody who
can't see that has obviously not worked with these three types of operating
systems enough and is basing conclusions on limited information...Or is a
troll. The OP probably works for microsoft.

James

--
James Stroud
UCLA-DOE Institute for Genomics and Proteomics
Box 951570
Los Angeles, CA 90095

http://www.jamesstroud.com/
Oct 19 '05 #12
On 19/10/05, James Stroud <js*****@mbi.ucla.edu> wrote:
The OP is obviously a troll.


Hey - let's not throw the T word around quite so freely. The OP did
say that he was switching to Windows "for unfortunate reasons", and
that OSX was "not as bad" as Windows.

Besides, it is possible to prefer Windows. Odd, but possible. Having
moved from Windows to Mac recently myself, I know *I* won't be
switching back, but reasonable men can differ.

--
Though-clearly-not-differ-with-me-ly y'rs,
Simon B.
Oct 19 '05 #13
ro**********@gmail.com wrote:
Try 4NT (http://www.jpsoft.com). It is like cmd on steroids. I've
been using it for years and it is the *only* thing that makes powerful
batch files possible on Windows.


why bother with "powerful batch files" when you can use a real programming
language ?

</F>

Oct 19 '05 #14
First, my apologies. You sound sincere.

But, in my defense to jump to conclusions and comparisons:

(1) You compared first:

"Windows has so many annoyances that I can only compare it...Bay
Area...OS X...Portland..."

(2) "Unfortunate reasons" can not necessarily be interpreted as "beyond my
control". For instance, elected officials take office many times for
"unfortunate reasons." Not the least of which is often the ignorance of
the populace.

I propose that any time anyone suggests switching to Windows, the reasons for
such should be explicitly described, and not left to interpretation.

James

On Wednesday 19 October 2005 14:31, Kenneth McDonald wrote:
Perhaps you didn't read my original post? I'm being forced to
consider Windows
for reasons beyond my control. Given that I wanted a decent shell in
Windows,
I thought I would ask about Python shells because I think Python is a
great language,
and such a beast would give me the flexibility I want on a machine I
don't want to
use.

There is such a shell (though with a fifty page manual it'll be a
little while before
I start using it :-) ). End of matter, except for those who wish to
discuss further
Pythonish/shell related issues. Why this demands an OS comparison and an
insult is beyond my understanding.

Ken

On 19-Oct-05, at 2:22 PM, James Stroud wrote:
The OP is obviously a troll. Or he doesn't realize that you can use
any shell
in OSX as the user default. I used OSX for 4 years and had to go
100% Linux
because of my employer. OSX is the best of Linux and Windows--
anybody who
can't see that has obviously not worked with these three types of
operating
systems enough and is basing conclusions on limited
information...Or is a
troll. The OP probably works for microsoft.

James


--
James Stroud
UCLA-DOE Institute for Genomics and Proteomics
Box 951570
Los Angeles, CA 90095

http://www.jamesstroud.com/
Oct 19 '05 #15
James Stroud wrote:
I propose that any time anyone suggests switching to Windows, the reasons for
such should be explicitly described, and not left to interpretation.


I propose that any time anyone suggests switching to Linux ...
I propose that any time anyone suggests switching to Mac ...
I propose that any time anyone suggests switching to Ruby ...
I propose that any time anyone suggests switching to Firefox ...
I propose that any time anyone suggests switching to Waxed Dental Floss ...

People should not feel *required* to justify their decisions to c.l.py,
especially if they are not trying to evangelize that choice. (FWIW, even
from the original post it's very apparent that he's dissuading people
from joining him.)

It is true that giving the reasons for a choice will help responders put
some perspective on it, and perhaps prompt a few alternatives, but
c.l.py is not your mother, and shouldn't require you to justify the
validity of your lifestyle to it.
Oct 20 '05 #16
Rocco Moretti wrote:
James Stroud wrote:

I propose that any time anyone suggests switching to Windows, the reasons for
such should be explicitly described, and not left to interpretation.

I propose that any time anyone suggests switching to Linux ...
I propose that any time anyone suggests switching to Mac ...
I propose that any time anyone suggests switching to Ruby ...
I propose that any time anyone suggests switching to Firefox ...
I propose that any time anyone suggests switching to Waxed Dental Floss ...

People should not feel *required* to justify their decisions to c.l.py,
especially if they are not trying to evangelize that choice. (FWIW, even
from the original post it's very apparent that he's dissuading people
from joining him.)

It is true that giving the reasons for a choice will help responders put
some perspective on it, and perhaps prompt a few alternatives, but
c.l.py is not your mother, and shouldn't require you to justify the
validity of your lifestyle to it.


Man, you mean I can use any dental floss I like?!?!?!?!!?

regards
Steve

who quite agrees with the sentiments expressed above
(it's an extension of the "consenting adults" philosophy).
--
Steve Holden +44 150 684 7255 +1 800 494 3119
Holden Web LLC www.holdenweb.com
PyCon TX 2006 www.python.org/pycon/

Oct 20 '05 #17

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

699
by: mike420 | last post by:
I think everyone who used Python will agree that its syntax is the best thing going for it. It is very readable and easy for everyone to learn. But, Python does not a have very good macro...
10
by: 2mc | last post by:
I'm new to Python and to Numerical Python. I have a program written in another program that used arrays extensively. I'm trying to convert to Python. Assume an array in Numerical Python, the...
226
by: Stephen C. Waterbury | last post by:
This seems like it ought to work, according to the description of reduce(), but it doesn't. Is this a bug, or am I missing something? Python 2.3.2 (#1, Oct 20 2003, 01:04:35) on linux2 Type...
17
by: seb.haase | last post by:
Hi, Is it true that that "Python 3000" is dead ? Honestly I think that e.g. changing 5/2 to be 2.5 (instead of 2) would just break to much code :-( On the otherhand I'm using Python as "Matlab...
112
by: mystilleef | last post by:
Hello, What is the Pythonic way of implementing getters and setters. I've heard people say the use of accessors is not Pythonic. But why? And what is the alternative? I refrain from using them...
270
by: Jordan | last post by:
Hi everyone, I'm a big Python fan who used to be involved semi regularly in comp.lang.python (lots of lurking, occasional posting) but kind of trailed off a bit. I just wrote a frustration...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.