Linux Guru

Cheatsheet tmux

Tmux Command line Cheatsheets tmux new -s {session_name} -n {name} - create new session and specify window name tmux {attach|a|at} -t {session_name} - attach to session tmux ls - list sessions tmux kill-session -t {session_name} - kill session Tmux Misc Prefix ? - help Prefix d - detach Prefix t - big clock Tmux Command mode Prefix : - command mode new-window -n {name} {command} - create new window and execute command Tmuix Sessions :new - new session Prefix s - list sessions Prefix $ - name session Prefix ( - previous session Prefix ) - next session Prefix L - last session Tmux Windows Prefix c - create new window Prefix , - rename window Prefix n - next window Prefix p - previous window Prefix {n} - go to window n Prefix f - find window by name Prefix w - list windows Prefix & - kill window Tmux Panes Prefix % split panes by vertical Prefix " split panes by horizontal Prefix o - cycle through the panes Prefix {arrow key} - navigate to specific pane Prefix space - cycle thought layouts Prefix x - close pane Prefix q - show panes numbers Prefix z - switch to whole window mode and back Prefix { - move the current pane left Prefix } - move the current pane right :setw synchronize-panes - toggle panes synchronization Tmux Copy mode (vi mode) Prefix [ - start copy mode Prefix ] - past from copy mode ^ - back to indentation esc - clear selection enter - copy selection j - cursor down h - cursor left l - cursor right k - cursor down L - cursor to bottom line M - cursor to middle line H - cursor to top line d - delete entire line D - delete to end of line $ - end of line : - goto line ⌃-d - half page down ⌃-u - half page up ⌃-f - next page w - next word p - paste buffer ⌃-b - previous page b - previous word q - quit mode ⌃-down, ⌃-j - scroll down ⌃-up, ⌃-k - scroll up n - next search match ?

Continue reading

Unix Sed Tutorial: Advanced Sed Substitution Examples

Sed Substitution Delimiter As we discussed in our previous post, we can use the different delimiters such as @ % | ; : in sed substitute command. Let us first create path.txt file that will be used in all the Beispielen mentioned below. cat path.txt /usr/kbos/bin:/usr/local/bin:/usr/jbin:/usr/bin:/usr/sas/bin /usr/local/sbin:/sbin:/bin/:/usr/sbin:/usr/bin:/opt/omni/bin: /opt/omni/lbin:/opt/omni/sbin:/root/bin  Beispiel 1 sed @ delimiter: Substitute /opt/omni/lbin to /opt/tools/bin When you substitute a path name which has ‘/’, you can use @ as a delimiter instead of ‘/’.

Continue reading

Useful Basic Commands of APT-GET and APT-CACHE for Package Management

Useful Basic Commands of APT-GET and APT-CACHE for Package Management Excerpt This article explains how quickly you can learn to install, remove, update and search software packages using apt-get and apt-cache commands from the command line. This article explains how quickly you can learn to install, remove, update and search software packages using apt-get and apt-cache commands from the command line. This article provides some useful commands that will help you to handle package management in Kali-Linux or Debian/Ubuntu based systems.

Continue reading