I'd like to try Perl...

M

Marc Girod

I'd like to try Perl on Win 7 and according to this:http://www.perl.org/get.html, it's a choice between ActiveState,
Strawberry and DWIM.  Any advice on choosing between them would be welcome.

ActivePerl is compiled with a Microsoft compiler (the Visual C++
Express Edition is available for free), and Strawberry with a bundled
gcc.
This will impact the ease with which CPAN modules interfacing with
shared libraries will drop.

Note also the Cygwin option...

Marc
 
P

Peter Percival

Marc said:
ActivePerl is compiled with a Microsoft compiler (the Visual C++
Express Edition is available for free

I didn't know that. Thank you for drawing my attention to it.
), and Strawberry with a bundled
gcc.
This will impact the ease with which CPAN modules interfacing with
shared libraries will drop.

Maybe both then!
 
J

John Black

Note also the Cygwin option...

Yeah, spend a few minutes checking out the cygwin environment. I started with Strawberry
Perl and ended up removing it and installing cygwin. You get perl and tons more if you want.
You choose what you want installed or not installed but what you end up with is an
environment and set of tools that looks like and includes most of what you get with Unix. In
fact, when I'm in a cygwin terminal, I can pretty much behave as if its a unix window and
everything seems to work as I expect.

John Black
 
P

Peter Percival

Marc said:
Note also the Cygwin option...

I have Cygwin and did not realize that Perl was included :). I suspect
that's true of a lot of Cygwin things.
 
P

Peter Percival

Peter said:
I'd like to try Perl on Win 7 and according to this:
http://www.perl.org/get.html, it's a choice between ActiveState,
Strawberry and DWIM. Any advice on choosing between them would be welcome.

I have "Learning Perl on Win32 Systems" by Schwartz, Olson and
Christiansen. It's the right level for me, but I need something for
Windows 7 specifically, and suggestions?
 
J

Jürgen Exner

Peter Percival said:
I have "Learning Perl on Win32 Systems" by Schwartz, Olson and
Christiansen. It's the right level for me, but I need something for
Windows 7 specifically,

Luckily Perl is blissfully independant and ignorant of any OS version.
Therefore unless you are doing some very specialized coding for a
specific OS-version there is no need for any OS-version specific
learning.

jue
 
P

Peter Percival

Jürgen Exner said:
Luckily Perl is blissfully independant and ignorant of any OS version.
Therefore unless you are doing some very specialized coding for a
specific OS-version there is no need for any OS-version specific
learning.

Strawberry 5.16 seems not to understand

use Win32::NetAdmin;

I guess that's because Win 7 doesn't have a Win32, but I may have
misunderstood.
 
D

David Combs

Yeah, spend a few minutes checking out the cygwin environment. I started with Strawberry
Perl and ended up removing it and installing cygwin. You get perl and tons more if you want.
You choose what you want installed or not installed but what you end up with is an
environment and set of tools that looks like and includes most of what you get with Unix. In
fact, when I'm in a cygwin terminal, I can pretty much behave as if its a unix window and
everything seems to work as I expect.

John Black

Sorry, I use cygwin (via *shell* in emacs), but I don't know
what this "cygwin terminal" is. I probably would benefit
from it!

Any comments or help on it? Thanks!


---


One problem I have is getting the *cygwin* shell stuff to work:
(this is from some time ago, so I might have forgotten
a bit of what I did):

I (thought I) found that if I wanted to use pipes, variables,
etc within a cygwin shell (sh, tcsh (I believe), etc), then
I was required to use that horrible windows "cmd" black-and-white
window, which was really, really gross.

One problem I had was that I could not prepare IN EMACS a command
to execute there, and paste that command into that
horrible cmd window. Could only type it in there by hand,
character by character.

Likewise, I think I recall, it was difficult or impossible
to "copy" text from within that window (for pasting elsewhere);
copying and pasting simply didn't work in cmd windows.

Question: have you found a way to run cygwin shells, etc,
other than within a cmd window?

Question: have you found a way TO do copy, paste, etc
with a cmd window?

And, generally, how do people run the cygwin shells?
In what environment?


Question: how do they get the full features of one
of those shells to work, within emacs? Within, say,
*shell* or *eshell*?



THANKS MUCH FOR ANY HELP!

David
 
P

pepa

3.7.2013 13:48, Ben Morrow kirjoitti:
This is completely OT, but...

Quoth (e-mail address removed) (David Combs):

I believe it's just a cmd window running a Cygwin shell.

You seem to be trying to guess, Ben, in a way that is not very helpful.
Not this this time anyway.

There are multiple issues at hand here. For one, the "cygwin terminal"
that I would recommend is mintty.exe, which comes with cygwin by
default or bash.exe or any other shell executable, but mintty nowadays
is the recommended one. Next, my guess is that David either has not
found a way to configure Emacs to use a cygwin shell inside Emacs
– or David is using NTEmacs, not the emacs that comes with cygwin,
and therefore has the problem described in
http://www.emacswiki.org/emacs/NTEmacsWithCygwin#toc1. Since this
problem appeared, it has
been a pain to use any of the cygwin shells inside Emacs.
It is easier to open a separate window for command line stuff,
and for that purpose, I'd recommend mintty. But that's a matter
of taste.

In any case, the David's guestion doesn't belong here.
 
J

Jürgen Exner

Right-click on title bar, "Properties" -> tab "Colors".

Change settings once by right-click, "Properties", tab "Options", "Quick
Edit Mode".
Then highlight text by dragging the cursor over the text, copy
highlighted text by hitting "Enter", pasting from clipboard by mouse
right-click.

A typical case of know how to use your tools. CMD/BAT is certainly a
poor command language, but you shouldn't blame the tool for the problem
that is between chair and keyboard.

