Ver código fonte

created MNU.pm and drv.pl

master
gashapwn 3 anos atrás
pai
commit
93a646a591
2 arquivos alterados com 37 adições e 0 exclusões
  1. +25
    -0
      MNU.pm
  2. +12
    -0
      drv.pl

+ 25
- 0
MNU.pm Ver arquivo

@@ -0,0 +1,25 @@
#!/usr/bin/perl

use warnings;
use strict;

package MNU;

sub prompt(){
printf("> ");
my $in;
$in = <STDIN>;
chomp $in;
return $in;
}

sub loop(){
my $in = prompt();

return 0 unless $in;
return 0 if $in eq "quit";
return 1;
}

return 1;

+ 12
- 0
drv.pl Ver arquivo

@@ -0,0 +1,12 @@
#!/usr/bin/perl

use warnings;
use strict;

use lib "./";
use MNU;

while(MNU->loop()){
}


Carregando…
Cancelar
Salvar