-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
can hide short flags via config file
- Loading branch information
Showing
10 changed files
with
95 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
Feature: Do not display short flags (-p) within lists of completions options | ||
In order to reduce cost of scanning through lists of completion options | ||
As a tabtab user | ||
I want to be able to disable short flags and never see them | ||
|
||
Scenario: Explicitly disable short flags via the config file for definitions | ||
Given a .tabtab.yml config file | ||
And a file 'my_definitions.rb' containing completion definitions | ||
And disable short flags | ||
When run local executable 'tabtab' with arguments '--file my_definitions.rb test_app "" test_app' | ||
Then I should not see any short form flags | ||
|
||
Scenario: Explicitly disable short flags via the config file for externals | ||
Given a .tabtab.yml config file | ||
And disable short flags | ||
And env variable $PATH includes fixture executables folder | ||
When run local executable 'tabtab' with arguments '--external test_app "" test_app' | ||
Then I should not see any short form flags | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
Given /^disable short flags$/ do | ||
in_home_folder do | ||
config = YAML.load(File.read('.tabtab.yml')) | ||
config['shortflags'] = 'disable' | ||
File.open('.tabtab.yml', 'w') do |f| | ||
f << config.to_yaml | ||
end | ||
end | ||
end | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters