Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Run and/or download code directly from perlmonk nodes.

by diotalevi (Canon)
on Aug 20, 2003 at 22:55 UTC ( #285317=note: print w/replies, xml ) Need Help??


in reply to Run and/or download code directly from perlmonk nodes.

Most of the time I just use an even simpler shell script and redirect to whatever I feel needs the code. So `pmget 153861 | perl` would download the code from your node and just run it.

#!/bin/sh lynx -source "http://www.perlmonks.org/index.pl?displaytype=displaycod +e&node=$1"

Updated to add the displaytype=displaycode. I was typing it from memory and forgot that part. Oops!

Replies are listed 'Best First'.
Re: Re: Run and/or download code directly from perlmonk nodes.
by Dog and Pony (Priest) on Aug 21, 2003 at 00:37 UTC
    Heh. Suddenly this old node pops up and has a reply. :)

    Anyhow, almost any problem has multiple solutions, as usual. Yours doesn't work, for one thing - but that is a typo, right? ;-) Missing a &displaytype=displaycode if I read it correctly, I did not try it.

    With the typo fixed, I suppose it does (some of) the same job nicely, as long as one has lynx installed. I seem to recall that this script scratched an itch on Windows (which has lynx available if needs be), but mainly, all those scripts written and posted in those days was to learn and have fun.

    Fun to be reminded of the things one once did. :)


    You have moved into a dark place.
    It is pitch black. You are likely to be eaten by a grue.
Re: Re: Run and/or download code directly from perlmonk nodes.
by eric256 (Parson) on Aug 20, 2003 at 23:12 UTC

    maybe i'm crazy...but wouldn't that get all the source... including the tables etc?

    ___________
    Eric Hodges

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://285317]
help
Chatterbox?
[Corion]: Discipulus: If you want to rewrite the SVG, then yes, something like XML::Twig should be enough. I would try to not modify the SVG but only modify the display, but so far I haven't convinced IE to change the style...
Corion gives up
[Discipulus]: ah! so you mean if i need a static image i can use Twig, if on the fly better css selector and mody attrs (jquery?), rigth?
[LanX]: not sure what you guys are taking about, but a DOM manipulation in JS shouldn't be difficult
[Corion]: Discipulus: Yeah, that's what I would try (but so far, I can't even change the colors manually in the SVG, which is why I gave up ;) )
Discipulus bad sign..
[Discipulus]: italian doc says to modify somehow the initial SVG before using it with D3.js
[Discipulus]: LanX the fact is that my js ability is even poorer than my Perl one..
[LanX]: oh its negative? ;P

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (13)
As of 2017-03-23 09:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (285 votes). Check out past polls.