Skip to content

Commit

Permalink
style(bash-v2): use herestring in activehelp extraction
Browse files Browse the repository at this point in the history
Herestrings read cleaner than process substitutions, and work in posix
mode (but we do and will have some process substitutions so this doesn't
matter much). Both approaches may end up using temporary files.
  • Loading branch information
scop committed Jun 18, 2022
1 parent a28f105 commit b8b0703
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bash_completionsV2.go
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ __%[1]s_extract_activeHelp() {
# Not an activeHelp line but a normal completion
completions+=("$comp")
fi
done < <(printf "%%s\n" "${out}")
done <<<"${out}"
}
__%[1]s_handle_completion_types() {
Expand Down

0 comments on commit b8b0703

Please sign in to comment.