forked from derailed/k9s
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add new plugin current-ctx-terminal (derailed#2795)
Co-authored-by: acobo <acobo@opensistemas.com>
- Loading branch information
Showing
1 changed file
with
16 additions
and
0 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,16 @@ | ||
plugins: | ||
open-terminal: | ||
shortCut: Ctrl-T | ||
confirm: false | ||
description: Open a terminal in the current context | ||
scopes: | ||
- all | ||
command: /usr/bin/sh | ||
background: false | ||
args: | ||
- -c | ||
- bash -c "kubectl config use-context $CONTEXT && echo -e \"\e[1;42mk9s bash terminal.\nCtrl + d or 'exit' to go back to k9s\e[0m\" && bash" | ||
# New window for terminal can be opened with any emulator | ||
#- x-terminal-emulator -e bash -c "kubectl config use-context $CONTEXT && echo -e \"\e[1;42mk9s bash terminal.\nCtrl + d or 'exit' to go back to k9s\e[0m\" && bash" | ||
# example with tilix: | ||
#- tilix -e bash -c "kubectl config use-context $CONTEXT && echo -e \"\e[1;42mk9s bash terminal.\nCtrl + d or 'exit' to go back to k9s\e[0m\" && bash" |