From storm at iparadigms.com Mon Mar 1 14:57:51 2010 From: storm at iparadigms.com (Christian Storm) Date: Mon, 1 Mar 2010 14:57:51 -0800 Subject: [sf-perl] Computer Assisted Translation Message-ID: <3c2d02c91003011457w7a643328lc46375981a7c111d@mail.gmail.com> I was wondering if anyone out there had any recommendations for a good computer aided translation system? We're working with multiple translators and currently sending around spreadsheets which we then convert to po files. It is a management nightmare and is prone to error. We gave Pootle a shot but it wasn't up to snuff. Thanks ahead of time for any input. Cheers, Christian -------------- next part -------------- An HTML attachment was scrubbed... URL: From drforr at pobox.com Mon Mar 1 15:01:19 2010 From: drforr at pobox.com (drforr at pobox.com) Date: Mon, 01 Mar 2010 18:01:19 -0500 Subject: [sf-perl] Computer Assisted Translation In-Reply-To: <3c2d02c91003011457w7a643328lc46375981a7c111d@mail.gmail.com> References: <3c2d02c91003011457w7a643328lc46375981a7c111d@mail.gmail.com> Message-ID: <18b7a4f1022fc7194e446cfcb5ada00b@roundcube-imap.mailstore.pobox.com> On Mon, 1 Mar 2010 14:57:51 -0800, Christian Storm wrote: > I was wondering if anyone out there had any recommendations for a good > computer aided translation system? > We're working with multiple translators and currently sending around > spreadsheets which we then > convert to po files. It is a management nightmare and is prone to error. > We gave Pootle a shot but it wasn't up to snuff. "We" here includes me. I'll be watching the list for responses... > > Thanks ahead of time for any input. > > Cheers, > > Christian From extasia at extasia.org Tue Mar 2 20:35:12 2010 From: extasia at extasia.org (David Alban) Date: Tue, 2 Mar 2010 20:35:12 -0800 Subject: [sf-perl] determining console or xwindows mode In-Reply-To: <0816EB8D-A828-4C77-95AA-36B42CE5E703@fairpath.com> References: <489cf9d1002281822v15e08490geb86dbc465dc669d@mail.gmail.com> <0816EB8D-A828-4C77-95AA-36B42CE5E703@fairpath.com> Message-ID: <4c714a9c1003022035r57b5691dna7515351868197db@mail.gmail.com> caveat: you can be running under X and not have your $DISPLAY set. not optimal, but it happens. consider also checking for X11 libs and/or an X server process in the process table. On Sun, Feb 28, 2010 at 6:58 PM, Quinn Weaver wrote: > If you're running under X, the DISPLAY environment variable should be set. > So do: > > if ($ENV{DISPLAY}) { > ? ?... -- Live in a world of your own, but always welcome visitors. From quinn at fairpath.com Tue Mar 2 22:36:21 2010 From: quinn at fairpath.com (Quinn Weaver) Date: Tue, 2 Mar 2010 22:36:21 -0800 Subject: [sf-perl] determining console or xwindows mode In-Reply-To: <4c714a9c1003022035r57b5691dna7515351868197db@mail.gmail.com> References: <489cf9d1002281822v15e08490geb86dbc465dc669d@mail.gmail.com> <0816EB8D-A828-4C77-95AA-36B42CE5E703@fairpath.com> <4c714a9c1003022035r57b5691dna7515351868197db@mail.gmail.com> Message-ID: <6ebbd8771003022236j60cea1c4r15144b6f5fddb956@mail.gmail.com> On Tue, Mar 2, 2010 at 8:35 PM, David Alban wrote: > caveat: ?you can be running under X and not have your $DISPLAY set. > not optimal, but it happens. Really? And new windows or subprocesses still know what X client to connect to? > consider also checking for X11 libs and/or an X server process in the > process table. Hmnn, but you could have those and still not be running this particular process with X. Hmn. There has got to be a better way. One would think. BTW, Richard, if you want to do some more research on this, try the search term "X11" or "X Window System." Those are the officially blessed names. "X" is blessed too, but it's used for too many other things to be a useful search term. "X Windows" and variants are misnomers, so they're not likely to turn up anything. Thanks, -- Quinn Weaver Consulting, LLC Full-stack web design and development http://quinnweaver.com/ 510-520-5217 From sphink at gmail.com Wed Mar 3 00:34:05 2010 From: sphink at gmail.com (Steve Fink) Date: Wed, 3 Mar 2010 00:34:05 -0800 Subject: [sf-perl] determining console or xwindows mode In-Reply-To: <4c714a9c1003022035r57b5691dna7515351868197db@mail.gmail.com> References: <489cf9d1002281822v15e08490geb86dbc465dc669d@mail.gmail.com> <0816EB8D-A828-4C77-95AA-36B42CE5E703@fairpath.com> <4c714a9c1003022035r57b5691dna7515351868197db@mail.gmail.com> Message-ID: <7d7f2e8c1003030034p1c9e6d50lb5acdbd5b1ed927d@mail.gmail.com> On Tue, Mar 2, 2010 at 8:35 PM, David Alban wrote: > caveat: ?you can be running under X and not have your $DISPLAY set. > not optimal, but it happens. > > consider also checking for X11 libs and/or an X server process in the > process table. If DISPLAY is not set, then you wouldn't want to run in "X mode" anyway. In the first place, you probably can't, since I'm guessing "X mode" probably talks to the X server at some point. But even if not, I will sometimes intentionally unset DISPLAY in order to force things into text mode. (Usually because I am using SSH to port-forward some X client through a slow link, and I don't want my emacs processes to take several minutes to open up their graphical windows.) From quinn at fairpath.com Wed Mar 3 07:31:30 2010 From: quinn at fairpath.com (Quinn Weaver) Date: Wed, 3 Mar 2010 07:31:30 -0800 Subject: [sf-perl] determining console or xwindows mode In-Reply-To: <7d7f2e8c1003030034p1c9e6d50lb5acdbd5b1ed927d@mail.gmail.com> References: <489cf9d1002281822v15e08490geb86dbc465dc669d@mail.gmail.com> <0816EB8D-A828-4C77-95AA-36B42CE5E703@fairpath.com> <4c714a9c1003022035r57b5691dna7515351868197db@mail.gmail.com> <7d7f2e8c1003030034p1c9e6d50lb5acdbd5b1ed927d@mail.gmail.com> Message-ID: <655C9DBA-93F6-4DB9-9528-79C2C161BFC3@fairpath.com> On Mar 3, 2010, at 12:34 AM, Steve Fink wrote: > On Tue, Mar 2, 2010 at 8:35 PM, David Alban > wrote: >> caveat: you can be running under X and not have your $DISPLAY set. >> not optimal, but it happens. >> >> consider also checking for X11 libs and/or an X server process in the >> process table. > > If DISPLAY is not set, then you wouldn't want to run in "X mode" > anyway. In the first place, you probably can't, since I'm guessing "X > mode" probably talks to the X server at some point. But even if not, I > will sometimes intentionally unset DISPLAY in order to force things > into text mode. (Usually because I am using SSH to port-forward some X > client through a slow link, and I don't want my emacs processes to > take several minutes to open up their graphical windows.) I used to do that too. Nowadays,I just use 'emacs -nw', which has the same effect. Tangent: TRAMP is a great way to run emacs graphically while transparently operating on remote files. However, it can be tricky to set up (it's supposed to be capable of traversing firewalls using multiple ssh hops, but this hasn't always worked for me). Also, it's nice for sudo-editing local files without starting a new shell and editor. -- Quinn Weaver Consulting, LLC Full-stack web design and development http://quinnweaver.com/ 510-520-5217 From doom at kzsu.stanford.edu Wed Mar 3 11:14:13 2010 From: doom at kzsu.stanford.edu (Joe Brenner) Date: Wed, 03 Mar 2010 11:14:13 -0800 Subject: [sf-perl] determining console or xwindows mode In-Reply-To: <655C9DBA-93F6-4DB9-9528-79C2C161BFC3@fairpath.com> References: <489cf9d1002281822v15e08490geb86dbc465dc669d@mail.gmail.com> <0816EB8D-A828-4C77-95AA-36B42CE5E703@fairpath.com> <4c714a9c1003022035r57b5691dna7515351868197db@mail.gmail.com> <7d7f2e8c1003030034p1c9e6d50lb5acdbd5b1ed927d@mail.gmail.com> <655C9DBA-93F6-4DB9-9528-79C2C161BFC3@fairpath.com> Message-ID: <201003031914.o23JEDP6093927@kzsu.stanford.edu> Quinn Weaver wrote: > Tangent: TRAMP is a great way to run emacs graphically while > transparently operating on remote files. However, it can be tricky to > set up (it's supposed to be capable of traversing firewalls using > multiple ssh hops, but this hasn't always worked for me). I had some bad experiences with tramp silently mangling files, though that was in a place that was using a proprietary network file system that might've had something to do with it. I had much better luck using this approach: http://www.cpan.org/authors/id/R/RK/RKS/ange-ftp-over-ssh.1.1-script.pl And it's written in perl, too. (Emacs might be better off if they'd stop trying to do everything in one single-threaded process.) From gatorreina at gmail.com Thu Mar 4 07:07:11 2010 From: gatorreina at gmail.com (Richard Reina) Date: Thu, 4 Mar 2010 09:07:11 -0600 Subject: [sf-perl] simultaneous processes? Message-ID: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> I use evince to view a good number of tiff files. I have written a quick little script to help me associate the tiff files with various database records. This script runs as part of larger API that runs in a very minimal xwindows system ( no desktop just twm as a window manager.) As it stands now I view the file with system("evince file.tiff"); close evince and execute the script which helps me associate and save the file. I was wondering if there is a way to for my script to open a terminal while evince is still open so I can still look at the file while I'm saving it. I've tried system("evince file.tiff & gnome-teminal --geometry=50x35-0+0"); but then I don't see evince. Any help would be greatly appreciated. Thanks, Richard -------------- next part -------------- An HTML attachment was scrubbed... URL: From mgrimes at cpan.org Thu Mar 4 07:41:26 2010 From: mgrimes at cpan.org (Mark Grimes) Date: Thu, 4 Mar 2010 10:41:26 -0500 Subject: [sf-perl] simultaneous processes? In-Reply-To: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> References: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> Message-ID: <7c99e1971003040741k1f3ae821y36e6a5ccf113defc@mail.gmail.com> There are better ways of dealing with this (forking, one of the IPC modules, etc), but these are a quick and dirty way to do what you want: perl -e'system(q{sh -c "( xlogo & ) ; xlogo "});' perl -e'system(q{ ( xlogo & ) ; xlogo });' (Replacing the xlogo commands with evice and terminal, of course.) 2010/3/4 Richard Reina : > I use evince to view a good number of tiff files.? I have written a quick > little script to help me associate the tiff files with various database > records.? This script runs as part of larger API that runs in a very minimal > xwindows system ( no desktop just twm as a window manager.) As it stands now > I view the file with system("evince file.tiff"); close evince and execute > the script which helps me associate and save the file.? I was wondering if > there is a way to for my script to open a terminal while evince is still > open so I can still look at the file while I'm saving it. > > I've tried system("evince file.tiff & gnome-teminal --geometry=50x35-0+0"); > but then I don't see evince. > > Any help would be greatly appreciated. > > Thanks, > > Richard > > _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > > From gatorreina at gmail.com Thu Mar 4 14:50:08 2010 From: gatorreina at gmail.com (Richard Reina) Date: Thu, 4 Mar 2010 16:50:08 -0600 Subject: [sf-perl] simultaneous processes? In-Reply-To: <7c99e1971003040741k1f3ae821y36e6a5ccf113defc@mail.gmail.com> References: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> <7c99e1971003040741k1f3ae821y36e6a5ccf113defc@mail.gmail.com> Message-ID: <489cf9d1003041450g1cbdf63em62a2d714b0765fda@mail.gmail.com> Mark, That is what I needed. Thank you very much. Have a great day. 2010/3/4 Mark Grimes > There are better ways of dealing with this (forking, one of the IPC > modules, etc), but these are a quick and dirty way to do what you > want: > > perl -e'system(q{sh -c "( xlogo & ) ; xlogo "});' > perl -e'system(q{ ( xlogo & ) ; xlogo });' > > (Replacing the xlogo commands with evice and terminal, of course.) > > > 2010/3/4 Richard Reina : > > I use evince to view a good number of tiff files. I have written a quick > > little script to help me associate the tiff files with various database > > records. This script runs as part of larger API that runs in a very > minimal > > xwindows system ( no desktop just twm as a window manager.) As it stands > now > > I view the file with system("evince file.tiff"); close evince and execute > > the script which helps me associate and save the file. I was wondering > if > > there is a way to for my script to open a terminal while evince is still > > open so I can still look at the file while I'm saving it. > > > > I've tried system("evince file.tiff & gnome-teminal > --geometry=50x35-0+0"); > > but then I don't see evince. > > > > Any help would be greatly appreciated. > > > > Thanks, > > > > Richard > > > > _______________________________________________ > > SanFrancisco-pm mailing list > > SanFrancisco-pm at pm.org > > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > > > > > _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gatorreina at gmail.com Fri Mar 5 10:43:36 2010 From: gatorreina at gmail.com (Richard Reina) Date: Fri, 5 Mar 2010 12:43:36 -0600 Subject: [sf-perl] simultaneous processes? In-Reply-To: <7c99e1971003040741k1f3ae821y36e6a5ccf113defc@mail.gmail.com> References: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> <7c99e1971003040741k1f3ae821y36e6a5ccf113defc@mail.gmail.com> Message-ID: <489cf9d1003051043m5404592jdfde6810c28302b4@mail.gmail.com> The solution below works. But when I have to pass a scalar to the program it does not. For example if I do something like: perl -e'system(q{ ( evince $file & ) ; xlogo });' evince opens with this error Unhandled MIME type: "x-directory/normal" Does any one know how I can remedy this? Thanks. Richard 2010/3/4 Mark Grimes > There are better ways of dealing with this (forking, one of the IPC > modules, etc), but these are a quick and dirty way to do what you > want: > > perl -e'system(q{sh -c "( xlogo & ) ; xlogo "});' > perl -e'system(q{ ( xlogo & ) ; xlogo });' > > (Replacing the xlogo commands with evice and terminal, of course.) > > > 2010/3/4 Richard Reina : > > I use evince to view a good number of tiff files. I have written a quick > > little script to help me associate the tiff files with various database > > records. This script runs as part of larger API that runs in a very > minimal > > xwindows system ( no desktop just twm as a window manager.) As it stands > now > > I view the file with system("evince file.tiff"); close evince and execute > > the script which helps me associate and save the file. I was wondering > if > > there is a way to for my script to open a terminal while evince is still > > open so I can still look at the file while I'm saving it. > > > > I've tried system("evince file.tiff & gnome-teminal > --geometry=50x35-0+0"); > > but then I don't see evince. > > > > Any help would be greatly appreciated. > > > > Thanks, > > > > Richard > > > > _______________________________________________ > > SanFrancisco-pm mailing list > > SanFrancisco-pm at pm.org > > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > > > > > _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > -------------- next part -------------- An HTML attachment was scrubbed... URL: From garth.webb at gmail.com Fri Mar 5 10:52:28 2010 From: garth.webb at gmail.com (Garth Webb) Date: Fri, 5 Mar 2010 10:52:28 -0800 Subject: [sf-perl] simultaneous processes? In-Reply-To: <489cf9d1003051043m5404592jdfde6810c28302b4@mail.gmail.com> References: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> <7c99e1971003040741k1f3ae821y36e6a5ccf113defc@mail.gmail.com> <489cf9d1003051043m5404592jdfde6810c28302b4@mail.gmail.com> Message-ID: I think I'm lost on what you're trying to do; if its not too lengthy, can you post exactly the script you're trying to run with the environment variables (e.g. $file) explicitly defined? If you're really doing a "perl -e" just to run system, you might consider making this a shell script instead of a perl script. Garth 2010/3/5 Richard Reina > The solution below works. But when I have to pass a scalar to the program > it does not. For example if I do something like: > perl -e'system(q{ ( evince $file & ) ; xlogo });' > > evince opens with this error Unhandled MIME type: "x-directory/normal" > > Does any one know how I can remedy this? > > Thanks. > > Richard > > > > 2010/3/4 Mark Grimes > >> There are better ways of dealing with this (forking, one of the IPC >> >> modules, etc), but these are a quick and dirty way to do what you >> want: >> >> perl -e'system(q{sh -c "( xlogo & ) ; xlogo "});' >> perl -e'system(q{ ( xlogo & ) ; xlogo });' >> >> (Replacing the xlogo commands with evice and terminal, of course.) >> >> >> 2010/3/4 Richard Reina : >> > I use evince to view a good number of tiff files. I have written a >> quick >> > little script to help me associate the tiff files with various database >> > records. This script runs as part of larger API that runs in a very >> minimal >> > xwindows system ( no desktop just twm as a window manager.) As it stands >> now >> > I view the file with system("evince file.tiff"); close evince and >> execute >> > the script which helps me associate and save the file. I was wondering >> if >> > there is a way to for my script to open a terminal while evince is still >> > open so I can still look at the file while I'm saving it. >> > >> > I've tried system("evince file.tiff & gnome-teminal >> --geometry=50x35-0+0"); >> > but then I don't see evince. >> > >> > Any help would be greatly appreciated. >> > >> > Thanks, >> > >> > Richard >> > >> > _______________________________________________ >> > SanFrancisco-pm mailing list >> > SanFrancisco-pm at pm.org >> > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >> > >> > >> _______________________________________________ >> SanFrancisco-pm mailing list >> SanFrancisco-pm at pm.org >> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >> > > > _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mgrimes at cpan.org Fri Mar 5 10:58:59 2010 From: mgrimes at cpan.org (Mark Grimes) Date: Fri, 5 Mar 2010 13:58:59 -0500 Subject: [sf-perl] simultaneous processes? In-Reply-To: <489cf9d1003051043m5404592jdfde6810c28302b4@mail.gmail.com> References: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> <7c99e1971003040741k1f3ae821y36e6a5ccf113defc@mail.gmail.com> <489cf9d1003051043m5404592jdfde6810c28302b4@mail.gmail.com> Message-ID: <7c99e1971003051058m2771aabfs78f9086d675d846b@mail.gmail.com> q{ } is equivalent to using single quotes (''), so there is no variable substitution. Very handy when you are using perl -e'' on the command line to avoid the shell interpreting your quotes. In your script do something like: system( "( evice $file & ) ; xlogo " ); or if there is anychange $file will have spaces you might want to do system( qq{ (evince "$file" & ) ; xlogo } ); In this one, qq{ } is equivalent to double quotes (""), so variables are substituted. 2010/3/5 Richard Reina : > The solution below works. But when I have to pass a scalar to the program it > does not.? For example if I do something like: > ?perl -e'system(q{ ( evince $file & ) ; xlogo });' > > evince opens with this error Unhandled MIME type: "x-directory/normal" > > Does any one know how I can remedy this? > > Thanks. > > Richard > > > > 2010/3/4 Mark Grimes >> >> There are better ways of dealing with this (forking, one of the IPC >> modules, etc), but these are a quick and dirty way to do what you >> want: >> >> ?perl -e'system(q{sh -c "( xlogo & ) ; xlogo "});' >> ?perl -e'system(q{ ( xlogo & ) ; xlogo });' >> >> (Replacing the xlogo commands with evice and terminal, of course.) >> >> >> 2010/3/4 Richard Reina : >> > I use evince to view a good number of tiff files.? I have written a >> > quick >> > little script to help me associate the tiff files with various database >> > records.? This script runs as part of larger API that runs in a very >> > minimal >> > xwindows system ( no desktop just twm as a window manager.) As it stands >> > now >> > I view the file with system("evince file.tiff"); close evince and >> > execute >> > the script which helps me associate and save the file.? I was wondering >> > if >> > there is a way to for my script to open a terminal while evince is still >> > open so I can still look at the file while I'm saving it. >> > >> > I've tried system("evince file.tiff & gnome-teminal >> > --geometry=50x35-0+0"); >> > but then I don't see evince. >> > >> > Any help would be greatly appreciated. >> > >> > Thanks, >> > >> > Richard >> > >> > _______________________________________________ >> > SanFrancisco-pm mailing list >> > SanFrancisco-pm at pm.org >> > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >> > >> > >> _______________________________________________ >> SanFrancisco-pm mailing list >> SanFrancisco-pm at pm.org >> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > > > _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > > From gatorreina at gmail.com Fri Mar 5 11:09:18 2010 From: gatorreina at gmail.com (Richard Reina) Date: Fri, 5 Mar 2010 13:09:18 -0600 Subject: [sf-perl] simultaneous processes? In-Reply-To: References: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> <7c99e1971003040741k1f3ae821y36e6a5ccf113defc@mail.gmail.com> <489cf9d1003051043m5404592jdfde6810c28302b4@mail.gmail.com> Message-ID: <489cf9d1003051109l61ba4040scace2a05e5b210b3@mail.gmail.com> Hi Garth, Thank you for he reply. What I am trying to do is run two programs simultaneously and pass an argument in the form of a scalar to one of the programs. Here's the code from the program ( I am retyping it as the machine it's on does not get connected to the internet) system(q{ ( evince /usr/local/docs/$file & ) ; gnome-terminal"}); evince opens with the error message: Unhandled MIME type: "x-directory/normal" However, system(q{ ( evince /usr/local/docs/file_name.tif & ) ; gnome-terminal"}); works ( the file opens fine and so does the terminal next to it.) I need to find a way to be able to pass the file name to evince. Thanks, again for the reply. Hopefully, this can be solved. 2010/3/5 Garth Webb > I think I'm lost on what you're trying to do; if its not too lengthy, can > you post exactly the script you're trying to run with the environment > variables (e.g. $file) explicitly defined? > > If you're really doing a "perl -e" just to run system, you might consider > making this a shell script instead of a perl script. > > Garth > > 2010/3/5 Richard Reina > > The solution below works. But when I have to pass a scalar to the program >> it does not. For example if I do something like: >> perl -e'system(q{ ( evince $file & ) ; xlogo });' >> >> evince opens with this error Unhandled MIME type: "x-directory/normal" >> >> Does any one know how I can remedy this? >> >> Thanks. >> >> Richard >> >> >> >> 2010/3/4 Mark Grimes >> >>> There are better ways of dealing with this (forking, one of the IPC >>> >>> modules, etc), but these are a quick and dirty way to do what you >>> want: >>> >>> perl -e'system(q{sh -c "( xlogo & ) ; xlogo "});' >>> perl -e'system(q{ ( xlogo & ) ; xlogo });' >>> >>> (Replacing the xlogo commands with evice and terminal, of course.) >>> >>> >>> 2010/3/4 Richard Reina : >>> > I use evince to view a good number of tiff files. I have written a >>> quick >>> > little script to help me associate the tiff files with various database >>> > records. This script runs as part of larger API that runs in a very >>> minimal >>> > xwindows system ( no desktop just twm as a window manager.) As it >>> stands now >>> > I view the file with system("evince file.tiff"); close evince and >>> execute >>> > the script which helps me associate and save the file. I was wondering >>> if >>> > there is a way to for my script to open a terminal while evince is >>> still >>> > open so I can still look at the file while I'm saving it. >>> > >>> > I've tried system("evince file.tiff & gnome-teminal >>> --geometry=50x35-0+0"); >>> > but then I don't see evince. >>> > >>> > Any help would be greatly appreciated. >>> > >>> > Thanks, >>> > >>> > Richard >>> > >>> > _______________________________________________ >>> > SanFrancisco-pm mailing list >>> > SanFrancisco-pm at pm.org >>> > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >>> > >>> > >>> _______________________________________________ >>> SanFrancisco-pm mailing list >>> SanFrancisco-pm at pm.org >>> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >>> >> >> >> _______________________________________________ >> SanFrancisco-pm mailing list >> SanFrancisco-pm at pm.org >> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >> >> > > _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mehryar at mehryar.com Fri Mar 5 11:20:34 2010 From: mehryar at mehryar.com (mehryar) Date: Fri, 5 Mar 2010 11:20:34 -0800 (PST) Subject: [sf-perl] simultaneous processes? In-Reply-To: <489cf9d1003051109l61ba4040scace2a05e5b210b3@mail.gmail.com> References: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> <7c99e1971003040741k1f3ae821y36e6a5ccf113defc@mail.gmail.com> <489cf9d1003051043m5404592jdfde6810c28302b4@mail.gmail.com> <489cf9d1003051109l61ba4040scace2a05e5b210b3@mail.gmail.com> Message-ID: I think you want qq{ } so the $file variable gets interpolated - q{ } will not do variable interpolation. cheers, -Mehryar On Fri, 5 Mar 2010, Richard Reina wrote: > Hi Garth, > > Thank you for he reply. What I am trying to do is run two programs > simultaneously and pass an argument in the form of a scalar to one of the > programs. > > Here's the code from the program ( I am retyping it as the machine it's on > does not get connected to the internet) > > system(q{ ( evince /usr/local/docs/$file & ) ; gnome-terminal"}); > > evince opens with the error message: > > Unhandled MIME type: "x-directory/normal" > > However, > > system(q{ ( evince /usr/local/docs/file_name.tif & ) ; gnome-terminal"}); > > works ( the file opens fine and so does the terminal next to it.) I need to > find a way to be able to pass the file name to evince. > > Thanks, again for the reply. Hopefully, this can be solved. > > > > 2010/3/5 Garth Webb > >> I think I'm lost on what you're trying to do; if its not too lengthy, can >> you post exactly the script you're trying to run with the environment >> variables (e.g. $file) explicitly defined? >> >> If you're really doing a "perl -e" just to run system, you might consider >> making this a shell script instead of a perl script. >> >> Garth >> >> 2010/3/5 Richard Reina >> >> The solution below works. But when I have to pass a scalar to the program >>> it does not. For example if I do something like: >>> perl -e'system(q{ ( evince $file & ) ; xlogo });' >>> >>> evince opens with this error Unhandled MIME type: "x-directory/normal" >>> >>> Does any one know how I can remedy this? >>> >>> Thanks. >>> >>> Richard >>> >>> >>> >>> 2010/3/4 Mark Grimes >>> >>>> There are better ways of dealing with this (forking, one of the IPC >>>> >>>> modules, etc), but these are a quick and dirty way to do what you >>>> want: >>>> >>>> perl -e'system(q{sh -c "( xlogo & ) ; xlogo "});' >>>> perl -e'system(q{ ( xlogo & ) ; xlogo });' >>>> >>>> (Replacing the xlogo commands with evice and terminal, of course.) >>>> >>>> >>>> 2010/3/4 Richard Reina : >>>>> I use evince to view a good number of tiff files. I have written a >>>> quick >>>>> little script to help me associate the tiff files with various database >>>>> records. This script runs as part of larger API that runs in a very >>>> minimal >>>>> xwindows system ( no desktop just twm as a window manager.) As it >>>> stands now >>>>> I view the file with system("evince file.tiff"); close evince and >>>> execute >>>>> the script which helps me associate and save the file. I was wondering >>>> if >>>>> there is a way to for my script to open a terminal while evince is >>>> still >>>>> open so I can still look at the file while I'm saving it. >>>>> >>>>> I've tried system("evince file.tiff & gnome-teminal >>>> --geometry=50x35-0+0"); >>>>> but then I don't see evince. >>>>> >>>>> Any help would be greatly appreciated. >>>>> >>>>> Thanks, >>>>> >>>>> Richard >>>>> >>>>> _______________________________________________ >>>>> SanFrancisco-pm mailing list >>>>> SanFrancisco-pm at pm.org >>>>> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >>>>> >>>>> >>>> _______________________________________________ >>>> SanFrancisco-pm mailing list >>>> SanFrancisco-pm at pm.org >>>> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >>>> >>> >>> >>> _______________________________________________ >>> SanFrancisco-pm mailing list >>> SanFrancisco-pm at pm.org >>> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >>> >>> >> >> _______________________________________________ >> SanFrancisco-pm mailing list >> SanFrancisco-pm at pm.org >> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >> >> > From gatorreina at gmail.com Fri Mar 5 12:35:53 2010 From: gatorreina at gmail.com (Richard Reina) Date: Fri, 5 Mar 2010 14:35:53 -0600 Subject: [sf-perl] simultaneous processes? In-Reply-To: References: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> <7c99e1971003040741k1f3ae821y36e6a5ccf113defc@mail.gmail.com> <489cf9d1003051043m5404592jdfde6810c28302b4@mail.gmail.com> <489cf9d1003051109l61ba4040scace2a05e5b210b3@mail.gmail.com> Message-ID: <489cf9d1003051235h5a0ee425id3b9af39a54042e3@mail.gmail.com> Both solutions seem to work. However, if I add complexity to the second part of the statement ( which is where this program will eventually be heading) I am having trouble. Nevertheless, the solutions do work for what is posted below and I am very grateful for the replies. Again, thank you very much. 2010/3/5 mehryar > > I think you want qq{ } so the $file variable gets interpolated - q{ } will > not do variable interpolation. > > cheers, > -Mehryar > > > > On Fri, 5 Mar 2010, Richard Reina wrote: > > Hi Garth, >> >> Thank you for he reply. What I am trying to do is run two programs >> simultaneously and pass an argument in the form of a scalar to one of the >> programs. >> >> Here's the code from the program ( I am retyping it as the machine it's on >> does not get connected to the internet) >> >> system(q{ ( evince /usr/local/docs/$file & ) ; gnome-terminal"}); >> >> evince opens with the error message: >> >> Unhandled MIME type: "x-directory/normal" >> >> However, >> >> system(q{ ( evince /usr/local/docs/file_name.tif & ) ; gnome-terminal"}); >> >> works ( the file opens fine and so does the terminal next to it.) I need >> to >> find a way to be able to pass the file name to evince. >> >> Thanks, again for the reply. Hopefully, this can be solved. >> >> >> >> 2010/3/5 Garth Webb >> >> I think I'm lost on what you're trying to do; if its not too lengthy, can >>> you post exactly the script you're trying to run with the environment >>> variables (e.g. $file) explicitly defined? >>> >>> If you're really doing a "perl -e" just to run system, you might consider >>> making this a shell script instead of a perl script. >>> >>> Garth >>> >>> 2010/3/5 Richard Reina >>> >>> The solution below works. But when I have to pass a scalar to the program >>> >>>> it does not. For example if I do something like: >>>> perl -e'system(q{ ( evince $file & ) ; xlogo });' >>>> >>>> evince opens with this error Unhandled MIME type: "x-directory/normal" >>>> >>>> Does any one know how I can remedy this? >>>> >>>> Thanks. >>>> >>>> Richard >>>> >>>> >>>> >>>> 2010/3/4 Mark Grimes >>>> >>>> There are better ways of dealing with this (forking, one of the IPC >>>>> >>>>> modules, etc), but these are a quick and dirty way to do what you >>>>> want: >>>>> >>>>> perl -e'system(q{sh -c "( xlogo & ) ; xlogo "});' >>>>> perl -e'system(q{ ( xlogo & ) ; xlogo });' >>>>> >>>>> (Replacing the xlogo commands with evice and terminal, of course.) >>>>> >>>>> >>>>> 2010/3/4 Richard Reina : >>>>> >>>>>> I use evince to view a good number of tiff files. I have written a >>>>>> >>>>> quick >>>>> >>>>>> little script to help me associate the tiff files with various >>>>>> database >>>>>> records. This script runs as part of larger API that runs in a very >>>>>> >>>>> minimal >>>>> >>>>>> xwindows system ( no desktop just twm as a window manager.) As it >>>>>> >>>>> stands now >>>>> >>>>>> I view the file with system("evince file.tiff"); close evince and >>>>>> >>>>> execute >>>>> >>>>>> the script which helps me associate and save the file. I was >>>>>> wondering >>>>>> >>>>> if >>>>> >>>>>> there is a way to for my script to open a terminal while evince is >>>>>> >>>>> still >>>>> >>>>>> open so I can still look at the file while I'm saving it. >>>>>> >>>>>> I've tried system("evince file.tiff & gnome-teminal >>>>>> >>>>> --geometry=50x35-0+0"); >>>>> >>>>>> but then I don't see evince. >>>>>> >>>>>> Any help would be greatly appreciated. >>>>>> >>>>>> Thanks, >>>>>> >>>>>> Richard >>>>>> >>>>>> _______________________________________________ >>>>>> SanFrancisco-pm mailing list >>>>>> SanFrancisco-pm at pm.org >>>>>> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >>>>>> >>>>>> >>>>>> _______________________________________________ >>>>> SanFrancisco-pm mailing list >>>>> SanFrancisco-pm at pm.org >>>>> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >>>>> >>>>> >>>> >>>> _______________________________________________ >>>> SanFrancisco-pm mailing list >>>> SanFrancisco-pm at pm.org >>>> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >>>> >>>> >>>> >>> _______________________________________________ >>> SanFrancisco-pm mailing list >>> SanFrancisco-pm at pm.org >>> http://mail.pm.org/mailman/listinfo/sanfrancisco-pm >>> >>> >>> >> _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > -------------- next part -------------- An HTML attachment was scrubbed... URL: From doom at kzsu.stanford.edu Fri Mar 5 12:49:25 2010 From: doom at kzsu.stanford.edu (Joe Brenner) Date: Fri, 05 Mar 2010 12:49:25 -0800 Subject: [sf-perl] Talk announcement: "Simple form validation with Data::FormValidator" Message-ID: <201003052049.o25KnPwP034714@kzsu.stanford.edu> As the first talk in series of talks on form validation, Fred Moyer will present an overview of Data::FormValidator. Real world code examples will be presented, and you'll see how you can use Data::FormValidator to implement form validation for legacy codebases as well as new code. Data::FormValidator is a loosely coupled, highly flexible, and easy to use form validation module written by Mark Stosberg. This meeting will take place on Tuesday, March 23rd at 7pm at Six Apart World Headquarters. Fred Moyer's CPAN page: http://search.cpan.org/~phred/ Data::FormValidator on CPAN: http://search.cpan.org/dist/Data-FormValidator/ RSVP at Meetup - http://www.meetup.com/San-Francisco-Perl-Mongers/calendar/12793946/ From doom at kzsu.stanford.edu Fri Mar 5 12:54:53 2010 From: doom at kzsu.stanford.edu (Joe Brenner) Date: Fri, 05 Mar 2010 12:54:53 -0800 Subject: [sf-perl] Talk announcement: "Simple form validation with Data::FormValidator" In-Reply-To: <201003052049.o25KnPwP034714@kzsu.stanford.edu> References: <201003052049.o25KnPwP034714@kzsu.stanford.edu> Message-ID: <201003052054.o25KsrCu034827@kzsu.stanford.edu> Joe Brenner wrote: > As the first talk in series of talks on form validation, Fred Moyer > will present an overview of Data::FormValidator. We really would like this to be the first in a series: If you've got a favorite method of doing html form handling that you'd like to demo for us, please do speak up, and let me know. From sphink at gmail.com Fri Mar 5 13:55:39 2010 From: sphink at gmail.com (Steve Fink) Date: Fri, 5 Mar 2010 13:55:39 -0800 Subject: [sf-perl] simultaneous processes? In-Reply-To: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> References: <489cf9d1003040707s5787fd5bn3ceb143cad18b6ad@mail.gmail.com> Message-ID: <7d7f2e8c1003051355p4c6a873ew5d3ecfb3ae40204d@mail.gmail.com> I'm also a little confused by exactly what you're trying to accomplish. Is this correct: you want to scan over a large set of tiff files. For each one, you want to pop up an image viewer and a shell. When you've figured out what to do with the image, you type a command into the shell and then you want both the shell and the view of that image to go away, and then you move onto the next one. Is that it? If so, the "safe" way to do it (and not worry about quoting and things) would be something like for my $file (glob("*.tiff")) { my $viewer = fork() || exec("evince", $file) || die; system("gnome-terminal", "--geometry=50x35-0+0"); kill(15, $viewer) if kill(0, $viewer); wait; } (warning: completely untested) Though if I was right about what you're doing, then wouldn't it be better to have the script prompt you for what you want to do with each image instead of starting up a terminal for it? I'm probably just confused about what you're after. From tkeefer at ebay.com Sat Mar 6 10:32:28 2010 From: tkeefer at ebay.com (Keefer, Tim) Date: Sat, 6 Mar 2010 11:32:28 -0700 Subject: [sf-perl] Mason applications and Module::Build Message-ID: Hi, Does anyone know if there's already some code that supports bundling HTML::Mason or other perl web applications into a CPAN distribution? I've written a Module::Build subclass that works really well for me and I'm wondering if it would be useful for others. I'm also looking for advice about what CPAN namespace it could go under. However, I don't want to go through the trouble of putting this on CPAN if there's already something that does this. Below is a section of the docs that should give you a better idea of what I'm talking about. I realize you guys had a meetup a few weeks ago which would have been a great place to bring this up. I tried to travel up for it, but I'm all the way down in the south part of the bay area and couldn't make it. Cheers, -Tim =head1 Name {some name} - a subclass of Module::Build to perform custom installs =head1 Description Use this module instead of Module::Build (which it subclasses). Use any or all of the Module::Build constructor keys as needed. =head1 Setting Up Your Application =head2 Application Layout This the typical directory structure for an application Apps-MyApp/ Build.PL Changes MANIFEST MANIFEST.SKIP INSTALL.SKIP conf/ _app.conf _myapachevhost.conf app.rules html/ autohandler.mpl css/ img/ inc/ footer.html header.html index.html lib/ Apps/ MyApp.pm MyApp/ Foo.pm t/ 01use.t 02myapp.t =head2 Build and Deploy perl Build.PL ./Build test # runs the application tests ./Build install # install the application ./Build dist # build the application tarbal =over 4 =head1 Setting up the application's Aeon Build.PL script =over 4 =item Sample Build.PL use strict; use File::HomeDir; my $build = {some name}->new( install_base_default => ( File::HomeDir->my_home . "/releases" ), get_options => { env => { type => '=s' }, rules => { type => '=s' }, install_base => { type => '=s' }, }, apache_conf => 'conf/myapachevhost.conf', license => 'perl', module_name => 'Apps::MyApp', requires => { 'perl' => '5.8.1', }, create_makefile_pl => 'passthrough', dist_abstract => 'Mason site for Apps Foo', script_files => [ glob('bin/*') ], 'recursive_test_files' => 1, ); $build->create_build_script; From swartz at pobox.com Sat Mar 6 11:08:06 2010 From: swartz at pobox.com (Jonathan Swartz) Date: Sat, 6 Mar 2010 11:08:06 -0800 Subject: [sf-perl] Mason applications and Module::Build In-Reply-To: References: Message-ID: <044BBDA3-05C5-412E-88ED-66F0A7AAEBDB@pobox.com> I've heard that Catalyst web apps are designed to be easily packaged up in this way, you could take a look at what they've done. You might also ask this question on the Mason user's list. Jon On Mar 6, 2010, at 10:32 AM, Keefer, Tim wrote: > Hi, > > Does anyone know if there's already some code that supports bundling > HTML::Mason or other perl web applications into a CPAN distribution? > I've written a Module::Build subclass that works really well for me > and I'm wondering if it would be useful for others. I'm also looking > for advice about what CPAN namespace it could go under. However, I > don't want to go through the trouble of putting this on CPAN if > there's already something that does this. Below is a section of the > docs that should give you a better idea of what I'm talking about. > > I realize you guys had a meetup a few weeks ago which would have > been a great place to bring this up. I tried to travel up for it, > but I'm all the way down in the south part of the bay area and > couldn't make it. > > Cheers, > -Tim > > =head1 Name > > {some name} - a subclass of Module::Build to perform custom installs > > =head1 Description > > Use this module instead of Module::Build (which it subclasses). Use > any or all of the Module::Build constructor keys as needed. > > =head1 Setting Up Your Application > > =head2 Application Layout > > This the typical directory structure for an application > > Apps-MyApp/ > Build.PL > Changes > MANIFEST > MANIFEST.SKIP > INSTALL.SKIP > conf/ > _app.conf > _myapachevhost.conf > app.rules > html/ > autohandler.mpl > css/ > img/ > inc/ > footer.html > header.html > index.html > lib/ > Apps/ > MyApp.pm > MyApp/ > Foo.pm > t/ > 01use.t > 02myapp.t > > =head2 Build and Deploy > > perl Build.PL > ./Build test # runs the application tests > ./Build install # install the application > ./Build dist # build the application tarbal > > =over 4 > > =head1 Setting up the application's Aeon Build.PL script > > =over 4 > > =item Sample Build.PL > > use strict; > use File::HomeDir; > > my $build = {some name}->new( > install_base_default => ( File::HomeDir->my_home . "/ > releases" ), > get_options => { > env => { type => '=s' }, > rules => { type => '=s' }, > install_base => { type => '=s' }, > }, > apache_conf => 'conf/myapachevhost.conf', > license => 'perl', > module_name => 'Apps::MyApp', > requires => { > 'perl' => '5.8.1', > }, > create_makefile_pl => 'passthrough', > dist_abstract => 'Mason site for Apps Foo', > script_files => [ glob('bin/*') ], > 'recursive_test_files' => 1, > ); > > $build->create_build_script; > _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm From doom at kzsu.stanford.edu Sat Mar 6 14:23:44 2010 From: doom at kzsu.stanford.edu (Joe Brenner) Date: Sat, 06 Mar 2010 14:23:44 -0800 Subject: [sf-perl] Mason applications and Module::Build In-Reply-To: <044BBDA3-05C5-412E-88ED-66F0A7AAEBDB@pobox.com> References: <044BBDA3-05C5-412E-88ED-66F0A7AAEBDB@pobox.com> Message-ID: <201003062223.o26MNiKi054761@kzsu.stanford.edu> I believe there's a Module::Install::Bundle that does something like this, but then, that's MakeMaker based. What does this system do in the event that the bundled module is already installed? (Over-writing a newer version with an older one is a recipe for disaster.) I don't see any place in the Build.PL where you tell it what you want to bundle, so I gather it traces dependencies automatically. Is that right? Perhaps unfortunately, it looks like someone has just grabbed the name "Module::Build::Bundle", for a minor piece of work that probably should never have been put on CPAN: http://search.cpan.org/~jonasbn/Bundle-JONASBN-0.04/ "Module::Build::Bundling" contains some discussion of the subject by dagolden: http://search.cpan.org/~dagolden/Module-Build-0.3603/lib/Module/Build/Bundling.pod Hm... there's a "Module::Build::Functions" that contains this hint: Deprecated directives auto_bundle auto_bundle_deps bundle bundle_deps This directives comes from Module::Install::Bundle. The author has deliberately chosen to drop support for bundling at this point, since Module::Build quite probably will have native bundling capabilities soon. Anyway, I'd suggest bugging people like David Golden about this... it could be they'd be interested in merging what you've got into Module::Build itself. Off the top of my head, if you needed a name for it now: Module::Build::Bundler Module::Build::AutoBundle Jonathan Swartz wrote: > I've heard that Catalyst web apps are designed to be easily packaged > up in this way, you could take a look at what they've done. > > You might also ask this question on the Mason user's list. > > Jon > > On Mar 6, 2010, at 10:32 AM, Keefer, Tim wrote: > > > Hi, > > > > Does anyone know if there's already some code that supports bundling > > HTML::Mason or other perl web applications into a CPAN distribution? > > I've written a Module::Build subclass that works really well for me > > and I'm wondering if it would be useful for others. I'm also looking > > for advice about what CPAN namespace it could go under. However, I > > don't want to go through the trouble of putting this on CPAN if > > there's already something that does this. Below is a section of the > > docs that should give you a better idea of what I'm talking about. > > > > I realize you guys had a meetup a few weeks ago which would have > > been a great place to bring this up. I tried to travel up for it, > > but I'm all the way down in the south part of the bay area and > > couldn't make it. > > > > Cheers, > > -Tim > > > > =head1 Name > > > > {some name} - a subclass of Module::Build to perform custom installs > > > > =head1 Description > > > > Use this module instead of Module::Build (which it subclasses). Use > > any or all of the Module::Build constructor keys as needed. > > > > =head1 Setting Up Your Application > > > > =head2 Application Layout > > > > This the typical directory structure for an application > > > > Apps-MyApp/ > > Build.PL > > Changes > > MANIFEST > > MANIFEST.SKIP > > INSTALL.SKIP > > conf/ > > _app.conf > > _myapachevhost.conf > > app.rules > > html/ > > autohandler.mpl > > css/ > > img/ > > inc/ > > footer.html > > header.html > > index.html > > lib/ > > Apps/ > > MyApp.pm > > MyApp/ > > Foo.pm > > t/ > > 01use.t > > 02myapp.t > > > > =head2 Build and Deploy > > > > perl Build.PL > > ./Build test # runs the application tests > > ./Build install # install the application > > ./Build dist # build the application tarbal > > > > =over 4 > > > > =head1 Setting up the application's Aeon Build.PL script > > > > =over 4 > > > > =item Sample Build.PL > > > > use strict; > > use File::HomeDir; > > > > my $build = {some name}->new( > > install_base_default => ( File::HomeDir->my_home . "/ > > releases" ), > > get_options => { > > env => { type => '=s' }, > > rules => { type => '=s' }, > > install_base => { type => '=s' }, > > }, > > apache_conf => 'conf/myapachevhost.conf', > > license => 'perl', > > module_name => 'Apps::MyApp', > > requires => { > > 'perl' => '5.8.1', > > }, > > create_makefile_pl => 'passthrough', > > dist_abstract => 'Mason site for Apps Foo', > > script_files => [ glob('bin/*') ], > > 'recursive_test_files' => 1, > > ); > > > > $build->create_build_script; > > _______________________________________________ > > SanFrancisco-pm mailing list > > SanFrancisco-pm at pm.org > > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > > _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm From tkeefer at ebay.com Sun Mar 7 09:45:55 2010 From: tkeefer at ebay.com (Keefer, Tim) Date: Sun, 7 Mar 2010 10:45:55 -0700 Subject: [sf-perl] Mason applications and Module::Build In-Reply-To: <201003062223.o26MNiKi054761@kzsu.stanford.edu> References: <044BBDA3-05C5-412E-88ED-66F0A7AAEBDB@pobox.com>, <201003062223.o26MNiKi054761@kzsu.stanford.edu> Message-ID: I used the word bundle, but now realize a better word may have been package -- subtle difference i guess. The way my code is working is, using ExtUtils::Install, I install the files into a versioned directory and then during the install process I do some other things, i.e. create a symlink for the versioned directory, build application conf , symlink the apache virtual host file, and localize any html. The only code my subclass installs is the web application code located in the lib directory. Any external dependencies need to be defined in the Module::Build requires hash which would get installed in the typical CPAN install fashion. Thinking more about this now, it might be useful to have a "./Build install_deps" method that pulls down this code so can also be versioned along with the web application. I can see this becoming unwieldy if the app has a lot of dependencies though. Thanks for the namespace suggestions - I'm also thinking Module::Build::VirtualHost since technically this a packaging process for the complete set of content for an Apache virtualhost. Thanks again, -Tim _______________________________________ From: sanfrancisco-pm-bounces+tkeefer=ebay.com at pm.org [sanfrancisco-pm-bounces+tkeefer=ebay.com at pm.org] On Behalf Of Joe Brenner [doom at kzsu.stanford.edu] Sent: Saturday, March 06, 2010 2:23 PM To: San Francisco Perl Mongers User Group Subject: Re: [sf-perl] Mason applications and Module::Build I believe there's a Module::Install::Bundle that does something like this, but then, that's MakeMaker based. What does this system do in the event that the bundled module is already installed? (Over-writing a newer version with an older one is a recipe for disaster.) I don't see any place in the Build.PL where you tell it what you want to bundle, so I gather it traces dependencies automatically. Is that right? Perhaps unfortunately, it looks like someone has just grabbed the name "Module::Build::Bundle", for a minor piece of work that probably should never have been put on CPAN: http://search.cpan.org/~jonasbn/Bundle-JONASBN-0.04/ "Module::Build::Bundling" contains some discussion of the subject by dagolden: http://search.cpan.org/~dagolden/Module-Build-0.3603/lib/Module/Build/Bundling.pod Hm... there's a "Module::Build::Functions" that contains this hint: Deprecated directives auto_bundle auto_bundle_deps bundle bundle_deps This directives comes from Module::Install::Bundle. The author has deliberately chosen to drop support for bundling at this point, since Module::Build quite probably will have native bundling capabilities soon. Anyway, I'd suggest bugging people like David Golden about this... it could be they'd be interested in merging what you've got into Module::Build itself. Off the top of my head, if you needed a name for it now: Module::Build::Bundler Module::Build::AutoBundle Jonathan Swartz wrote: > I've heard that Catalyst web apps are designed to be easily packaged > up in this way, you could take a look at what they've done. > > You might also ask this question on the Mason user's list. > > Jon > > On Mar 6, 2010, at 10:32 AM, Keefer, Tim wrote: > > > Hi, > > > > Does anyone know if there's already some code that supports bundling > > HTML::Mason or other perl web applications into a CPAN distribution? > > I've written a Module::Build subclass that works really well for me > > and I'm wondering if it would be useful for others. I'm also looking > > for advice about what CPAN namespace it could go under. However, I > > don't want to go through the trouble of putting this on CPAN if > > there's already something that does this. Below is a section of the > > docs that should give you a better idea of what I'm talking about. > > > > I realize you guys had a meetup a few weeks ago which would have > > been a great place to bring this up. I tried to travel up for it, > > but I'm all the way down in the south part of the bay area and > > couldn't make it. > > > > Cheers, > > -Tim > > > > =head1 Name > > > > {some name} - a subclass of Module::Build to perform custom installs > > > > =head1 Description > > > > Use this module instead of Module::Build (which it subclasses). Use > > any or all of the Module::Build constructor keys as needed. > > > > =head1 Setting Up Your Application > > > > =head2 Application Layout > > > > This the typical directory structure for an application > > > > Apps-MyApp/ > > Build.PL > > Changes > > MANIFEST > > MANIFEST.SKIP > > INSTALL.SKIP > > conf/ > > _app.conf > > _myapachevhost.conf > > app.rules > > html/ > > autohandler.mpl > > css/ > > img/ > > inc/ > > footer.html > > header.html > > index.html > > lib/ > > Apps/ > > MyApp.pm > > MyApp/ > > Foo.pm > > t/ > > 01use.t > > 02myapp.t > > > > =head2 Build and Deploy > > > > perl Build.PL > > ./Build test # runs the application tests > > ./Build install # install the application > > ./Build dist # build the application tarbal > > > > =over 4 > > > > =head1 Setting up the application's Aeon Build.PL script > > > > =over 4 > > > > =item Sample Build.PL > > > > use strict; > > use File::HomeDir; > > > > my $build = {some name}->new( > > install_base_default => ( File::HomeDir->my_home . "/ > > releases" ), > > get_options => { > > env => { type => '=s' }, > > rules => { type => '=s' }, > > install_base => { type => '=s' }, > > }, > > apache_conf => 'conf/myapachevhost.conf', > > license => 'perl', > > module_name => 'Apps::MyApp', > > requires => { > > 'perl' => '5.8.1', > > }, > > create_makefile_pl => 'passthrough', > > dist_abstract => 'Mason site for Apps Foo', > > script_files => [ glob('bin/*') ], > > 'recursive_test_files' => 1, > > ); > > > > $build->create_build_script; > > _______________________________________________ > > SanFrancisco-pm mailing list > > SanFrancisco-pm at pm.org > > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > > _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm _______________________________________________ SanFrancisco-pm mailing list SanFrancisco-pm at pm.org http://mail.pm.org/mailman/listinfo/sanfrancisco-pm From fred at redhotpenguin.com Fri Mar 12 15:25:48 2010 From: fred at redhotpenguin.com (Fred Moyer) Date: Fri, 12 Mar 2010 15:25:48 -0800 Subject: [sf-perl] Fwd: Books and News from the O'Reilly User Group Program--March In-Reply-To: <1268409734.6975.0.726746@post.oreilly.com> References: <1268409734.6975.0.726746@post.oreilly.com> Message-ID: Some good deals in here. ---------- Forwarded message ---------- From: Marsee Henon Date: Fri, Mar 12, 2010 at 8:02 AM Subject: Books and News from the O'Reilly User Group Program--March To: fred at redhotpenguin.com View this information as HTML in your browser, click here: http://post.oreilly.com/rd/9z1z1ih83ho8u1efbfcromgjrgikstbbfbcick42qpo Hi there, Here's a slide to promote our UG discount information at your user group meetings. Simply download a PowerPoint or Keynote version of the slide here. If you need a different size or format, let me know. http://post.oreilly.com/rd/9z1zbs86j523n15nuc6uillea5af8l1sk0t9ds3e268 I hope you've noticed our new $9.99 ebook deal of the day on oreilly.com. Check our daily announcements on Twitter, Facebook, and LinkedIn. Or follow our RSS Feed. http://post.oreilly.com/rd/9z1zoltnc3e2simuatpm5h5499g0qm4c7ureanp94fo We're looking for people to write reviews of our new video "Croll & Power's Communilytics Master Class--Social Media Analytics." I attended this very session. http://post.oreilly.com/rd/9z1zdmc4d73vsuplf3a4amc4ipe1koa116o0huemk90 Travel update: I'm headed to Microsoft Mix March 15-17 in Las Vegas. We'll be in the Commons area selling Microsoft Press and O'Reilly Media books. Stop by and say hi. Thanks, --Marsee Henon P.S. Don't forget you can register for the O'Reilly Newsletter and product announcements to keep up to date between user group newsletters. You can pick and choose your lists here: http://post.oreilly.com/rd/9z1zjujrddoqtu1p1omda412p24qraduqd8vqdkjh70 --------------------------------------------------------------- Tips for User Group Leaders --------------------------------------------------------------- I've just posted the following: "What do you do when you have a speaker that cancels at the last minute?" Please post your answer online. http://post.oreilly.com/rd/9z1z51rvipnr1kk7eass51ooejpbse7rd6pkbc6i7sg Are you interested in Live Streaming your meetings? Here's a guide from Stephen Chin of the Silicon Valley JavaFX User Group: Part 1 : Introduction http://post.oreilly.com/rd/9z1zkeitnf9v03sd7j17l26v1ioqio6hqgvttk04nso --------------------------------------------------------------- Register Now - Free Upcoming Webcasts and Online Conferences --------------------------------------------------------------- O'Reilly Velocity Online Conference March 17, 2010 at 9:00am PST / 12:00pm EST http://post.oreilly.com/rd/9z1zvbj0npv6q2lupfaa4rvulivfkia0ledefcf7j1o Check the Webcast page for on-demand videos of past webcasts and more upcoming live events: http://post.oreilly.com/rd/9z1zb527h1l9d3i92gj253qpcmp4otvcsrnmtbb4110 -------------------------------------------------------------- New Releases and Book Reviews Needed --------------------------------------------------------------- Get 35% off from O'Reilly, Microsoft Press, No Starch, Paraglyph, PC Publishing, Pragmatic Bookshelf, Rocky Nook, SitePoint, or YoungJin books and 45% off ebooks you purchase directly from O'Reilly. Just use code DSUG when ordering online or by phone 800-998-9938. http://post.oreilly.com/rd/9z1zap0qt184so37uhmleadj37dcgebud6op3bt11ag 97 Things Every Programmer Should Know http://post.oreilly.com/rd/9z1z595ua3paejlttfth5b6qef6l8jbif92ne3ust7g Open Government http://post.oreilly.com/rd/9z1z4nhuebiqbrjf63kurg24c8jur1gmkaousjejd9g Microsoft Forefront Threat Management Gateway (TMG) Administrator's Companion (Microsoft Press) http://post.oreilly.com/rd/9z1zvm5265uluh4v3du26ctcamcli3rveq0a6qdclog HTML & CSS: The Good Parts http://post.oreilly.com/rd/9z1zpffl922lmi5puu92ksavl64gqqqirgif4kfbtvg Effective UI http://post.oreilly.com/rd/9z1z2s045tp08qge3ppb7v8qjs676hbi8mlgjuhstro CLR via C#, Third Edition (Microsoft Press) http://post.oreilly.com/rd/9z1zjldh9gdgtblsh6oeuknailje5ht50pb6u0f19lo The Art of Assembly Language, Second Edition (No Starch) http://post.oreilly.com/rd/9z1z57gtelporf6s00dab41omespf6to286gmlrk5so Croll & Power's Communilytics Master Class http://post.oreilly.com/rd/9z1z4i9uoqeelbkbh443bk47frpd4mn8fq86dughn30 REST in Practice: Rough Cuts Version http://post.oreilly.com/rd/9z1zdr62qf0bjs5r5r5qo57ndjqcraphpbmf47a5b10 Tap Happy: Rough Cuts Version http://post.oreilly.com/rd/9z1zk8nlfkfq4t3th8p4fke905i6q8gnb5rgqrpi8i0 Host Your Web Site On The Cloud: Amazon Web Services Made Easy (SitePoint) http://post.oreilly.com/rd/9z1z2tmbu9mi62gnqqj8351bi7u3ch5su7o3tu6qk30 Digital Photography for the Web (SitePoint) http://post.oreilly.com/rd/9z1zub27dbeedhv4o5r8ad46g9u8tlkavd4fg1rlkbg Take Control of Screen Sharing in Snow Leopard (TidBITS) http://post.oreilly.com/rd/9z1zk6tp0laq6t173glectr52okijhcjd6kktcmtso0 jQuery: Novice to Ninja (SitePoint) http://post.oreilly.com/rd/9z1zckpgvpm8k3s4jfia9r6hkuk0nuo0ipi6mnlohp0 Layout in Pages '09: The Mini Missing Manual http://post.oreilly.com/rd/9z1zhpp26uo338kc1d54d88l8o9g0htu21ht31im5ko Word Processing in Pages '09: The Mini Missing Manual http://post.oreilly.com/rd/9z1zoneeamp5t32fqn4ih0gu8rrvan32361il0viro8 Creating Keynote Slideshows: The Mini Missing Manual http://post.oreilly.com/rd/9z1zbkeplbvdtm49nd2rh9uuac3ilet7rlh9t6nbe20 Attract Visitors to Your Site: The Mini Missing Manual http://post.oreilly.com/rd/9z1z667033qpiucrv4b6ru5ao0q775igv13mpcohhe0 Add Interactivity to Your Site: The Mini Missing Manual http://post.oreilly.com/rd/9z1z4habcl0694b3stupu29j4s8k4pdl2vhoaphtvc0 Sharing Keynote Slideshows: The Mini Missing Manual http://post.oreilly.com/rd/9z1z0ns0vrsolajlik8rlm6ku1msu9pi0hiqbdq1mfg Add Audio and Video to Your Site: The Mini Missing Manual http://post.oreilly.com/rd/9z1zndoolrt66jtv5mqgdee7if3vak2gthbrj659jqo Metaprogramming Ruby (Pragmatic Bookshelf) http://post.oreilly.com/rd/9z1znd5jvudeev16121je26vrt6dtqjj55b01vcevc8 Programming the Mobile Web: Rough Cuts Version http://post.oreilly.com/rd/9z1zr1234kbeuu0ndee32hig9oq20s41q0ovfobkdeo --------------------------------------------------------------- UG leaders only--Put Up a Banner, Get a Free Book --------------------------------------------------------------- We're looking for user groups to display our discount banners on their web sites. If you send me your group's site with one or more banners, I'll send you the O'Reilly book(s) of your choice. Choose from the following list: The New How http://post.oreilly.com/rd/9z1zjsfdg6cvubmk2sk1kvp4jsthnvspptjlgvksc50 Confessions of a Public Speaker http://post.oreilly.com/rd/9z1zo2cs14fp9ahdq6kem17a06hiiafefaomgoku0qo slide:ology http://post.oreilly.com/rd/9z1z3d4bfq6tcrr6f54fqnr85cv449kj60r2r8sk2ko O'Reilly Answers http://post.oreilly.com/rd/9z1zhoirfqom3oh1v8fhel9soiv52oafjtj70logtc0 RailsConf 2010 http://post.oreilly.com/rd/9z1zuuv63ilug9893pv7bfvb12054l7nahrtcf45cjo Where 2.0 Conference http://post.oreilly.com/rd/9z1z53607b23bnf97cnop9upi81r2ksrto25mffet5g MySQL Conference & Expo 2010 http://post.oreilly.com/rd/9z1zed03ocgeptqopdp984t2362ghfhl9si3k6m7af8 O'Reilly School of Technology Banners http://post.oreilly.com/rd/9z1zauh5o37invqeef849rhsu9qtebbe30jv8iqqkt8 Customizable O'Reilly Book Widgets http://post.oreilly.com/rd/9z1z6i8b0ad1tmp240tp8ismje60f5kh5pj6h8kbe8g 35% off User Group Discount Banners http://post.oreilly.com/rd/9z1zqp7kq4qahap7nccl5drr3mvu90us6pvgscc1rs0 --------------------------------------------------------------- Discount offers from Safari Books Online & The O'Reilly School of Technolgy --------------------------------------------------------------- 20% off Safari Books Online for 12 months for UG members (new subscribers only) Safari Books Online provides online access to more than 8,500 books and videos from the world's leading technology publishers. We're offering User Group members an exclusive 20% discount on monthly subscriptions to Safari Books Online for 12 months (new subscribers only). Subscriptions must be purchased before March 31, 2010. Coupon Code: QLGSSZG http://post.oreilly.com/rd/9z1zuht9m3tgk3pphiq861b15sgf6g8n6jia94ebk6g ------------------------- O'Reilly School of Technology Courses: UG Members Receive a 30% Discount To redeem, use Promotion Code "ORALL1" good for a 30% discount, in Step #2 of the enrollment process. Each course comes with a free O'Reilly book and a 7-day money-back guarantee. Register online: http://post.oreilly.com/rd/9z1zlgmqnh9onclvgcos8s92bl871okpv028fhtmt78 (This discount is not combinable with other offers.) Until next time-- Marsee Henon Forward this announcement - http://post.oreilly.com/f2f/9z1zmoc1tfk9phbsone4g9b7c3m3bf0ldtlhdikghoo ================================================================ O'Reilly 1005 Gravenstein Highway North Sebastopol, CA ? 95472 800-998-9938 http://post.oreilly.com/rd/9z1zpaf14ded6cope2bphpfo002ksmavfqpl32ft5ug Follow us on Twitter at: http://post.oreilly.com/rd/9z1zpao6sm37slklo1e25tv0tck8panus09oa644stg You are receiving this email because you are a User Group contact with O'Reilly Media. If you would like to stop receiving these newsletters or announcements from O'Reilly, send an email to marsee at oreilly.com ================================================================ From fred at redhotpenguin.com Tue Mar 16 15:17:16 2010 From: fred at redhotpenguin.com (Fred Moyer) Date: Tue, 16 Mar 2010 15:17:16 -0700 Subject: [sf-perl] [meeting] Fwd: Reminder: Simple form validation with Data::FormValidator is in one week. In-Reply-To: <1157259140.1268773671267.JavaMail.root@jobs.meetup.com> References: <1157259140.1268773671267.JavaMail.root@jobs.meetup.com> Message-ID: Simple form validation with Data::FormValidator is next Tuesday. We have a food sponsor for this event, which means the pizza and sodas are free! Hope to see you there. http://www.meetup.com/San-Francisco-Perl-Mongers/calendar/12793946/ ---------- Forwarded message ---------- From: Meetup Reminder Date: Tue, Mar 16, 2010 at 2:07 PM Subject: Reminder: Simple form validation with Data::FormValidator is in one week. To: fred at redhotpenguin.com [image: Meetup] Meetup Reminder San Francisco Perl Mongers Your group has a Meetup Tuesday, March 23, 2010 7:00 PM! You RSVPed Yes. What Simple form validation with Data::FormValidator When Tuesday, March 23, 2010 7:00 PM Who 11 Yes / 2 Maybe Where Six Apart World Headquarters 548 4th Street San Francisco CA 94107 Update your RSVP 11 Perl MongersRSVPed Yes, including? *see all * Meetup Description As the first talk in series of talks on form validation, Fred Moyer will present an overview of Data::FormValidator. Real world code examples will be presented, and you'll see how you can use Data::FormValidator to implement form validation for legacy codebases as well as new code. Data::FormValidator is a loosely coupled, highly flexible, and easy to use form validation module written by Mark Stosberg. This meeting will take place on Tuesday, March 23rd at 7pm at Six Apart World Headquarters. Fred Moyer's CPAN page: http://search.cpan.org/~phred/ Data::FormValidator on CPAN: http://search.cpan.org/dist/Data-FormValidator/ Announcement posted via App::PM::Announce Add *info at meetup.com* to your address book to receive all Meetup emails To manage your email settings for this group, click here Meetup, PO Box 4668 #37895 New York, New York 10163-4668 -------------- next part -------------- An HTML attachment was scrubbed... URL: From fred at redhotpenguin.com Tue Mar 16 18:45:28 2010 From: fred at redhotpenguin.com (Fred Moyer) Date: Tue, 16 Mar 2010 18:45:28 -0700 Subject: [sf-perl] Fwd: Open Source Bridge: CFP and raffle a free pass for your user group! In-Reply-To: <4B9E648A.7010102@opensourcebridge.org> References: <4B9E648A.7010102@opensourcebridge.org> Message-ID: Has anyone here been to this conference? ---------- Forwarded message ---------- From: Selena Deckelmann Date: Mon, Mar 15, 2010 at 9:47 AM Subject: Open Source Bridge: CFP and raffle a free pass for your user group! To: fred at redhotpenguin.com Hello Fred Moyer, I'm a volunteer working to organize Open Source Bridge, the conference for open source citizens. We're hosting it for the second time on June 1?4, 2010, in Portland, Oregon. We?re aiming to connect people across projects, languages and experience and would love to have members of Perl Mongers involved as speakers and participants. Details about the conference are included below. Bridge isn?t a typical conference. It?s entirely volunteer-run, by developers, for developers. Session tracks are technology agnostic, based instead around shared community experiences and focused on similarities between projects, not differences. Plus, we?ll be running a 24-hour hacker lounge on site for code sprints, bug bashes, bouncing ideas, starting new projects and generally socializing around code. We?d be delighted if you could mention Open Source Bridge at your user group meetings, post this email to your mailing list, and get us in touch with other groups in your community interested in participating. Our call for proposals runs through March 25th, which is fast approaching, so please pass this information on as soon as possible. We don?t expect something for nothing, so we?re giving all of your user group members a discounted registration rate of $200. That?s $25 off the Early Bird rate, and $100 off our regular registration. User groups are very important to us and our organizers are heavily involved in the local tech community. We?re also offering a free conference pass for you to give away to a member of your group. If you?re interested in more ways to promote the conference, let us know! Thank You! -Selena Open Source Bridge http://opensourcebridge.org/ ### CONFERENCE PASS RAFFLE INFORMATION You get one free conference pass to raffle off to a member of your group! We?ve found that these raffles work best when you: 1) Let all of your members know about the conference, dates, and URL: http://opensourcebridge.org/ 2) Allow anyone in the group to sign up for the raffle. 3) Draw the winner at random, preferably at a public meeting. When you have selected a winner, email usergroups at opensourcebridge.org, CC the winner, and we?ll register them for you. DETAILS TO SHARE WITH YOUR GROUP?S MEMBERS Open Source Bridge http://opensourcebridge.org Open Source Bridge is a conference for developers working with open source technologies. It will take place June 1?4, 2010, in Portland, Oregon, with five tracks connecting people across projects, languages and experience to explore how we do our work and why we participate in open source. The conference structure is designed to provide developers with an opportunity to learn from people they might not connect with at other events. Attendees will learn and interact at three days of traditional conference presentations, a day of free-form unconference sessions, and our 24-hour Hacker Lounge. This year we are thrilled to have an excellent downtown location at the Portland Art Museum ( http://pam.org/ ), an extra day packed full of open source goodness, and an on-site 24-hour Hacker Lounge! As a user group member, you can use the coupon code "osbugluv" to register for only $200 when you select either an Early Bird Registration (through April 1st), or a Regular Registration (after April 1st). Learn more and register today at http://opensourcebridge.org/attend/ The conference is run entirely by volunteers who believe in the need for an open source event that focuses on the culture of being an open source citizen, regardless of where in the stack you choose to code. All proceeds from conference registration and sponsorship go directly to the costs of the conference. Our event shares in-depth knowledge about using, creating and contributing to open source as citizens of a greater community. You?ll find relevant information whether you write web apps for the cloud, tinker with operating system internals, create hardware, run a startup, or blog about technology. We're still seeking proposals ? and we've just extended the deadline through March 25th ? so submit yours before time runs out at http://opensourcebridge.org/proposals/ The city of Portland is a great place to visit. It has a thriving technical community, a love of all things open source and offers many attractions for visiting geeks, including Powell?s technical books, dozens of local brewpubs, and large greenspaces like Forest Park?all accessible by mass transit. Visit http://opensourcebridge.org/ to learn more about the conference, see our session proposals, and register to attend. Thanks! -- Open Source Bridge Foundation http://opensourcebridge.org From josh at agliodbs.com Thu Mar 18 21:56:28 2010 From: josh at agliodbs.com (Josh Berkus) Date: Thu, 18 Mar 2010 21:56:28 -0700 Subject: [sf-perl] Fwd: Open Source Bridge: CFP and raffle a free pass for your user group! In-Reply-To: References: <4B9E648A.7010102@opensourcebridge.org> Message-ID: <4BA303FC.1020701@agliodbs.com> On 3/16/10 6:45 PM, Fred Moyer wrote: > Has anyone here been to this conference? Yes. It's cool and a lot of fun. Hacking. Community. The Lesbian Vegan Biker-Baker Posse. People should submit talks. -- -- Josh Berkus PostgreSQL Experts Inc. http://www.pgexperts.com From gatorreina at gmail.com Sun Mar 21 11:41:04 2010 From: gatorreina at gmail.com (Richard Reina) Date: Sun, 21 Mar 2010 13:41:04 -0500 Subject: [sf-perl] Cmenu question Message-ID: <489cf9d1003211141k4ee31877x66e8b189937d309d@mail.gmail.com> Happy Sunday, Was wondering if anyone has played around with Cmenu (or in any other perl GUI module) enough to know if there is a way to make the menu choices different colors? Like: Item 1 (in red) Item 2 (in blue) Item 3 (in yellow) Thanks, Richard -------------- next part -------------- An HTML attachment was scrubbed... URL: From Michael.Paoli at cal.berkeley.edu Sun Mar 21 12:51:43 2010 From: Michael.Paoli at cal.berkeley.edu (Michael Paoli) Date: Sun, 21 Mar 2010 12:51:43 -0700 Subject: [sf-perl] determining console or xwindows mode In-Reply-To: References: Message-ID: <20100321125143.11412fn6i0co0yzo@webmail.rawbw.com> Well, first question would be exactly what you're trying to do, and why? What if it's neither a Linux console nor some xwindow? If you really need to know if it's running bare on a Linux console, one can examine the output of tty - or better yet do what the tty command does, readlink on /proc/self/fd/0. Of course that's highly Linux-specific, and one would still have to match the results to possible Linux console devices. In general, the better approach however, on, e.g. use X or not for X capable program output is: o If option/environment on program is set to not use X, don't use X o notwithstanding the above, if DISPLAY is set, use X o and of course check and do reasonable thing(s) in case of error(s)/exception(s) Keep in mind: o may be neither console, X nor X-capable (e.g. X not available and on terminal or pseudo-terminal) o may be console, yet DISPLAY set and X fully available (e.g. user doing stuff from console, but prefers X capable stuff launch/display in X) o may be in X (e.g. xterm) but DISPLAY may not be set (e.g. user just wants text mode behavior of stuff started from there) o just because DISPLAY is set, doesn't mean it's useable (e.g. could be incorrect/vestigial setting, or don't have permission(s)) > Date: Sun, 28 Feb 2010 20:22:06 -0600 > From: Richard Reina > To: San Francisco Perl Mongers User Group > > I have a program that must run differently in xwindows then it would on a > linux console. I was wondering if there's a function to determine if a > program is running in a linux console or in xwindows so that upon execute > it can make the necessary accommodations? From gatorreina at gmail.com Sun Mar 21 18:39:27 2010 From: gatorreina at gmail.com (Richard Reina) Date: Sun, 21 Mar 2010 20:39:27 -0500 Subject: [sf-perl] perl GUI question Message-ID: <489cf9d1003211839k402efd70i1bb2adc2b55d80ef@mail.gmail.com> I have been using perlmenu to create menus for a small database API. However, perl menu does not allow color. Does anyone know if Cmenu or any other perl GUI (aside from perl-tk) that allows for color in menu items? Like the following: Choice 1 (in red) Choice 2 ( in blue) Choice 3 (in yellow) Thanks -------------- next part -------------- An HTML attachment was scrubbed... URL: From fred at redhotpenguin.com Mon Mar 22 13:22:46 2010 From: fred at redhotpenguin.com (Fred Moyer) Date: Mon, 22 Mar 2010 13:22:46 -0700 Subject: [sf-perl] [meeting] Fwd: Reminder: "Simple form validation with Data::FormValidator" is tomorrow, Tuesday, March 23, 2010 7:00 PM! In-Reply-To: <171027421.1269289047160.JavaMail.root@jobs.meetup.com> References: <171027421.1269289047160.JavaMail.root@jobs.meetup.com> Message-ID: Just a quick reminder that our March meeting is tomorrow night (Tuesday) at 7pm at Six Apart. Hope to see you there! If you plan on attending please rsvp - http://www.meetup.com/San-Francisco-Perl-Mongers/calendar/12793946/ ---------- Forwarded message ---------- From: Meetup Reminder Date: Mon, Mar 22, 2010 at 1:17 PM Subject: Reminder: "Simple form validation with Data::FormValidator" is tomorrow, Tuesday, March 23, 2010 7:00 PM! To: fred at redhotpenguin.com [image: Meetup] Meetup Reminder San Francisco Perl Mongers Your group has a Meetup tomorrow! You RSVPed Yes. What Simple form validation with Data::FormValidator When Tuesday, March 23, 2010 7:00 PM Who 11 Yes / 2 Maybe Where Six Apart World Headquarters 548 4th Street San Francisco CA 94107 Update your RSVP 11 Perl MongersRSVPed Yes, including? *see all * Meetup Description As the first talk in series of talks on form validation, Fred Moyer will present an overview of Data::FormValidator. Real world code examples will be presented, and you'll see how you can use Data::FormValidator to implement form validation for legacy codebases as well as new code. Data::FormValidator is a loosely coupled, highly flexible, and easy to use form validation module written by Mark Stosberg. This meeting will take place on Tuesday, March 23rd at 7pm at Six Apart World Headquarters. Fred Moyer's CPAN page: http://search.cpan.org/~phred/ Data::FormValidator on CPAN: http://search.cpan.org/dist/Data-FormValidator/ Announcement posted via App::PM::Announce Add *info at meetup.com* to your address book to receive all Meetup emails To manage your email settings for this group, click here Meetup, PO Box 4668 #37895 New York, New York 10163-4668 -------------- next part -------------- An HTML attachment was scrubbed... URL: From fred at redhotpenguin.com Wed Mar 24 13:03:02 2010 From: fred at redhotpenguin.com (Fred Moyer) Date: Wed, 24 Mar 2010 13:03:02 -0700 Subject: [sf-perl] Slides from last night's talk Message-ID: Here is the slide deck from last night's talk; thanks to everyone who showed up! http://www.slideshare.net/redhotpenguin/dfv-3542204 From extasia at extasia.org Thu Mar 25 11:10:25 2010 From: extasia at extasia.org (David Alban) Date: Thu, 25 Mar 2010 11:10:25 -0700 Subject: [sf-perl] [ot] pruning rsnapshot backups Message-ID: <4c714a9c1003251110v370e6544me20a1475fe9046e3@mail.gmail.com> greetings, i have a nightly rsnapshot job which is running out of disk space. assume that it's a major pita to get additional disk space and that i'm stuck with what i now have. currently i have three hundred and seventy five backup trees, representing slightly more than a year of daily backups. say i want to keep only twenty selected trees from this set. i'm assuming i can delete 355 of the trees without compromising the integrity of the remaining twenty trees, because each backup tree is completely independent of any other backup tree.[1] but i wanted to run this by some folks for a sanity check. do you think i'm safe doing this? am i missing anything? thanks, david [1] i know that when a backup tree is *created* rsnapshot uses the previous tree to determine whether to reuse an inode or to use a new one. but after the backup is created, the new tree is completely independent of the old tree, -- Live in a world of your own, but always welcome visitors. From mgrimes at cpan.org Thu Mar 25 11:49:47 2010 From: mgrimes at cpan.org (Mark Grimes) Date: Thu, 25 Mar 2010 14:49:47 -0400 Subject: [sf-perl] [ot] pruning rsnapshot backups In-Reply-To: <4c714a9c1003251110v370e6544me20a1475fe9046e3@mail.gmail.com> References: <4c714a9c1003251110v370e6544me20a1475fe9046e3@mail.gmail.com> Message-ID: <7c99e1971003251149s625dde1cn60272d975d5f838c@mail.gmail.com> Each tree is made up of files that may share inodes with other trees. Deleting one file will not delete its contents as long as there is another file that references that inode. You should be able to delete one tree without impacting others***. That said, since the trees sharing inodes, they typically don't take up all that much room. If you are just deleting blindly you might have to delete a whole bunch of trees to make an impact. I have a q&d perl script that I use to see which trees are really taking up space. Often you can spot something odd in just a few backups that are taking up a bunch of room. You can find the script at: http://www.peculier.com/dl/du-bank Hope it is helpful. *** I am not all that familiar with rsnapshot specifically, but I use the rsync --link-dest in my own backup scripts. On Thu, Mar 25, 2010 at 2:10 PM, David Alban wrote: > greetings, > > i have a nightly rsnapshot job which is running out of disk space. > assume that it's a major pita to get additional disk space and that > i'm stuck with what i now have. > > currently i have three hundred and seventy five backup trees, > representing slightly more than a year of daily backups. ?say i want > to keep only twenty selected trees from this set. ?i'm assuming i can > delete 355 of the trees without compromising the integrity of the > remaining twenty trees, because each backup tree is completely > independent of any other backup tree.[1] > > but i wanted to run this by some folks for a sanity check. > > do you think i'm safe doing this? ?am i missing anything? > > thanks, > david > > [1] i know that when a backup tree is *created* rsnapshot uses the > previous tree to determine whether to reuse an inode or to use a new > one. ?but after the backup is created, the new tree is completely > independent of the old tree, > -- > Live in a world of your own, but always welcome visitors. > _______________________________________________ > SanFrancisco-pm mailing list > SanFrancisco-pm at pm.org > http://mail.pm.org/mailman/listinfo/sanfrancisco-pm > From extasia at extasia.org Thu Mar 25 12:21:29 2010 From: extasia at extasia.org (David Alban) Date: Thu, 25 Mar 2010 12:21:29 -0700 Subject: [sf-perl] [ot] pruning rsnapshot backups In-Reply-To: <7c99e1971003251149s625dde1cn60272d975d5f838c@mail.gmail.com> References: <4c714a9c1003251110v370e6544me20a1475fe9046e3@mail.gmail.com> <7c99e1971003251149s625dde1cn60272d975d5f838c@mail.gmail.com> Message-ID: <4c714a9c1003251221l796281afq9e8946ef545a44a0@mail.gmail.com> hi mark, thanks for your response. until now, i've been finding the largest files in the latest snapshot and, if they don't need to be backed up, i delete them from all trees (except the original :-). so it's not a matter of finding the "largest" trees, it's just a matter of keeping a small subset of those generated to this point. anyway, thanks for confirming the independence of each tree! david p.s. related amusing story. i once tried to rsync an rsnapshot "metatree", that is, a tree containing multiple snapshots to different filesystem partition, but i forgot to use the --hard-links option (to preserve them) and i filled the destination partition. :-) On Thu, Mar 25, 2010 at 11:49 AM, Mark Grimes wrote: > Each tree is made up of files that may share inodes with other trees. > Deleting one file will not delete its contents as long as there is > another file that references that inode. You should be able to delete > one tree without impacting others***. > > That said, since the trees sharing inodes, they typically don't take > up all that much room. If you are just deleting blindly you might have > to delete a whole bunch of trees to make an impact. I have a q&d perl > script that I use to see which trees are really taking up space. Often > you can spot something odd in just a few backups that are taking up a > bunch of room. You can find the script at: > > http://www.peculier.com/dl/du-bank > > Hope it is helpful. > > *** I am not all that familiar with rsnapshot specifically, but I use > the rsync --link-dest in my own backup scripts. -- Live in a world of your own, but always welcome visitors. From rjray at blackperl.com Thu Mar 25 13:36:48 2010 From: rjray at blackperl.com (Randy J. Ray) Date: Thu, 25 Mar 2010 13:36:48 -0700 Subject: [sf-perl] [jobs] Sunnyvale-based NetApp, Inc. Message-ID: <4BABC960.2050305@blackperl.com> My company, NetApp (http://www.netapp.com) has a number of openings for Perl programmers. In particular, my team (QA automation for one of the product-groups) has two openings currently. The primary requirements are understanding of QA and QA automation, and of course plenty of Perl knowledge. I also personally know a QA manager in a different team looking for someone with similar skills, who is also comfortable writing Perl on Windows platforms (which is less critical in my team). All of these are at the corporate HQ in Sunnyvale, CA, off of CA-237 and near highway 101. Our current listings can be searched here: https://careers.netapp.com/1033/ASP/TG/cim_home.asp?partnerid=25093&siteid=5100 When I searched just now (clicking on "Search openings", then using "Perl" for a keyword and selecting the Sunnyvale site in the "Posting Location" field), there were a total of 37 matching listings. If you have any questions, or are interested, please feel free to write me at this address or at rjray at netapp.com (NetApp address). Randy -- """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" Randy J. Ray Sunnyvale, CA http://www.rjray.org rjray at blackperl.com Silicon Valley Scale Modelers: http://www.svsm.org From tkeefer at ebay.com Fri Mar 26 09:00:06 2010 From: tkeefer at ebay.com (Keefer, Tim) Date: Fri, 26 Mar 2010 10:00:06 -0600 Subject: [sf-perl] Perl Job in San Jose Message-ID: Hi All, If anyone is interested in working in the San Jose (Campbell) area our group has an opening for a Perl engineer. The position is a 1yr contract with potential to hire. http://jobs.perl.org/job/11968 Thanks, -Tim From fred at redhotpenguin.com Fri Mar 26 09:56:31 2010 From: fred at redhotpenguin.com (Fred Moyer) Date: Fri, 26 Mar 2010 09:56:31 -0700 Subject: [sf-perl] Fwd: [pm_groups] Google Summer of Code and TPF call for students In-Reply-To: <201003260350.55273.scratchcomputing@gmail.com> References: <201003260350.55273.scratchcomputing@gmail.com> Message-ID: In case anyone is interested in being a mentor. ---------- Forwarded message ---------- From: Eric Wilhelm Date: Fri, Mar 26, 2010 at 3:50 AM Subject: [pm_groups] Google Summer of Code and TPF call for students To: pm_groups at pm.org Cc: Jerry Gay , Jonathan Leto Hi Perl Mongers, TPF is participating in GSoC 2010 and will begin accepting applications from students on the 29th. ?Please share this info with your groups and local academic contacts. If you are a college student interested in Open Source software, now is the time to get involved. ?http://code.google.com/soc/ Each year, Google offers students the opportunity to spend their summer coding on open source projects. You propose a project, and if selected, you're assigned a mentor and provided a $4500 stipend. It is a competitive program to get into, but offers an amazing amount of real-world experience and the ability to get seriously involved in an open source project of your choosing. The Perl Foundation spans a wide variety of projects including Perl 5, Perl 6, and Parrot with many great mentors knowledgeable in areas ranging from language design, virtual machines, and compilers through web and desktop applications. This program is a great chance to get more involved in the Perl community and put a substantial project worth of source code in your portfolio. Applications are due April 9th. ?http://www.perlfoundation.org/perl5/index.cgi?gsoc Thanks, Eric -- http://pdx.pm.org -- Request pm.org Technical Support via support at pm.org pm_groups mailing list pm_groups at pm.org http://mail.pm.org/mailman/listinfo/pm_groups From fred at redhotpenguin.com Fri Mar 26 12:31:05 2010 From: fred at redhotpenguin.com (Fred Moyer) Date: Fri, 26 Mar 2010 12:31:05 -0700 Subject: [sf-perl] Fwd: [yapc] Call for Talks ending soon! In-Reply-To: <20100326192914.GC16630@mawode.com> References: <20100326192914.GC16630@mawode.com> Message-ID: FYI... ---------- Forwarded message ---------- From: Walt Mankowski Date: Fri, Mar 26, 2010 at 12:29 PM Subject: Fwd: [yapc] Call for Talks ending soon! To: phl at lists.pm.org FYI... ----- Forwarded message from BAIRH at nationwide.com ----- Date: Fri, 26 Mar 2010 15:19:49 -0400 From: BAIRH at nationwide.com To: yapc at pm.org Subject: [yapc] Call for Talks ending soon! X-Mailer: Lotus Notes Release 6.5.4 March 27, 2005 The call for speakers ends next week! ?3/31/2010! ?Get out to the website, get your self registered and get your talks and lighting talks in before it is too late! http://robonperl.blogspot.com/2010/02/call-for-presentations-for-yapcna2010.html ) YAPC::NA::2010 is just around the corner. (Well, in as much as something 8 weeks away is "around the corner.") Last week, I met with Heath Bair and the other organizers and took the position of speaker liaison. So, I should probably talk some about what we're looking for. YAPC::NA::2010 is going to be about "Modern Perl 5". We believe that Perl 5 is a vibrant and living language with many uncharted places it can go. Perl 6 is going to be great, but we can't wait until Christmas for Perl 6. So, we're looking for presentations about Perl 5 in all of its modern glory. Whatcha got? You'll need to register (or login) to the YAPC::NA::2010 website (http://yapc2010.com/), then after registering for the conference, you can submit your CFP. Heath Bair (440) 289-9820 _______________________________________________ yapc mailing list yapc at pm.org http://mail.pm.org/mailman/listinfo/yapc ----- End forwarded message ----- -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iD8DBQFLrQsJXfGeK2entYQRArYNAKDIq3t26CsgrNk0vaXc0lwLZrJk7wCbBg// YP4YlS3Kb2aQRDdShbk73gI= =nE8y -----END PGP SIGNATURE----- -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 189 bytes Desc: not available URL: From fred at redhotpenguin.com Tue Mar 30 12:33:34 2010 From: fred at redhotpenguin.com (Fred Moyer) Date: Tue, 30 Mar 2010 12:33:34 -0700 Subject: [sf-perl] cpanminus Message-ID: Judging my usage over the last month, I'm guessing that cpanminus will save me about 15-20 hours throughout the rest of 2010. Thanks @miyagawa!