At 11:00 +0900 2000.09.26, Joel Rees wrote: >Adding options to cp is probably not a good idea. Better to write your >own cp with newline filtering options. Or, better still, just save the >one-liner Chris mentions here as a script (say, newlnfilter) and pipe I/O >that needs to be filtered through your brand-new filter: > > % cat source.pl | newlnfilter > target.pl > >Which points out the killer problem (killer solution waiting to be found) >hidden behind the excitement about scripting. With true scripting, >program options don't have to be added. The desired effects can be >achieved by external filter programs. Non-algebraically minded users tend >to blur the distinction between option and filter, but that's no big >deal. (Well, maybe it's a pride issue for some engineers and >theoreticians like myself about ten years ago.) That's all true, but I specifically had in mind the h* tools I used to use in the MkLinux distributions, like hcp that would do newline conversions for you and copy from mounted HFS volumes. I don't really care what method is used, except insofar as Joe User has an easy go of it. >>Also note: perl 5.6 comes with Mac OS X Beta, but there is no perldoc, >>pod2man, etc. Of course, there are no compilers or other build tools, >>either (yet; I understand they will be made available). > >I wonder why. I see lots of pods and manpages about perl. The source code >should be easy enough to compile. License issues? Well, I imagine the perldoc/pod2man/etc. omissions were oversights. They are just perl programs that need to be run: perl pod2man.PL cp pod2man /usr/bin So it is not hard. :-) As to the build tools (cc, make, etc.), those I expect to see in a distribution for us Mac OS X Beta users at some point in the near future. >>Well, I see little or no need for the MacPerl application. As for >>droplets, well, they would be pretty simple to create in Mac OS X. Now, >>here is the bad news: I made a perl script executable (chmod a+x), but it >>appears as a text file. This is Bad. However, I imagine it would be >>mostly trivial to create an executable wrapper for the script, just like >>the current droplet code, which would send the script and the dropped >>contents to /usr/bin/perl instead of MacPerl. > >Ahh! I see you have run into one of the walls between UNIX and Mac. While >you would not want chmod to mess with the actual contents of the file, >you might hope that the system commands for UNIX would influence the Mac >side's interpretation of a file. But this would basically require the Mac >OS version of chmod to build the underlying package structure around the >file being converted to executable, move the file down in the directory >structure, and generate an alias in the file's original position. I don't see why. Why couldn't the Desktop app just see that it is +x, and then allow me to drop files on it, and when I do, launch a terminal, chdir to where the original file is, and run the executable with that file? It doesn't seem Hard to me at all to do that much. For extra points, a terminal window would only actually come up if there was output from the program; otherwise, it would just happen in the background. -- Chris Nandor pudge@pobox.com http://pudge.net/ Open Source Development Network pudge@osdn.com http://osdn.com/ # ===== Want to unsubscribe from this list? # ===== Send mail with body "unsubscribe" to macperl-request@macperl.org