I had the same problems. The readme talks about other required modules and then those
talk about others. It's a recursive exercise apparently done for us in the MacPerl
world. (Thanks Chris)
After a couple of hours I found my way thru CPAN getting one missing module at a time.
It appears that
Actually Chuck sent this to me. This is one of those lists that has a hangup about
changing the reply to: header so that it defaults to the list.
Someday I'll learn about bundles but as of now it's up to someone else to answer.
And - while were at it? Is there a document somewhere that talks
What is the official name of the operating system under MacOS neXt?
Where does perl get it?
I need it so that I can write perl and shell scripts that can be tested on a Mac and
then run under Solaris. I solicit comments on the most reliable way to keep things
working at least until next week.
We are getting somewhere here. I think I have to add code to support MacPerl and perl
running under Windoze or DOS. Perhaps Parrot/Perl6 will fix it all up.
Using MPW on MacOS 9.1
perl -v
This is perl, version 5.004
perl -e 'print `uname`;'
### ToolServer - Command uname was not found. (Not
At 16:30 -0800 11/19/02, Heather Madrone wrote:
I've already encountered a few text file anomalies on OS X. Most GUI applications
seem to default to Mac-style text files (linefeeds only),
I think that's returns only for Mac style. Don't be fooled by MPW's and perhaps
MacPerl's redefinition of \n
At 12:50 -0500 3/2/03, Bill Metzinger wrote:
perl: warning: Please check that your locale settings:
LC_ALL = (unset),
LANG = en
You need to create a plist file and a directory for it:
$HOME/.MacOSX/environment.plist
and set up LC_ALL and LANG there. Setting them in your .login,
Icon\r files appear when, in earlier Mac OS's, a folder - directory in UNIX parlance -
was to be displayed by Finder with a special icon. I'm pretty sure the files are
resource-only with no data fork.
You might try concatenating /..namedfork/rsrc to the path but if you do open it it
will be
At 07:19 -0700 9/15/03, Chris Nandor wrote, and I snipped:
$ cat Icon^M
foo
^C
$ perl -e 'open $fh, Icon\r or die $!; print scalar $fh'
No such file or directory at -e line 1.
# add null
$ perl -e 'open $fh, Icon\r\0 or die $!; print scalar $fh'
foo
The cat operation creates a
At 06:37 -0700 9/24/03, Mark Wheeler wrote:
#!/usr/bin/perl -w
use strict;
print Content-type: text/html\n\n;
print The contents of the file: brbr;
open (DATA, example.txt) || die (Could not open file br $!);
my @text = DATA;
print @text;
close (DATA);
exit;
If you're calling the script from
At 07:57 -0700 9/24/03, Mark Wheeler wrote:
Yes, I am running this as a cgi. I called it from a web browser. IE 6 on a
PC. Yes, the script has no Mac line endings. I wrote it on a PC using a text
editor.
Peecee's use a CR/LF pair for line ends.
If you uploaded it in ASCII mode with ftp it should
At 17:19 -0400 9/25/03, Kevin Barry wrote:
perl: warning: Please check that your locale settings:
LC_ALL = (unset),
LANG = en_US
environment.plist lives in $HOME/.MacOSX/ (with a leading dot)
It is read only at login time. And that means login to the OS neXt GUI and not login
via
At 21:54 +0200 9/26/03, Marco Baroni wrote:
suppose I had a question about extracting plain text from web pages with perl. Is
there an appropriate list for this sort of questions?
The perl / curl combination is great for just that. I'd like to talk about it.
--
-- There are 10 kinds of
At 01:58 -0700 9/28/03, Chris Cantrall wrote:
If your shell is tcsh, put the following 2 lines in your .tcshrc login/setup file.
setenv LANG en_US
setenv LC_ALL C
Remember though that your .login script will not be executed unless you log in to
Darwin using Terminal or externally with ssh.
The
At 12:03 +0100 10/13/03, Alan Fry wrote:
What I miss most is the MacPerl droplet, on which you could drop a file, extract the
path (into ARGV) and do something with the file. For instance I have a droplet to
decode Base64 -- drop and bingo there is the decoded file.
I do use AppleScript for
At 00:16 +0100 10/14/03, Alan Fry wrote:
do shell script /Users/alanfry/Desktop/backatcha.pl
results in the error:
...backatcha.pl:perl:bad interpreter:Permission denied
do shell script is misnamed as are a lot of other commands in AppleScript. What it
really means is
Tell the OS
At 09:56 -0400 10/16/03, Vic Norton wrote:
I have recently installed Perl 5.8.0 on my iMac via PortsManager from
DarwinPorts http://www.opendarwin.org/projects/darwinports/. Perl 5.8.0
resides in the /opt/local/bin directory, and this directory is at the
beginning of $PATH. Everything works well
At 16:12 -0700 10/16/03, Ingles, Juan W. wrote:
I wonder: Is this because
/opt/local/bin/perl points to the perl 5.6 binary
or
5.6 binary path is hard coded in BBEdit
I don't have any /opt/local/bin/. None was created by the CPAN perl 5.8 install in
July 2002
which perl
on the terminal will
2. If I must live with the current setup, how do I change my MANPATH
in bash. In tcsh I would simply put the line
setenv MANPATH /man:/usr/share/man: ... :${HOME}/man
Personally I would change my default to tcsh in Netinfo
But check out the export command in bash.
--
-- In
The || and or operators differ in the evaluation of their operands. It probably
doesn't matter in this particular case but don't be fooled into thinking they are the
same.
|| and are short circuit operators that may not evaluate all of their operands.
Programming Perl, 3rd edition,, page 102
At 20:20 +0100 11/23/03, Jerry Rocteur wrote:
Why would a Perl Module installation wipe out a standard UNIX program 'head' with a
head Perl script which is completely unrelated to the real 'head' ??
In the old days there was a problem with head and HEAD. The perl installer was
accustomed to a
At 04:32 -0500 11/25/03, Ari Kahn wrote:
I use the cp or ditto commands to accomplish the last part.
`cp $filename $chromat_dir`; #copy encountered file to the chromatograph_dir
`ditto $filename $chromat_dir/$file_prefix$file_suffix`;
I find that sometimes the sizes of the copied files are not
At 11:53 -0500 11/25/03, Ari Kahn wrote:
When I do a search for the original file, I find
.../../.AppleDouble/
What is an AppleDouble?
AppleDouble and AppleSingle are file formats which incorporate the resource fork and
the data fork and the finder information (type/creator and some other
It used to be, back in the days of Apple Classic, that the clipboard contained several
copies of the stuff that was placed there. Each copy was identified by one of those
four character type codes that are now deprecated in OS neXt.
pbpaste, as a tool, does not allow tor an argument for
At 13:52 -0500 1/11/04, Vic Norton wrote:
Now I seem to have resolved the problem--sort of. I believe it's a bug in BBEdit.
I suspect BareBones will call it a feature.
The unwillingness of BBEdit to work on a file without doing things like changing all
of the line ends has been a pain. It is
I just saw this on the AppleScript mailing list.
John is probably not a member of this list but I'll bet someone here can help off list.
Isn't there a module available?
To: [EMAIL PROTECTED]
From: John DeYoung [EMAIL PROTECTED]
Begin copy
Apologies for being a little off-topic...
At 12:57 +0100 1/15/04, Stephan Hochhaus wrote:
ps: How can I find out if a file is just a link from this:
-rwxr-xr-x 2 root wheel 19944 24 Sep 09:00 perl
try
cd /usr/bin
file perl
or
man file
--
-- There are 10 kinds of people: those who understand binary, and those who don't
--
At 17:53 +0100 1/21/04, manu chao wrote:
Hi, I just wanted to get started by following the tutorial at
http://www.mactipscafe.com/tip015/
but I get the following error:
'Exec format error. Binary file not executable.'
The web page seems to show a space between the exclamation point and the /.. I
At 16:59 -0500 1/23/04, [EMAIL PROTECTED] wrote:
do shell script perl /tmp/junk.pl
-- = Hello
I'm afraid I don't have a handle on the Mac OS Extended file system. When you
make the do shell call in Script Editor, as you demonstrated, where is the
origin of the filepath? I'm not successful with
At 10:55 -0600 2/3/04, Joseph Alotta wrote:
I am looking for someone to write a subroutine for me
involving graphics and pdf files.
Please reply to me offline with an email address that works.
I worry that the ~/ convention for the home directory is a shell convention. In the
first case it is expanded by the shell while in the other cases it's expanded by perl.
Does perl honor the option? When you say @INC is properly modified is the expansion
done in the list as displayed?
In
At 01:08 -0600 2/28/04, Chap Harrison wrote:
I am about to switch away from Applescript -- either that, or go mad.
Welcome to perl. You will be pleased.
It involves loading a Filemaker database.
I'm sorry for you. When Filemaker allows me to prepare a macro - er script - with a
text editor I
At 20:23 -0700 3/16/04, Joel Rees wrote:
I guess that 'll make it a sort of world of geocities minus the ads, lusers, l33tz,
and exploits. And google will run the yellow pages.
http://www.bellsystemmemorial.com/belllabs.html
We, in the USA, once had the best in the whole world.
--
-- The
At 10:10 -0500 5/22/04, Timothy Bailey wrote:
Oddly enough, shell scripts (which I am less familiar with) don't seem to pay
attention to the shebang line either. I am guessing that the problems are related.
You do have the execute bit set don't you?
chmod 755 yourScript
In any case it's not
At 15:06 -0400 6/6/04, Ingo Weiss wrote:
how can i make a Perl droplet (A Perl script that processes files or
folders dropped onto it) fast and easily?
One way is to write a three line AppleScript. An advantage - or disadvantage - is that
aliases and symbolic links will be resolved before you
At 09:16 -0400 7/27/04, Nick Pappas wrote:
When I type: perl /Documents/simple_print, I get the diagnostic
Can't open perl script /Documents/simple_print: No such file or directory
Your documents folder is probably in your home directory rather than on the root.
perl $HOME/Documents/simple_print
At 19:41 -0500 9/9/04, Ian Ragsdale wrote:
Shell worksheets (allows easy editing running of shell commands)
And there is by far the most important item. When the MacPerl port ran as an MPW tool
it looked a whole lot like UNIX perl and you could run it from a command line, with
arguments, and
At 07:46 -0700 10/3/04, wren argetlahm wrote:
all correspondence should be directed to
[EMAIL PROTECTED] off-list.
I'm not so sure about the OT designation.
Apple's Macintosh Programmer's Workshop (MPW) is the best programming environment I
have ever used. BBEdit worksheets are a start but are
At 22:44 -0500 12/25/04, Lola Lee wrote:
Nothing happens. This lesson that I'm working on is working from the premise
that people are using a Windows Perl installation.
Watch out for line ends in the source file that is being counted. Perl probably
doesn't care because the return-linefeed pair
At 22:23 + 1/5/05, John Delacour wrote:
If not then you need to consider your line endings.
And remember that MacPerl subscribes to the MPW convention that reverses the
meanings of \n and \r for the Mac.
ftp://ftp.macnauchtan.com/Software/LineEnds/FixEndsFolder.sit (52 kB)
At 08:08 -0400 7/29/05, Sherm Pendley wrote:
On Jul 28, 2005, at 11:10 PM, John Horner wrote:
What about a script run from BBEdit?
BBEdit is a GUI app, and GUI apps don't use your login shell. To define
environment variables to be used by GUI apps, have a look at this QA from
Apple:
BBEdit
At 15:15 + 12/22/05, James Harvard wrote:
I'm trying to detect a file's line endings (\r\n for DOS, \r for Mac
and \n for Unix as I'm sure y'all know).
ftp://ftp.macnauchtan.com/Software/LineEnds/FixEndsFolder.sit 52 kB
ftp://ftp.macnauchtan.com/Software/LineEnds/ReadMe_fixends.txt 4 kB
At 17:15 -0500 12/30/05, Vic Norton wrote:
A second question. When I run
for (sort keys %ENV) {
printf %25s = %s\n, $_, $ENV{$_};
}
from BBEdit, I see a small subset of the %ENV that comes from running
the script in Terminal. How can I make BBEdit's %ENV more like the
system %ENV?
I'm
At 12:15 -0600 1/5/06, The Ghost wrote:
How can I permanently add to @INC? I have 2 versions of perl installed and
only use one of them. The reason for 2 versions is a port system that
refuses to rely on the already installed perl.
Try setting the PERL5LIB environment variable. It's
At 13:29 -0600 1/17/06, Bill Stephenson wrote:
I want to write a script that faxes selected members of congress my humble
opinions ;)
You can send e-mail from perl and that leads to two options:
1) Send the email to efax (sp) where it can be converted to FAX and sent for a
fee.
2) Don't vote
While messing with CGI POSTed data I got trapped by this one.
Version 5.8.1-RC3 for Mac OS 10.3.9
It appears that the hash element D gets defined in the process of testing to
see if an element in the associated string is defined. The last if below takes
the else route.
Is that normal? Does it
At 08:41 -0700 4/5/06, Stewart Leicester wrote:
'defined' will autovivify, 'exists' will not. I'll leave it up to Doug to
decide if knowing that helps.
The Camel book, page 710 in the third edition is very clear that exists goes
the same way as defined. But perl has gone through a couple of
At 12:37 -0500 5/20/06, Joseph Alotta wrote:
I have this text file I want to read that has ^M as the record separator (in
emacs). Is there a utility on the Mac that i can use to view this file in
hex. I thought i remember something like hex filename, but it is not
there.
hexedit is a
If you want to adjust the line ends in the files have a look at:
ftp://ftp.macnauchtan.com/Software/LineEnds/FixEndsFolder.sit 52 kB
ftp://ftp.macnauchtan.com/Software/LineEnds/ReadMe_fixends.txt 4 kB
Yeah. It's pretty easy in perl too.
I have on occasion, read the first few hundred
At 09:59 +0800 7/26/06, Peter N Lewis wrote:
I'm interested in producing some drawings/diagrams/pictures based on 3D
data/objects generated from Perl. Something that would allow me to write code
that generates boxes, cylinders, spheres, etc with various colours and
material styles and generate
Perhaps I'm ranting but this IS an Apple based list.
In MacOS classic from M1, I can mount a folder that exists on M2 and another
folder that exists on M3.
Dragging a file, as an icon on a CRT connected to M1, from M2 to M3 goes
directly with no problem. I think it's because high level
At 18:29 -0700 8/5/06, [EMAIL PROTECTED] quoted:
On Aug 5, 2006, at 3:43 PM, Michael Barto wrote:
The issue is that the Math/GMP.pm is located in my development directory :
/Users/Mbarto/Development/Perl/GMP.pm
setenv PERL5LIB /Users/Mbarto/Development/Perl
At 17:03 +0100 8/24/06, David Cantrell wrote:
Run the CPAN shell as root as all will be well.
Idonwannadodat!
Although I have root privileges on all machines around here there are still two
of use who install things and I much prefer NOT to step on the War Department's
toes. She's the one who
At 19:39 +0100 8/24/06, John Delacour wrote:
All tests successful, 1 subtest skipped.
Files=18, Tests=503, 3 wallclock secs ( 1.75 cusr + 0.50 csys = 2.25 CPU)
/usr/bin/make test -- OK
Running make install
Installing /usr/local/lib/perl5/5.8.8/CGI.pm
Installing
At 08:53 -0500 1/10/07, Jay Savage wrote:
As I said before, you have two options here. Since reinstalling all
your Finked software manually probably isn't appealing, what you need
to do is use your .xinitrc file to setup the fink environment in X.
Either setup your PATH and PERL5LIB manually in
At 18:21 -0500 2/22/07, Vic Norton wrote:
So this is my question. How do I add /Library/Perl/5.8.6 to @INC, without
having to add
use lib /Library/Perl/5.8.6;
to every script ?
It's likely that there is abetter way, but. . .
If you define the environment variable PERL5LIB in your
The Camel book is a bit scary describing performance of filename globbing with
the *.pl or the glob(*.pl) syntax with or without use Cwd in the
preamble. Portability is declared questionable.
I find that the only thing that works is * within a loop where each file is
tested by hand.
Consider
The Camel book is a bit scary describing performance of filename globbing with
the *.pl or the glob(*.pl) syntax with or without use Cwd in the
preamble. Portability is declared questionable.
I find that the only thing that works is * within a loop where each file is
tested by hand.
Consider
At 18:20 -0700 10/15/07, Michael Barto wrote:
I think in the more newer languages, they have implemented true booleans. Perl
is kind of old school.
use constant TRUE = 1;
use constant FALSE = 0;
Is a complete solution in perl 5. There was once a reason back in the time of
grandfathered
At 21:29 -0500 11/30/07, Chas. Owens wrote:
The tr/// operator does not take a regex, it takes two strings.
Yep. Damn. What I meant to type is
$line =~ s/\+/ /g;
But that does explain why there was no error message.
Looking at Joel's code the substitute might still be the way to go.
--
--
At 01:56 + 12/1/07, Andy Holyer wrote:
On 1 Dec 2007, at 00:33, Joel Rees wrote:
This is probably the wrong list for this question, but is anyone willing to
give me a clue why
$line =~ tr/+/ /;
would clip out the lead bytes of a shift-JIS string in a cgi script?
what was just expressed,
At 17:03 +0900 12/1/07, Joel Rees wrote:
Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed
Message-Id: [EMAIL PROTECTED]
Content-Transfer-Encoding: 7bit
From: Joel Rees [EMAIL PROTECTED]
At 11:43 +0900 12/1/07, Joel Rees wrote:
Content-Type: text/plain; charset=ISO-2022-JP;
At 20:11 +0900 12/9/07, Peter N Lewis wrote:
At 19:01 -0500 8/12/07, Dan Neville wrote:
Does anyone know how to make a Mac OS alias in Perl? So, I wish to have Perl
create aliases in multiple directories rather than copy the original file.
There actually is no API call to create an alias file.
At 09:31 -0500 1/10/08, Dan Neville wrote:
I am writing an application in Perl and compiling it in CamelBones. I want to
make it a DragDrop. I can't get the pasteboard to pass the file or folder
information to the script. Does anyone have an example I could use as a
template?
If all of
At 03:15 + 1/21/08, [EMAIL PROTECTED] wrote:
Is there a module that will let one manipulate a Mac OS X pasteboard? There
does not seem to be anything on CPAN that strikes me as being for that purpose.
Have a look at the tools pbcopy and pbpaste that are delivered with OS neXt.
There is a
At 16:52 -0500 2/28/08, Jay Savage wrote:
On Thu, Feb 28, 2008 at 4:03 PM, Ben Crane [EMAIL PROTECTED] wrote:
I have a Perl 4.X script that runs using MacPerl in Classic on my G5
Mac but I can't get it to run using Perl in 10.4.11.
What do I need to do to make it run?
Thanks for any
Hashing of tools by shells has not been mentioned. It may not be part of the
problem but on invocation many, if not all, shells examine the $PATH variable
and make a table of executables that it finds. The table is then converted to a
hashed lookup array in order to improve speed of response.
At 08:43 +0100 8/23/08, Eberhard Lisse wrote:
7 open (trans, g5hd:newScansImages:trans) or die Error, can't open;
open (TRANS, /Volumes/g5hd/newScansImages/trans)
or die Error can't open $!\n;
Be really careful about that /Volumes/ directory. Apple uses it as a mount
point for external
At 18:17 -0400 8/25/08, David Green wrote:
Can't locate Mac/Glue/Common.pm in @INC
There is an environment variable PERL5LIB that can be set to add directories to
perl's default include path. It is, for instance, possible to add the library
from a previous install to @INC. There is some
At 18:23 -0400 9/7/08, Vic Norton wrote:
As far as I can tell Perl on a Mac pays absolutely no attention the
environmental variable PERL5LIB. I have eliminated all PERL5LIB specifications
on my machine.
You WILL have that problem if you try to define PERL5LIB as an environment
variable in
Mac OS neXt also provides for a file:
$HOME/.MacOSX/environment.plist. .If it's not present you can create
it and its hidden directory. Contents are environment variables that
you would like defined even if you haven't opened a Terminal.app
session. AppleScript's do shell script command,
At 20:25 + 3/10/09, John Delacour wrote:
At 21:10 -0600 9/3/09, Doug McNutt wrote:
At 22:24 -0400 3/9/09, Chris Devers wrote:
How can a Perl script reliably, portably resolve the path inside which
it is running?...
$0 That's a zero. Has always worked for me to produce a full path
At 23:22 +0100 9/12/09, Mine wrote:
Hi,
Thanks for your excellent response, makes installing so easy assuming I did
it correctly.
I think everything that was required is installed, but I am not sure
everything was installed
in the right location.
It appears that Perl 5.10.1 was installed and
Is it possible that some perl modules are not installed until Apple's developer
tools are installed?
--
-- A fair tax is one that you pay but I don't --
At 23:26 +0100 9/14/09, Mine wrote:
Is it possible to add the Perl 5.10.1 path to the environment so i
don't loose the MacPort option.
mkdir $HOME/.MacOSX
and put this, after changing it a bit, in the new folder. This is just a copy
of mine.
cat $HOME/.MacOSX/environment.plist
paste the
At 01:10 +0100 9/15/09, Mine wrote:
Hi Doug,
Thanks for the info, but I think this possibly way out side my level of
experience.
Would what you have suggested allow get_iplayer find the path to Perl 5.10.1
when I try to run get_iplayer from the terminal?
If it does then I don't fully
At 13:04 +0100 9/15/09, Mine wrote:
Hi Doug,
Just before I create the file I would like to check a few points.
but you should edit that so that the first directory, before the first
separating colon, is the one that perl 5.10 is in
I am not quite sure which is the main Perl folder.
At 22:10 +0100 9/16/09, Mine wrote:
Content-Transfer-Encoding: 7bit
Content-Type: text/plain;
charset=US-ASCII;
delsp=yes;
format=flowed
Hi,
I have Perl 5.8.8 installed by MacPorts and a CPAN install of 5.10.1.
Is there a simple way switch between them hopefully from the
I'm adding some comments between yours. To me the state of affairs reminds me
of the terrible problems I got into when first moving from MacPerl on OS 9 to
real perl on OS 10. With Fink, DarwinPorts, and CPAN I got really lost.
Darwin is now MacPorts and CPAN has been improved but I'm stuck on
Top posted :
Try using the pbcopy and pbpaste UNIX tools provided with Mac OS neXt or
perhaps Open BSD,
You can shell out using a line like this
$theclipboard = `pbpaste`;
man pbcopy or man pbpaste in Terminal.app for more.
At 21:54 -0700 5/9/10, Spencer Chase wrote:
sorry for posting to a
At 10:38 -0400 6/10/11, Sherm Pendley wrote:
On Fri, Jun 10, 2011 at 10:34 AM, John Delacour j...@bd8.com wrote:
What would be the effect of setting a value (or no value) for PERL5LIB in
~/.MacOSX/environment.plist?
That plist is for setting up environment variables for GUI apps. It
has no
80 matches
Mail list logo