Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert wordbreak (colon) patch #72

Merged
merged 1 commit into from
May 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions lib/completely/templates/template.erb
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@
local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")
local compline="${compwords[*]}"

local original_comp_wordbreaks="$COMP_WORDBREAKS"
COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"

% if ENV['COMPLETELY_DEBUG']
if [[ -n "$COMPLETELY_DEBUG" ]]; then
echo "compline: '$compline'" > 'completely-debug.txt'
Expand All @@ -46,8 +43,6 @@

% end
esac

COMP_WORDBREAKS="$original_comp_wordbreaks"
} &&
complete -F <%= function_name %> <%= command %>

Expand Down
5 changes: 0 additions & 5 deletions spec/approvals/cli/generated-script
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ _mygit_completions() {
local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")
local compline="${compwords[*]}"

local original_comp_wordbreaks="$COMP_WORDBREAKS"
COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"

case "$compline" in
'status'*)
while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_mygit_completions_filter "--help --verbose --branch $(git branch 2>/dev/null)")" -- "$cur")
Expand All @@ -48,8 +45,6 @@ _mygit_completions() {
;;

esac

COMP_WORDBREAKS="$original_comp_wordbreaks"
} &&
complete -F _mygit_completions mygit

Expand Down
5 changes: 0 additions & 5 deletions spec/approvals/cli/generated-script-alt
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ _mycomps() {
local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")
local compline="${compwords[*]}"

local original_comp_wordbreaks="$COMP_WORDBREAKS"
COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"

case "$compline" in
'status'*)
while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_mycomps_filter "--help --verbose --branch $(git branch 2>/dev/null)")" -- "$cur")
Expand All @@ -48,8 +45,6 @@ _mycomps() {
;;

esac

COMP_WORDBREAKS="$original_comp_wordbreaks"
} &&
complete -F _mycomps mygit

Expand Down
5 changes: 0 additions & 5 deletions spec/approvals/cli/generated-wrapped-script
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@ give_comps() {
echo $' local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")'
echo $' local compline="${compwords[*]}"'
echo $''
echo $' local original_comp_wordbreaks="$COMP_WORDBREAKS"'
echo $' COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"'
echo $''
echo $' case "$compline" in'
echo $' \'status\'*)'
echo $' while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_mygit_completions_filter "--help --verbose --branch $(git branch 2>/dev/null)")" -- "$cur")'
Expand All @@ -49,8 +46,6 @@ give_comps() {
echo $' ;;'
echo $''
echo $' esac'
echo $''
echo $' COMP_WORDBREAKS="$original_comp_wordbreaks"'
echo $'} &&'
echo $' complete -F _mygit_completions mygit'
echo $''
Expand Down
5 changes: 0 additions & 5 deletions spec/approvals/cli/test/completely-tester-1.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,6 @@ _mygit_completions() {
local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")
local compline="${compwords[*]}"

local original_comp_wordbreaks="$COMP_WORDBREAKS"
COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"

case "$compline" in
'status'*)
while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_mygit_completions_filter "--help --verbose --branch $(git branch 2>/dev/null)")" -- "$cur")
Expand All @@ -56,8 +53,6 @@ _mygit_completions() {
;;

esac

COMP_WORDBREAKS="$original_comp_wordbreaks"
} &&
complete -F _mygit_completions mygit

Expand Down
5 changes: 0 additions & 5 deletions spec/approvals/cli/test/completely-tester-2.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,6 @@ _mygit_completions() {
local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")
local compline="${compwords[*]}"

local original_comp_wordbreaks="$COMP_WORDBREAKS"
COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"

case "$compline" in
'status'*)
while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_mygit_completions_filter "--help --verbose --branch $(git branch 2>/dev/null)")" -- "$cur")
Expand All @@ -56,8 +53,6 @@ _mygit_completions() {
;;

esac

COMP_WORDBREAKS="$original_comp_wordbreaks"
} &&
complete -F _mygit_completions mygit

