Introduction
I’ve spent long hours studying and refreshing my knowledge of linux in the past months so I feel I need to lighten up the atmosphere a bit and turn down the technical complexity. This article focuses on productivity with linux by going over my configuration and the tools I use to speed up my daily tasks.
1. Command line: Zsh
I’ve added fuzzy history finder fzf
to my .zshrc
so that I can find a previous command quickly.
zsh (ohmyzsh package) also has tons of plugins for autocompletion. Some popular ones i’m using:
- git
- dnf
- zsh-autosuggestions
- zsh-syntax-highlighting
but there are of hundreds available. Look at your favorite tool like kubectl
and see if it has a corresponding zsh plugin.
2. Vscode
I mostly use my text editor for web development, scripting and writing markdown. Vscode and its shortcuts for easy text manipulation and editing is the ideal tool for me right now. I know that neovim is a big contender in this space but i’m not ready to dig that rabbithole just yet. Nor do I need to.
I have some custom bindings to override the custom vscode key binds. You can save this json in any vscode project under .vscode/keybindings.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
[
{
"key": "alt+right",
"command": "workbench.action.navigateForward"
},
{
"key": "alt+left",
"command": "workbench.action.navigateBack"
},
{
"key": "ctrl+shift+down",
"command": "-editor.action.copyLinesDownAction",
"when": "editorTextFocus && !editorReadonly"
},
{
"key": "ctrl+k",
"command": "editor.action.deleteLines",
"when": "textInputFocus && !editorReadonly"
},
{
"key": "ctrl+shift+k",
"command": "-editor.action.deleteLines",
"when": "textInputFocus && !editorReadonly"
}
]
Add breakpoints to your python code in vscode with this json configuration file. There are some good ones you can use for django as well. You can save this json in any vscode project under .vscode/launch.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Brevo",
"type": "debugpy",
"request": "launch",
"program": "${file}",
"python": "${workspaceFolder}/brevo/env/bin/python",
"console": "integratedTerminal"
},
{
"name": "supersecretproject",
"type": "debugpy",
"request": "launch",
"program": "${file}",
"python": "${workspaceFolder}/Scripting/python/supersecretproject/env/bin/python",
"console": "integratedTerminal"
}
]
}
3. Window manager
X11 is not officially discontinued but it is being phased out in favor of Wayland. So I naturally gravitated towards Wayland and hyprland for my desktop/window manager
4. Clipboard history
I use a small bash script that calls the cliphist list
command and the rofi menu to display them as a pop up
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#!/bin/bash
# /* ---- 💫 https://github.com/JaKooLit 💫 ---- */ ##
# Clipboard Manager. This script uses cliphist, rofi, and wl-copy.
# Variables
rofi_theme="$HOME/.config/rofi/config-clipboard.rasi"
msg='👀 **note** CTRL DEL = cliphist del (entry) or ALT DEL - cliphist wipe (all)'
# Actions:
# CTRL Del to delete an entry
# ALT Del to wipe clipboard contents
# Check if rofi is already running
if pidof rofi > /dev/null; then
pkill rofi
fi
while true; do
result=$(
rofi -i -dmenu \
-kb-custom-1 "Control-Delete" \
-kb-custom-2 "Alt-Delete" \
-config $rofi_theme < <(cliphist list) \
-mesg "$msg"
)
case "$?" in
1)
exit
;;
0)
case "$result" in
"")
continue
;;
*)
cliphist decode <<<"$result" | wl-copy
exit
;;
esac
;;
10)
cliphist delete <<<"$result"
;;
11)
cliphist wipe
;;
esac
done
5. Thunderbird
Simply installing the desktop and mobile versions of the app brought me significant improvements to my calendar, email and contacts syncronization. Make sure you’re using imaps so that once you read an email on one device marks them as read on all other devices. I haven’t found a way to sync calendar and contacts on mobile because thunderbird does not support ir for now but it’s not a “nice to have” feature so I guess I’ll just do without it.
6. Swaync
Having a notification center that allows you to control your music paired with a keyboard with media controls is an absolute must for me. You can also allow certain web applications that have PWA capabilities to send notifications to that pannel. Everything is handled for you by the browser so if these concepts seem foreign to you don’t worry. Everything is already handled by your internet browser.
7. Tmux: sharing terminals with co-workers
Tmux is an absolute must have. You can also use it to keep background tasks running as I often forget about them and accidentally close the windows. If for instance you need to give root access to a coworker who does not have those permissions you can temporarily open a shell for him on a jump server.
It’s also extremely useful for coworkers to show something on the terminal without having to start a screen share over teams, slack or zoom.