diff options
author | Luke Shumaker <lukeshu@lukeshu.com> | 2017-04-19 11:56:33 -0400 |
---|---|---|
committer | Luke Shumaker <lukeshu@lukeshu.com> | 2017-04-19 11:56:33 -0400 |
commit | 682d9e7d44079b3c2be4c2bc5b859dbdb6ac4ca6 (patch) | |
tree | a5c053b03ab1044412824ba1aa682f9c81a16ead /git-shell-commands | |
parent | bb098d66d9358f0fe4fe0c42233f4b9874f630c8 (diff) |
test: rm git-shell-commands/delete-repo
Diffstat (limited to 'git-shell-commands')
-rwxr-xr-x | git-shell-commands/delete-repo | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/git-shell-commands/delete-repo b/git-shell-commands/delete-repo deleted file mode 100755 index 04e896b..0000000 --- a/git-shell-commands/delete-repo +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/bash -# * delete-repo REPO [REPO2...] -# Allows users to delete REPO.git permanently -# Example: delete-repo packages/libretools packages/pbs-tools - -set -e - -for repo in "$@"; do - repo="$(sed -r 's,^/*,,' <<<"$repo")" - _repo="$(sed -r -e '/(^|\/)\.\.($|\/)/d' -e "s,[^A-Za-z0-9\./_~-],,g" <<<"$repo")" - test "$repo" != "$_repo" && { printf 'Illegal name: %s\n' "${repo}"; continue; } - test ! -d "$repo".git && { printf 'Does not exist: %s\n' "${repo}"; continue; } - - echo "Removing ${repo}.git" - # lo and behold absolute horror - rm -rf -- "$repo".git -done |