aboutsummaryrefslogtreecommitdiffstats
path: root/gitjoe-rmrepo.pl
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-07-07 20:49:26 +0200
committerJozanLeClerc <bousset.rudy@gmail.com>2020-07-07 20:49:26 +0200
commitc546fee3fa3f3f1430bd289c51fc6a9e1a1030bf (patch)
tree5cf3e5c2396ef327383fba372cedfccf7bb5d98f /gitjoe-rmrepo.pl
parenttest (diff)
downloadjoe-scripts-c546fee3fa3f3f1430bd289c51fc6a9e1a1030bf.tar.gz
joe-scripts-c546fee3fa3f3f1430bd289c51fc6a9e1a1030bf.tar.bz2
joe-scripts-c546fee3fa3f3f1430bd289c51fc6a9e1a1030bf.tar.xz
joe-scripts-c546fee3fa3f3f1430bd289c51fc6a9e1a1030bf.tar.zst
joe-scripts-c546fee3fa3f3f1430bd289c51fc6a9e1a1030bf.zip
Better dir
Diffstat (limited to 'gitjoe-rmrepo.pl')
-rwxr-xr-xgitjoe-rmrepo.pl33
1 files changed, 0 insertions, 33 deletions
diff --git a/gitjoe-rmrepo.pl b/gitjoe-rmrepo.pl
deleted file mode 100755
index 30ce4d2..0000000
--- a/gitjoe-rmrepo.pl
+++ /dev/null
@@ -1,33 +0,0 @@
-#!/usr/local/bin/perl
-
-use strict;
-use warnings;
-use Term::ANSIColor;
-
-sub main {
- my $argc = $#ARGV + 1;
- if ($argc < 2) {
- print colored("Failed!\n", 'bold red')
- . "Missing argument, 2 needed "
- . colored("[user - reponame]", 'bold')
- . "\n";
- exit 1;
- }
- my $usr = $ARGV[0];
- my $repo = $ARGV[1];
- my $home_dir = '/usr/home/' . $usr . '/';
- if (substr($repo, -4) ne '.git') {
- $repo = $repo . '.git';
- }
- $repo = $repo . '/';
- system(
- '/usr/local/bin/dash',
- '-c',
- '/bin/rm -rfv ' . $home_dir . $repo
- );
- exit;
-}
-
-main();
-
-__END__