-
Notifications
You must be signed in to change notification settings - Fork 123
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add Terraform item * Do not show default workspace in Terraform prompt * Add terraform to tide_right_prompt_items * Add terraform to _tide_remove_unusable_items * Fix test, use read, format Co-authored-by: Ilan Cosman <[email protected]>
- Loading branch information
1 parent
03bffd9
commit 3787c72
Showing
9 changed files
with
44 additions
and
4 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
function _tide_item_terraform | ||
if test -d .terraform | ||
terraform workspace show | read -l workspace | ||
test $workspace != default && _tide_print_item terraform $tide_terraform_icon' ' $workspace | ||
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
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,19 @@ | ||
# RUN: %fish %s | ||
|
||
function _terraform | ||
_tide_decolor (_tide_item_terraform) | ||
end | ||
|
||
set -l terraformDir (mktemp -d) | ||
cd $terraformDir | ||
|
||
mock terraform "workspace show" "echo default" | ||
_terraform # CHECK: | ||
|
||
mkdir .terraform | ||
_terraform # CHECK: | ||
|
||
mock terraform "workspace show" "echo test" | ||
_terraform # CHECK: test | ||
|
||
rm -r $terraformDir |