Commit 8b124e01 authored by Vitaly Lipatov's avatar Vitaly Lipatov

gitask: strip ANSI colors, add_changelog: skip editor without tty

parent 4815cc81
......@@ -250,7 +250,7 @@ if [ "$1" = "ls" ] ; then
# TODO: add support ls -a (with subtasks)
if [ -n "$1" ] || ! isatty ; then
showcmd "$GEARHOST>" girar-show "$@"
GIT_ALT=$GEARHOST girar-show "$@"
GIT_ALT=$GEARHOST girar-show "$@" | sed 's/\x1b\[[0-9;]*m//g'
else
showcmd "$GEARHOST>" 'girar-show | head -n20'
GIT_ALT=$GEARHOST girar-show | head -n20
......
......@@ -270,6 +270,7 @@ add_changelog_helper()
[ -n "$QUIET" ] && return
[ -z "$EDITOR" ] && { echo "skip changelog editing without EDITOR var"; return 0 ; }
! tty -s && { echo "skip changelog editing without tty"; return 0 ; }
# If changelog sucessfully added, let us to edit
if [ "$R" = "0" ]; then
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment