Created
June 19, 2023 14:04
-
-
Save earnhardt3rd/0ff537cfd546b584c255fdbe6f8460c1 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
| require 'getopts.pl'; | |
| Getopts('m:d:t'); | |
| my $MODE = uc($opt_m) || ""; | |
| my $DEBUG = $opt_d || 0; | |
| if (defined $opt_t) { my %TEST = &_TODO_ADD();} | |
| 1; | |
| sub _TODO_ADD { | |
| my $tdFile = $_[0] || ""; | |
| print " Enter Item for To Do List:"; | |
| my $tdi = <STDIN>; | |
| chomp($tdi); | |
| if ($tdi ne "") { | |
| my $a = &Ask("Do you want to own this item?","Yes","No","Exit"); | |
| if ($a eq "Exit") {&_EXIT_CLEAN();} | |
| my $owner=$BINNAME; | |
| if ($a eq "No") { | |
| $owner=""; | |
| } | |
| my $status = &Ask("Please select a Status:","UnAssigned","Pending","WIP","Complete"); | |
| if (! -f $tdFile) { | |
| open (TODOFH,"> $tdFile"); | |
| print TODOFH "TO_DO_ITEM,OWNER,STATUS,RELEASE\n"; | |
| close(TODOFH); | |
| } | |
| open (TODOFH,">> $tdFile"); | |
| print TODOFH "$tdi,$owner,$status,$PACKAGE\n"; | |
| close(TODOFH); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment