Skip to content

Commit

Permalink
Open a given workflows file when polish-workflow
Browse files Browse the repository at this point in the history
There is undefined `${file}` variable that is used as a reference to a
given workflows file. But the variable is never initialized. As the
result, the command just opens the editor, but not a given file. Now,
this variable is replaced with `${1}` (a reference to the first input
parameter).
  • Loading branch information
extsoft committed Apr 6, 2020
1 parent c9cbdc0 commit 97cc560
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions libexec/git-elegant-polish-workflow
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@ MESSAGE

default() {
_error-if-empty "${1}" "Please specify a workflow file name"
if test -e ${file}; then
$(git config core.editor) ${file}
if test -e ${1}; then
$(git config core.editor) ${1}
else
error-text "The '${file}' file does not exist."
error-text "The '${1}' file does not exist."
exit 43
fi
}

0 comments on commit 97cc560

Please sign in to comment.