jue
 
P

pepa

Seconf attempt. Sorry Ben for sending privately. Meant to usenet.

3.7.2013 19:45, Ben Morrow kirjoitti:
Last time I used Cygwin (quite a while ago now) the 'Cygwin shell' link
installed on the Start Menu just opened a cmd window running Cygwin
bash. IIRC there were other options available--some sort of rxvt
port?--but they didn't work right. Pipes, in particular, tended to
misbehave.

Must e very very long ago, because I've never seen Cygwin providing cmd
by default. When I began with cygwin, the main interface was a bat that
invokes bash. It's still there but now the entry that the installer adds
to start menu invokes mintty.
Am I to assume from this that the 'no ptys' issue has been solved, or
worked around, and that mintty is a terminal emulator that works? Or is
it just a shell?

Now there is mintty, which provides better window management, but mintty
is not a shell (and you would not want to use it inside emacs, which I
should have already pointed out, but then, this is not an emacs forum).
I have never had pipe problems with cygwin, and I have no idea of what
you refer to when you talk about "the 'no ptys' issue". Which probably
just means you are more skillful than I am.

My best guess is still that David has not told Emacs which shell to run
when he wants shell. How to do that belogns to an emacs forum, not here,
however.
 
J

John Black

Sorry, I use cygwin (via *shell* in emacs), but I don't know
what this "cygwin terminal" is. I probably would benefit
from it!

We may be talking different languages but I will try to help. I don't know what "use cygwin
via shell in emacs" even means. I don't use emacs so that is perhaps why. But I've
installed cygwin and as part of that I got something (icon on my desktop) called Cygwin
Terminal. When I start one (and I can open as many as I want), I get a terminal running
bash. It runs bash by default but I think there is a way to run different shells. Like I
said, when I am in one of these terminals, its just like I'm running unix or linux.
Any comments or help on it? Thanks!


---


One problem I have is getting the *cygwin* shell stuff to work:
(this is from some time ago, so I might have forgotten
a bit of what I did):

I (thought I) found that if I wanted to use pipes, variables,
etc within a cygwin shell (sh, tcsh (I believe), etc), then
I was required to use that horrible windows "cmd" black-and-white
window, which was really, really gross.

Nope. You are right, that windows cmd window is crap. Thankfully I don't have to use it
since I have the cygwin terminal.
One problem I had was that I could not prepare IN EMACS a command
to execute there, and paste that command into that
horrible cmd window. Could only type it in there by hand,
character by character.

The cygwin terminal works just as many other unix terminal programs. Select a bunch of text
with the mouse. (and yes, you can select more than what fits on one screen Ben). Then
middle mouse button to paste. Easy.
Likewise, I think I recall, it was difficult or impossible
to "copy" text from within that window (for pasting elsewhere);
copying and pasting simply didn't work in cmd windows.

Copy paste in a cmd window is a pain, yes. Fortunately, we don't need cmd windows.
Question: have you found a way to run cygwin shells, etc,
other than within a cmd window?

yes. see above.
Question: have you found a way TO do copy, paste, etc
with a cmd window?

yes, see above.
And, generally, how do people run the cygwin shells?
In what environment?

I wish I knew what I did that you didn't do? How long has it been since you installed it?
When you install, make sure you have everything in the package called "Base".
Question: how do they get the full features of one
of those shells to work, within emacs? Within, say,
*shell* or *eshell*?

This I can't help with since I don't use emacs. I use Zues or vi.

John Black
 
J

John Black

This is completely OT, but...

Quoth (e-mail address removed) (David Combs):

I believe it's just a cmd window running a Cygwin shell.


This is expected on Windows. Because Windows doesn't have ptys, and
makes some distinction between 'console' and 'gui' applications, and for
other reasons I can't remember, it's never worth using any sort of
terminal emulator other than cmd.exe. They just never work properly.

(And cmd isn't *that* bad, at least if you make the font a bit bigger.
It's not what I'd call pleasant, but it's not unusable.)


Copy and paste in cmd.exe are found on the right-click menu on the icon
in the top-left of the window. (Yes, this is weird.) Copying is a
two-step process: first choose right-click/Edit/Mark, then select the
text you want to copy, then right-click/Edit/Copy. IIRC you can't copy
more than one (visible) screenful at a time.

Ug. Cygwin now comes with a cygwin terminal. You don't need cmd which sucks for copy paste
and everything else.
I stay as far away from Cygwin as possible. IME it has all the bugs of
Windows plus a whole lot more of its own.

I really like it. How long since you've tried it?
They don't. It can't be done on Windows, since there aren't any ptys.

Its been done. cygwin has it.

John Black
 
T

Tim McDaniel

Catching up on the newsgroup.

Hmm, glancing at that just confirms my opinion: mixing native Win32
facilities with ported-from-Unix facilities with Cygwin facilities
just leads to worlds of pain. Since, IME, native Win32 facilities
cannot be avoided entirely, this makes using Cygwin an exercise in
hacking around compatibility problems.

In my long experience with Cygwin, I use it for file processing (perl
and sed and pipes and such) and running some commands that it provides
(ssh, for example). I don't know what "Win32 facilities" might refer
to, but when it comes to files and using drive letters, Cygwin has
been perfectly usable.

From just the other replies I've seen, much of your other knowledge
is outdated or incomplete.
 
T

Tim McDaniel

Quoth (e-mail address removed):

Programs which are not Cygwin programs, and don't understand Cygwin
paths.

In practice, I haven't had much need for them, other than
double-clicking applications which therefore don't interact with
Cgywin at all, or just typing them at the Cygwin shell. But on the
command line,

... $(cygpath -w /some/cygwin/path) ...

produces something along the lines of

... C:\some\cygwin\path ...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top