Skip to content

Commit d5f7552

Browse files
committed
rubocop
1 parent f8928cc commit d5f7552

5 files changed

Lines changed: 12 additions & 5 deletions

File tree

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,13 @@ mygit:
169169
The `2> /dev/null` is used so that if the command is executed in a directory
170170
without a git repository, it will still behave as expected.
171171

172+
### Completion scope and limitations
173+
174+
- Completion words are treated as whitespace-delimited tokens.
175+
- Literal completion phrases that contain spaces are not supported as a single completion item.
176+
- Quotes and other special shell characters in literal completion words are not escaped automatically.
177+
- Dynamic `$(...)` completion commands should output plain whitespace-delimited words.
178+
172179
### Suggesting flag arguments
173180

174181
Adding a `*` wildcard in the middle of a pattern can be useful for suggesting

spec/approvals/cli/install/dry

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
cp completely.bash /home/vagrant/.local/share/bash-completion/completions/completely-test
1+
cp completely.bash /home/USER/.local/share/bash-completion/completions/completely-test
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
cp <tmpfile-path> /home/vagrant/.local/share/bash-completion/completions/completely-test
1+
cp <tmpfile-path> /home/USER/.local/share/bash-completion/completions/completely-test

spec/completely/commands/install_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252

5353
expect { subject.execute %w[install completely-test --dry] }
5454
.to output_approval('cli/install/dry')
55-
.except(%r[/home/([^/]+)], '/home/USER')
55+
.except(%r{/home/([^/]+)}, '/home/USER')
5656
end
5757
end
5858

@@ -65,7 +65,7 @@
6565
expect { subject.execute %w[install completely-test - --dry] }
6666
.to output_approval('cli/install/stdin-dry')
6767
.except(/cp [^\s]*completely-[^\s]*/, 'cp <tmpfile-path>')
68-
.except(%r[/home/([^/]+)], '/home/USER')
68+
.except(%r{/home/([^/]+)}, '/home/USER')
6969
end
7070
end
7171

spec/completely/commands/uninstall_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939

4040
expect { subject.execute %w[uninstall completely-test --dry] }
4141
.to output_approval('cli/uninstall/dry')
42-
.except(%r[/home/([^/]+)], '/home/USER')
42+
.except(%r{/home/([^/]+)}, '/home/USER')
4343
.diff(20)
4444
end
4545
end

0 commit comments

Comments
 (0)