Skip to content
Yuri Pereira Constante edited this page Feb 1, 2022 · 9 revisions

Bash conditions manual

http://tldp.org/LDP/Bash-Beginners-Guide/html/sect_07_01.html

Git

Create ssh key

  • ssh-keygen -t ed25519
  • xclip -selection clipboard -in <file>.pub
  • Add key to git host
  • Test with ssh -T git@<git-host>

Pull branch without checkout

git fetch && git update-ref refs/heads/<branch> refs/remotes/origin/<branch>

Watch changes

Watch for dconf changes

dconf watch /

Watch file changes

inotifywait -e modify -e close_write -e move -e create -e delete -m -r <path>

Watch files changes and access

inotifywait -m -r <path>

XDG spec

ZSH keybinding functions

List of the default functions available to use for keybinding http://zsh.sourceforge.net/Doc/Release/Editor-Functions-Index.html

.desktop file not working

Check if the file is valid: desktop-file-validate <path>.

Read the execution output: awk -F= '/Exec=/{system($2)}' <path>

Find what is slowing down boot

set FILE (mktemp); systemd-analyze plot > "$FILE"; firefox "$FILE"

systemd-analyze critical-chain
systemd-analyze blame

Fish

Makefile shortcut

alias something="make --directory DIR_PATH "

Gnome Boxes

Enable shared folders

On guest, run command sudo dnf --refresh install spice-webdavd spice-vdagent, and restart guest

Access shared folder in files

Access path dav://localhost:9843

Access shared folder in terminal

cd /run/user/$UID/gvfs/dav:host=localhost,port=9843,ssl=false/

Podman

Fix permission error on volume: chcon -R -t svirt_sandbox_file_t <PATH>