remove edit command - notes - a console notes manager using git | |
Log | |
Files | |
Refs | |
Tags | |
LICENSE | |
--- | |
commit 5b8d8d6280ab1db93048b40558176d3ccc7d5615 | |
parent ec70c177db133ec5a0d8ccc4bfd7c11ae9334573 | |
Author: Solene Rapenne <[email protected]> | |
Date: Fri, 13 Jul 2018 22:45:18 +0200 | |
remove edit command | |
Diffstat: | |
M completions/ksh_completion | 2 +- | |
M notes | 5 ++--- | |
M notes.1 | 3 +-- | |
3 files changed, 4 insertions(+), 6 deletions(-) | |
--- | |
diff --git a/completions/ksh_completion b/completions/ksh_completion | |
@@ -1,3 +1,3 @@ | |
FILES=$(notes _files) | |
-set -A complete_notes_1 -- ls edit history help init cat rm last "$FILES" | |
+set -A complete_notes_1 -- ls history help init cat rm last "$FILES" | |
set -A complete_notes_2 -- "$FILES" | |
diff --git a/notes b/notes | |
@@ -14,7 +14,7 @@ fi | |
usage() { | |
NAME=$(basename $0) | |
- echo "$NAME [init|ls|edit|history|cat|rm] [path]" | |
+ echo "$NAME [init|ls|history|cat|rm] [path]" | |
echo "" | |
echo " $NAME init" | |
echo " - initialize the git repository" | |
@@ -22,7 +22,7 @@ usage() { | |
echo " $NAME [ls]" | |
echo " - show hierarchy tree" | |
echo "" | |
- echo " $NAME edit path" | |
+ echo " $NAME path" | |
echo ' - start $EDITOR on file and auto commit' | |
echo "" | |
echo " $NAME history path" | |
@@ -143,7 +143,6 @@ PARAM2=$2 | |
if [ "$PARAM1" = "ls" ]; then display ; exit 0 ; fi | |
if [ "$PARAM1" = "init" ]; then initialization ; exit 0 ; fi | |
if [ "$PARAM1" = "" ]; then display ; exit 0 ; fi | |
-if expr "$PARAM1" : "^e" >/dev/null && [ -n "$PARAM2" ]; then edit "$PARAM2" … | |
if expr "$PARAM1" : "^hi" >/dev/null && [ -n "$PARAM2" ]; then histo "$PARAM2"… | |
if expr "$PARAM1" : "^c" >/dev/null && [ -n "$PARAM2" ]; then show_file "$PARA… | |
if [ "$PARAM1" = "rm" ] && [ -n "$PARAM2" ]; then delete "$PARAM2" ; exit 0 ; … | |
diff --git a/notes.1 b/notes.1 | |
@@ -39,8 +39,7 @@ to display commit history. | |
display files and their last commit time ordered by time. | |
This is useful to find which files have been modified lastly. | |
-.It Nm Ar file | |
-.It Nm Cm edit Ar file | |
+.It Nm Cm Pa file | |
execute $EDITOR on | |
.Ar file | |
and then call |