mirror of
https://github.com/wahyd4/gvm.git
synced 2026-08-10 05:16:13 +10:00
24 lines
562 B
Bash
Executable File
24 lines
562 B
Bash
Executable File
#!/bin/bash
|
|
if [[ $1 == "pkgset" ]] && [[ $2 == "delete" ]]; then
|
|
if [[ -n $3 ]]; then
|
|
CUR_VER=`readlink $GVM_ROOT/go | awk '{ n=split($1,path,"/"); print path[n] }'`
|
|
if [[ $CUR_VER == "" ]]; then
|
|
echo "ERROR: No Go version selected"
|
|
exit 1
|
|
else
|
|
rm -rf $GVM_ROOT/pkgsets/$CUR_VER/$3
|
|
if [[ $? -ne 0 ]]; then
|
|
echo "ERROR: Could not delete package set"
|
|
exit 1
|
|
fi
|
|
fi
|
|
else
|
|
echo "ERROR: Please specifiy the name"
|
|
exit 1
|
|
fi
|
|
else
|
|
echo "Please use gvm [action] to call this file"
|
|
exit 1
|
|
fi
|
|
|