mirror of
https://github.com/garrytan/gstack.git
synced 2026-11-04 07:47:27 +01:00
fix: a touch whose identity read comes back empty keeps the recorded identity and its runs (GST-1205 review)
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
This commit is contained in:
1 parent
76f67dbcdb
commit
14524f7e49
1 file changed
+1
@@ -280,6 +280,7 @@ case "$VERB" in
|
||||
}
|
||||
_tmp="$DIR/.$PID.$$"
|
||||
_id=$(identity "$PID") _keep="" _held=0 _now=$(date +%s)
|
||||
[ -n "$_id" ] || _id=$(head -1 "$DIR/$PID" 2>/dev/null)
|
||||
if [ -f "$DIR/$PID" ] && [ "$(head -1 "$DIR/$PID" 2>/dev/null)" = "$_id" ]; then
|
||||
if [ -n "$RUN" ]; then _keep=$(fresh "$DIR/$PID" "run $RUN"); else _keep=$(fresh "$DIR/$PID" hold); fi
|
||||
[ -z "$(sed -n '2,$p' "$DIR/$PID" 2>/dev/null | grep -v '^$')" ] && _held=1
|
||||
|
||||
Reference in new issue
Block a user