Next System Programming in Perl 19

Current directory

        plover% pwd
        /home/mjd
        plover% cat do-cd
        chdir '/tmp';
        print "I am now in ", qx{pwd}, "\n";
        plover% perl do-cd
        I am now in /tmp.
        plover% pwd
        /home/mjd


Next Copyright © 2003 M. J. Dominus