Expand Down
5 changes: 0 additions & 5 deletions spec/approvals/cli/test/completely-tester.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,6 @@ _mygit_completions() {
local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")
local compline="${compwords[*]}"

local original_comp_wordbreaks="$COMP_WORDBREAKS"
COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"

case "$compline" in
'status'*)
while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_mygit_completions_filter "--help --verbose --branch $(git branch 2>/dev/null)")" -- "$cur")
Expand All @@ -56,8 +53,6 @@ _mygit_completions() {
;;

esac

COMP_WORDBREAKS="$original_comp_wordbreaks"
} &&
complete -F _mygit_completions mygit

Expand Down
5 changes: 0 additions & 5 deletions spec/approvals/completions/function
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@ send_completions() {
echo $' local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")'
echo $' local compline="${compwords[*]}"'
echo $''
echo $' local original_comp_wordbreaks="$COMP_WORDBREAKS"'
echo $' COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"'
echo $''
echo $' case "$compline" in'
echo $' \'generate\'*)'
echo $' while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A directory -W "$(_completely_completions_filter "--help --force")" -- "$cur")'
Expand All @@ -45,8 +42,6 @@ send_completions() {
echo $' ;;'
echo $''
echo $' esac'
echo $''
echo $' COMP_WORDBREAKS="$original_comp_wordbreaks"'
echo $'} &&'
echo $' complete -F _completely_completions completely'
echo $''
Expand Down
5 changes: 0 additions & 5 deletions spec/approvals/completions/script
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ _completely_completions() {
local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")
local compline="${compwords[*]}"

local original_comp_wordbreaks="$COMP_WORDBREAKS"
COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"

case "$compline" in
'generate'*)
while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A directory -W "$(_completely_completions_filter "--help --force")" -- "$cur")
Expand All @@ -44,8 +41,6 @@ _completely_completions() {
;;

esac

COMP_WORDBREAKS="$original_comp_wordbreaks"
} &&
complete -F _completely_completions completely

Expand Down
5 changes: 0 additions & 5 deletions spec/approvals/completions/script-only-spaces
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ _completely_completions() {
local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")
local compline="${compwords[*]}"

local original_comp_wordbreaks="$COMP_WORDBREAKS"
COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"

case "$compline" in
'generate'*)
while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -A directory -W "$(_completely_completions_filter "--help --force")" -- "$cur")
Expand All @@ -40,8 +37,6 @@ _completely_completions() {
;;

esac

COMP_WORDBREAKS="$original_comp_wordbreaks"
} &&
complete -F _completely_completions completely

Expand Down
3 changes: 0 additions & 3 deletions spec/approvals/completions/script-with-debug
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ _completely_completions() {
local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")
local compline="${compwords[*]}"

local original_comp_wordbreaks="$COMP_WORDBREAKS"
COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"

if [[ -n "$COMPLETELY_DEBUG" ]]; then
echo "compline: '$compline'" > 'completely-debug.txt'
echo "cur: '$cur'" >> 'completely-debug.txt'
Expand Down
5 changes: 0 additions & 5 deletions spec/fixtures/tester/default.bash
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ _cli_completions() {
local compwords=("${COMP_WORDS[@]:1:$COMP_CWORD-1}")
local compline="${compwords[*]}"

local original_comp_wordbreaks="$COMP_WORDBREAKS"
COMP_WORDBREAKS="${COMP_WORDBREAKS//[:=]/}"

case "$compline" in
'command childcommand'*)
while read -r; do COMPREPLY+=("$REPLY"); done < <(compgen -W "$(_cli_completions_filter "--quiet --verbose -q -v")" -- "$cur")
Expand All @@ -48,8 +45,6 @@ _cli_completions() {
;;

esac

COMP_WORDBREAKS="$original_comp_wordbreaks"
} &&
complete -F _cli_completions cli

Expand Down