We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 4b12295 + 3d77cf0 commit b9dab86Copy full SHA for b9dab86
_helpers/helpers.sh
@@ -85,6 +85,14 @@ function previewnotes {
85
86
}
87
88
+function opennote {
89
+ if [ -z "$EDITOR" ]; then
90
+ open $1
91
+ else
92
+ eval "$EDITOR $1"
93
+ fi
94
+}
95
+
96
# help
97
# --------------------------------------------------
98
unset usage
bin/notes
@@ -120,7 +120,7 @@ while getopts "$optstring" opt; do
120
n)
121
checkname "$OPTARG"
122
mkdir -p $(dirname "$OPTARG${_ext}") && touch "$OPTARG${_ext}"
123
- open "$OPTARG${_ext}"
+ opennote "$OPTARG${_ext}"
124
exit 0
125
;;
126
@@ -207,7 +207,7 @@ if [ -z "$2" ]; then
207
208
fi
209
210
- open $1${_ext}
+ opennote $1${_ext}
211
212
213
0 commit comments