dotfiles/home/bin/executable_todo

10 lines
210 B
Bash

#!/bin/bash
if [ -z "$*" ]; then
echo "Usage: todo <task name>"
exit 1
fi
TASK_NAME="$*"
ENCODED_NAME=$(printf %s "$TASK_NAME" | jq -sRr @uri)
open "omnifocus:///add?name=$ENCODED_NAME&autosave=true"