Created
October 12, 2010 18:04
-
-
Save jhannah/622624 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/perl | |
| use strict; | |
| use warnings; | |
| $site = "http://sample.com"; | |
| $testcommand = "test command"; | |
| print "SAMPLE\n"; | |
| Base(); | |
| if (($base eq "show") && ($command eq "options")){ | |
| Options(); | |
| } | |
| if ($base eq "show"){ | |
| Show(); | |
| } | |
| exit; | |
| # ---------- | |
| # subs down here | |
| # ----------- | |
| sub Base { | |
| print ">"; | |
| our $ex=<STDIN>; | |
| chomp $ex; | |
| our ($base, $command) = split(/ /, $ex); | |
| } | |
| sub Show{ | |
| print "s0me test shit\n"; | |
| print "ex: six66 \n"; | |
| Base(); | |
| } | |
| sub Options{ | |
| print "Site : $site \n"; | |
| print "Test : $testcommand\n"; | |
| Base(); | |
| } | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment