mirror of
https://github.com/msmhq/msm.git
synced 2024-08-30 18:12:35 +00:00
Can now delete jar groups.
This commit is contained in:
parent
094bcd45ad
commit
d7d7b31b06
17
msm
17
msm
@ -131,8 +131,7 @@ manager_jars_remote_create() {
|
||||
}
|
||||
|
||||
manager_jars_remote_getlatest() {
|
||||
if is_valid_name "$1"; then
|
||||
if [[ -e $JAR_STORAGE_PATH/$1 ]]; then
|
||||
if is_valid_name "$1" && [[ -e $JAR_STORAGE_PATH/$1 ]]; then
|
||||
if [[ -e $JAR_STORAGE_PATH/$1/$JAR_REMOTE_TARGET ]]; then
|
||||
printf "Downloading latest version... "
|
||||
|
||||
@ -191,6 +190,19 @@ manager_jars_remote_getlatest() {
|
||||
else
|
||||
echo "No remote with that name."
|
||||
fi
|
||||
}
|
||||
|
||||
manager_jars_remote_delete() {
|
||||
if is_valid_name "$1" && [[ -e $JAR_STORAGE_PATH/$1 ]]; then
|
||||
printf "Are you sure you want to delete this jar group [y/N]: "
|
||||
|
||||
read answer
|
||||
if [[ $answer =~ ^y|Y|yes$ ]]; then
|
||||
as_user "rm -r $JAR_STORAGE_PATH/$1"
|
||||
echo "Jar group was deleted."
|
||||
else
|
||||
echo "Jar group was NOT deleted."
|
||||
fi
|
||||
else
|
||||
echo "No remote with that name."
|
||||
fi
|
||||
@ -228,6 +240,7 @@ case "$1" in
|
||||
manager_jars_remote_create $4 $5
|
||||
;;
|
||||
delete)
|
||||
manager_jars_remote_delete $4
|
||||
;;
|
||||
rename)
|
||||
;;
|
||||
|
Loading…
Reference in New Issue
Block a user