This commit is contained in:
abs3nt 2024-10-07 18:48:43 -07:00
parent 3fd45047d4
commit cbd1e505dc
Signed by: abs3nt
GPG Key ID: A7BD96A8BAB04C09

View File

@ -1,31 +1,15 @@
repo() { repo() {
case "$1" in local cmd="$1"
'get' ) local arg="$2"
repo_get "$2"
;; case "$cmd" in
'open' ) 'get' ) repo_clone "git" "$arg" ;;
repo_open 'aur' ) repo_clone "aur" "$arg" ;;
;; 'open') repo_open ;;
'aur' ) 'list') list_repos ;;
repo_aur "$2" 'go' | 'goto') repo_goto "$arg" ;;
;; 'new' | 'create') repo_new "$arg" ;;
'list' ) 'help' | "-h" | "-help" | "--help") repo_help ;;
list_repos *) echo "Unknown command: $cmd"; repo_help; return 1 ;;
;;
'go' | 'goto')
repo_goto "$2"
;;
'new' | 'create')
repo_new "$2"
;;
'help' | "-h" | "-help" | "--help")
repo_help
;;
* )
echo "Unknown command: $1"
repo_help
return 1
;;
esac esac
} }