mirror of
https://gitlab.com/sagidayan/linux-config.git
synced 2024-11-22 07:15:25 +00:00
Merge branch 'cleanups' into 'main'
Cleanups and tweaks See merge request sagidayan/linux-config!8
This commit is contained in:
commit
f41ce07bca
8 changed files with 40 additions and 59 deletions
|
@ -28,3 +28,4 @@ $ ./run_play.sh <playbook> # Defaults to workstation
|
||||||
### Playbooks
|
### Playbooks
|
||||||
- workstation
|
- workstation
|
||||||
- cli-tools
|
- cli-tools
|
||||||
|
- self-managed-unix-update (Updating all packages from the modern unix role)
|
||||||
|
|
|
@ -4,17 +4,16 @@
|
||||||
########################################################
|
########################################################
|
||||||
|
|
||||||
# Get docs fast
|
# Get docs fast
|
||||||
selected=`/bin/cat ~/.shellconfig/cheat/languages ~/.shellconfig/cheat/commands | fzf --header="Select a topic"`
|
selected=`cat ~/.shellconfig/cheat/topics | fzf --header="🏳️ Select a Topic: " --reverse`
|
||||||
if [[ -z $selected ]]; then
|
if [[ -z $selected ]]; then
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
read -p "Enter Query: " query
|
read -p "What you want to know?: " query
|
||||||
|
|
||||||
if grep -qs "$selected" ~/.shellconfig/cheat/languages; then
|
query=`echo $query | tr ' ' '+'`
|
||||||
query=`echo $query | tr ' ' '+'`
|
if [[ $selected == "TLDR" ]]; then
|
||||||
tmux neww bash -c "echo \"curl cht.sh/$selected/$query/\" & curl cht.sh/$selected/$query & while [ : ]; do sleep 1; done"
|
tmux neww -n "[🏳️ Cheat: ${selected}/${query}]" bash -c "tldr ${query} | bat --paging=always --file-name='${selected} | Query: ${query}'"
|
||||||
else
|
else
|
||||||
tmux neww bash -c "curl -s cht.sh/$selected~$query | less"
|
tmux neww -n "[🏳️ Cheat: ${selected}/${query}]" bash -c "curl -s https://cht.sh/$selected/$query | bat --paging=always --file-name='Topic: ${selected} | Query: ${query}'"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -1,35 +0,0 @@
|
||||||
find
|
|
||||||
fzf
|
|
||||||
man
|
|
||||||
tldr
|
|
||||||
sed
|
|
||||||
awk
|
|
||||||
tr
|
|
||||||
cp
|
|
||||||
ls
|
|
||||||
grep
|
|
||||||
xargs
|
|
||||||
ps
|
|
||||||
mv
|
|
||||||
kill
|
|
||||||
lsof
|
|
||||||
less
|
|
||||||
head
|
|
||||||
tail
|
|
||||||
tar
|
|
||||||
rm
|
|
||||||
jq
|
|
||||||
cat
|
|
||||||
ssh
|
|
||||||
cargo
|
|
||||||
git
|
|
||||||
podman
|
|
||||||
docker
|
|
||||||
docker-compose
|
|
||||||
chmod
|
|
||||||
chown
|
|
||||||
make
|
|
||||||
kubectl
|
|
||||||
oc
|
|
||||||
ocp
|
|
||||||
systemctl
|
|
|
@ -1,15 +1,25 @@
|
||||||
|
TLDR
|
||||||
golang
|
golang
|
||||||
nodejs
|
ansible
|
||||||
yaml
|
yaml
|
||||||
|
python
|
||||||
|
bash
|
||||||
|
typescript
|
||||||
|
nodejs
|
||||||
javascript
|
javascript
|
||||||
tmux
|
tmux
|
||||||
typescript
|
|
||||||
zsh
|
zsh
|
||||||
cpp
|
cpp
|
||||||
c
|
c
|
||||||
rust
|
rust
|
||||||
python
|
|
||||||
bash
|
|
||||||
css
|
css
|
||||||
markdown
|
markdown
|
||||||
ansible
|
linux
|
||||||
|
systemd
|
||||||
|
jq
|
||||||
|
kubectl
|
||||||
|
oc
|
||||||
|
grep
|
||||||
|
sed
|
||||||
|
awk
|
||||||
|
tr
|
|
@ -71,7 +71,19 @@ function ide() {
|
||||||
|
|
||||||
pre_check_tmux_for_layout "ide" || return 1
|
pre_check_tmux_for_layout "ide" || return 1
|
||||||
|
|
||||||
tmux send-keys "l" C-m
|
echo "=-=-=-=-=-=-=-=-=-=-=-=-=-="; \
|
||||||
|
echo "${IDE_NAME}"; \
|
||||||
|
echo "=-=-=-=-=-=-=-=-=-=-=-=-=-="; \
|
||||||
|
echo;echo Status:; \
|
||||||
|
echo -=-=-=-; \
|
||||||
|
git status; \
|
||||||
|
echo; \
|
||||||
|
echo Remotes:; \
|
||||||
|
echo -=-=-=-=; \
|
||||||
|
git remote -v | cat; \
|
||||||
|
echo;echo Files:; \
|
||||||
|
echo -=-=-=; \
|
||||||
|
ls -l
|
||||||
tmux split-window -h -p 80
|
tmux split-window -h -p 80
|
||||||
tmux split-window -h -p 30
|
tmux split-window -h -p 30
|
||||||
tmux send-keys "gitui" C-m
|
tmux send-keys "gitui" C-m
|
||||||
|
|
|
@ -25,7 +25,7 @@ bind-key - split-window -v -c "#{pane_current_path}"
|
||||||
# close window with <prefix-q>
|
# close window with <prefix-q>
|
||||||
bind-key q kill-window
|
bind-key q kill-window
|
||||||
# refresh window with <prefix-e>
|
# refresh window with <prefix-e>
|
||||||
bind-key e respawn-window -k
|
bind-key e respawn-window -k -c "#{pane_current_path}"
|
||||||
|
|
||||||
# <prefix>-j/k for up down (useful to move between history commands)
|
# <prefix>-j/k for up down (useful to move between history commands)
|
||||||
bind-key k send-keys Up
|
bind-key k send-keys Up
|
||||||
|
|
|
@ -108,16 +108,10 @@
|
||||||
dest: ~/.shellconfig/environment.sh
|
dest: ~/.shellconfig/environment.sh
|
||||||
force: no
|
force: no
|
||||||
|
|
||||||
- name: Copy languages cheat sheet list
|
- name: Copy topics cheat sheet list
|
||||||
copy:
|
copy:
|
||||||
src: dotfiles/shellconfig/cheat/languages
|
src: dotfiles/shellconfig/cheat/topics
|
||||||
dest: ~/.shellconfig/cheat/languages
|
dest: ~/.shellconfig/cheat/topics
|
||||||
force: yes
|
|
||||||
|
|
||||||
- name: Copy commands cheat sheet list
|
|
||||||
copy:
|
|
||||||
src: dotfiles/shellconfig/cheat/commands
|
|
||||||
dest: ~/.shellconfig/cheat/commands
|
|
||||||
force: yes
|
force: yes
|
||||||
|
|
||||||
- name: Install modern UNIX tools
|
- name: Install modern UNIX tools
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
name: btm
|
name: btm
|
||||||
repo: ClementTsang/bottom
|
repo: ClementTsang/bottom
|
||||||
bin_path: "/btm"
|
bin_path: "/btm"
|
||||||
autocomplete_path: "/completion/btm.bash"
|
#autocomplete_path: "/completion/btm.bash"
|
||||||
filter: bottom_x86_64-unknown-linux-gnu.tar.gz
|
filter: bottom_x86_64-unknown-linux-gnu.tar.gz
|
||||||
|
|
||||||
- name: Installing gitui
|
- name: Installing gitui
|
||||||
|
|
Loading…
Reference in a new issue