mirror of
https://github.com/olexsmir/dotfiles.git
synced 2026-01-15 08:41:34 +02:00
todo: update config; refactor actions
This commit is contained in:
parent
d5d6748eb3
commit
b68db8cdc1
5 changed files with 17 additions and 4 deletions
|
|
@ -8,8 +8,13 @@ if [[ $action == "usage" ]]; then
|
|||
fi
|
||||
|
||||
item=$1
|
||||
if [[ $item == "" ]]; then
|
||||
TODOTXT_VERBOSE=0 $TODO_FULL_SH ls @url
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [[ ! "$item" =~ ^[0-9]+$ ]]; then
|
||||
echo "$item: invalid item number"
|
||||
echo "provided [task_number] is invalid: $item"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
|
@ -21,7 +26,7 @@ if [[ -z "$URL" ]]; then
|
|||
exit 1
|
||||
fi
|
||||
|
||||
if [[ ! "#URL" =~ ^(?!https?:\/\/) ]]; then
|
||||
if [[ ! "$URL" =~ ^(?!https?:\/\/) ]]; then
|
||||
URL="https://$URL"
|
||||
fi
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue