Re: 500 Can't connect to search.cpan.org:80 (Bad protocol 'tcp') at web.plline 24.

From: Peter Wyzl (wyzelli_at_yahoo.com)
Date: 11/29/04


Date: Mon, 29 Nov 2004 12:02:54 GMT


"Michele Dondi" <bik.mido@tiscalinet.it> wrote in message
news:ih0mq0t6g8nsng397s94s39dkqd3mc2b9m@4ax.com...
: On Mon, 29 Nov 2004 08:47:52 GMT, "Peter Wyzl" <wyzelli@yahoo.com>
: wrote:
:
: >: > command.com and cmd.exe both understand / as well as \ for directory
: >: > seperators.
: >:
: >: Bull****. A / does not work as a directory separator in DOS or
Windoze,
: >: and never has -- it is a command options or "switch" designator:
: [...]
: >I beg to differ... the problem you have is with the dir command, not
: >cmd.exe.
: >
: >you can 'cd' to /junk
: >
: >you can cd to /junk/junk2 etc
: >
: >open (IN, 'c:/junk/junk2/file.txt') or die "Can't $!\n";
: >
: >works perfectly fine as well.
:
: I beg to differ... what you wrote is still BS, since it has nothing to
: do with command.com and/or cmd.exe: indeed Windows *APIs* do support
: both '/' and '\' as directory separators. You can even mix them in a
: single specification.
:
: >Since we are dealing with Perl, the context of the comment is important,
in
: >that a forward slash works perfectly well, in all instances except
accessing
:
: It works perfectly *within* perl[1]. Still this has NOTHING to do with
: either command.com or cmd.exe! Whatever the context of the comment can
: be, whatever we're dealing with, what you wrote about command.com and
: cmd.exe is WRONG, period.
:
: The examples you gave are wrong and misleading as they have nothing to
: do with any shell (apart a possible ambiguity with C<cd>, that could
: be interpreted as an internal Perl command or a shell one).
:
:
: [1] no matter if by means of some magic it does or directly by means
: of Windows APIs capabilities. I don't know which of the two is true,
: BTW...

Windows API.

To get back to the original comment, Bob said that as far as he knew it had
to have a literal backslash if Windows was looking at it. I countered that
this is not true. There are cases where Windows requires a literal
backslash (File::Find suffers from it) but it is not universally true. Bob
gave an example where a forward slash is not accepted (/ being a switch
delimiter) and I gave an example where it is. Within Perl / is accepted
because perl does the right thing. Stating that 'Windows requires a literal
backslash' is what was incorrect.

However, this was not intended to be a discussion about Windows or cmd.exe.
It WAS intended to be a discussion about what happens within [Pp]erl and
that / can be used as much as \\ in programs written in Perl. This enhances
readability and portability.

What I wrote about cmd.exe is not wrong, I gave an example that supported
that statement. This is NOT universal, and is not even the difference
between internal/external commands. However, the point I was making was
(trying to make?) is that / works in perl. Why you have to tell me I wrote
BS and then state the same thing is a little confusing to me.

-- 
Wyzelli
if (-e 'c:/windows/win.ini'){print 'Just another Perl Hacker'}; 


Relevant Pages

  • Thanks for the comments Jan. 25, 2006
    ... "shadow" operating system which is running behind Windows. ... Perl can then collect data from that program and do ... that by sending longer strings etc. to the Windows clipboard and then having ... SendKeysuse a Ctrl V command to paste the information to the text editor ...
    (comp.lang.perl.misc)
  • Re: executing from command line
    ... if fact it's a way to run a command remotely. ... >> I have a perl script that i would like to run it on a windows server. ... >opening up a security hole on the remote machine when you do this. ...
    (comp.lang.perl.misc)
  • Re: perl in Windows: using the "Send To" folder and perl
    ... this is not strictly a Perl question but ... ... > marked are supplied on the command line to the executable i.e. ... > I create my executable by writing a .bat file which in turn supplies ... You do not mention which Windows command shell you are using. ...
    (comp.lang.perl.misc)
  • RE: Could anyone please answer a simple PERL question.
    ... I have added a note regarding Windows XP at the end of it. ... I have assumed that you have installed the Active State perl with all the ... One way to get around this is to open a command window. ... You need to get to the "file types" section of windows - I'm in NT right ...
    (perl.beginners)
  • RE: re-setting boot partition
    ... Description of the Windows 2000 Recovery Console ... For a Microsoft Windows XP version of this article, ... MB of hard disk space on your system partition to hold the Cmdcons folder ... Windows NTBoot Console Command Interpreter. ...
    (microsoft.public.win2000.setup_upgrade)