|
@@ -22,6 +22,10 @@ function list-utilities () {
|
|
}
|
|
}
|
|
|
|
|
|
function new-utility () {
|
|
function new-utility () {
|
|
|
|
+ if [[ $# -lt 2 ]] ; then
|
|
|
|
+ echo "ledgerutil new name ( perl / shell / python )"
|
|
|
|
+ exit 1
|
|
|
|
+ fi
|
|
name=$1
|
|
name=$1
|
|
shift
|
|
shift
|
|
type=$1
|
|
type=$1
|
|
@@ -59,6 +63,10 @@ EOF
|
|
}
|
|
}
|
|
|
|
|
|
function edit-utility () {
|
|
function edit-utility () {
|
|
|
|
+ if [[ $# -lt 1 ]] ; then
|
|
|
|
+ echo "ledgerutil edit name"
|
|
|
|
+ exit 1
|
|
|
|
+ fi
|
|
name=$1
|
|
name=$1
|
|
shift
|
|
shift
|
|
if [[ -e ~/.ledger/utilities/${name}.sh ]] ; then
|
|
if [[ -e ~/.ledger/utilities/${name}.sh ]] ; then
|