jbev2328:

That sounds like a path issue. If you're wanting cygwin to use your Strawberry perl and not the other perl, then in your .bashrc or .bash_profile you can remove the other vendor's bin directories from your PATH. For example, at $work, I needed to edit the PATH, so I put this in my .bashrc:

#20110309 - Remove irrelevent entries from $PATH PATH=`bin/path_filter.pl` PATH=$PATH:~/bin export PATH

And then in my local bin directory, I put in a little script to patch up PATH as I wanted. (I didn't use anything fancy, so it doesn't matter which perl you run it under.

#!/usr/bin/perl # # path_filter.pl - parse the PATH variable, and return a new path str +ing with all # the duplicates removed, and any entries in the IGNORE hash removed. # # Win/DOS doesn't care much about case sensitivity, so we'll map ever +ything to lower # case on storage so we can remove dups in different cases (specifica +lly for the # case of C:\Windows\System32 vs C:\Windows\system32) # # 20110309 roboticus use strict; use warnings; my $DBG=0; my %IGNORE = map { lc($_)=>0 } ( "/DOS/c/Program Files/TortoiseSVN/bin", "/DOS/c/Program Files/QuickTime/QTSystem", "/DOS/c/WINDOWS/system32/WindowsPowerShell/v1.0", . . . snip! . . . # WBEM=Web-Based Enterprise Management (WMI), not likely neede +d in Cygwin "/DOS/c/WINDOWS/System32/Wbem", ); my %DUP = (); my @Path = split /:/, $ENV{PATH}; my @NewPath = (); for my $dir (@Path) { if (! -d $dir) { print STDERR "MISSING: $dir\n" if $DBG; } elsif (exists $IGNORE{lc $dir}) { ++$IGNORE{$dir}; print STDERR "IGNORED: $dir\n" if $DBG; } elsif (exists $DUP{lc $dir}) { print STDERR "DUP: $dir\n" if $DBG; ++$DUP{lc $dir}; } else { print STDERR "ADDED: $dir\n" if $DBG; $DUP{lc $dir}=0; push @NewPath, $dir; } } # Output the new PATH variable print join(":", @NewPath);

Once you fix that, though, you may find another annoyance. (I'd be more specific, but it's been a while since I tried using Strawberry perl in a cygwin environment. I think it was some directory name translation issues, but I don't remember for certain.)

...roboticus

When your only tool is a hammer, all problems look like your thumb.


In reply to Re: Perl on Windows 2008 R2 by roboticus
in thread Perl on Windows 2008 R2 by jbev2328

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.