I recommend cloning this repository into ~/dotfiles
so the wallpaper image and the install guide work without any adjustment.
git clone git@github.com:Florian-Merle/dotfiles.git ~/dotfiles
sudo apt install zsh
sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
ln -s ~/dotfiles/.zshrc ~/.zshrc
ln -s ~/dotfiles/.oh-my-zsh/themes/agnoster-custom.zsh-theme ~/.oh-my-zsh/themes/agnoster-custom.zsh-theme
Used to search files more efficiently in Neovim and do so fuzzy finding magic 🪄
sudo apt-get install fzf
Used to forward stuff in the clipboard
sudo apt-get install xsel
Basically cat with syntax sighlighting.
sudo apt install bat
Used to have fancy git diffs.
In order to always have syntax highlight for PHP (even chunks without an opening php tag <?php
) the following workaround should be applied.
Also, make sure both bat and delta versions are compatible (mainly because from what I understand, delta reads bat cache, but bat cache structure can evolve). I found that bat v0.19.0 (the version I currently have installed) works with delta v0.12.1.
To sum up, you can download delta from its repository, then build bat cache and finally create a symlink for the ~/.config/bat/syntaxes/PHP.sublime-syntax
file.
wget https://github.com/dandavison/delta/releases/download/0.12.1/git-delta_0.12.1_amd64.deb
dpkg -i git-delta_0.12.1_amd64.deb
rm git-delta_0.12.1_amd64.deb
bat cache --build
ln -s ~/dotfiles/bat/syntaxes/PHP.sublime-syntax ~/.config/bat/syntaxes/PHP.sublime-syntax
# phpactor binary
cd ~/.local/share
git clone git@github.com:phpactor/phpactor.git
composer i
cd /usr/local/bin
ln -s ~/.local/share/phpactor/bin/phpactor phpactor
# phpactor configuration
ln -sf ~/dotfiles/phpactor ~/.config/phpactor
Lsp logs
tail /home/florian/.local/state/nvim/lsp.log
## Psalm
Just like phpactor, psalm can be used as a lsp.
```sh
composer global require vimeo/psalm:5.0.0-beta1
sudo ln -s ~/.config/composer/vendor/bin/psalm /usr/local/bin/psalm
# Create profile
dconf dump /org/gnome/terminal/legacy/profiles:/ > gnome-terminal-profiles.dconf
# Install profile
dconf load /org/gnome/terminal/legacy/profiles:/ < gnome-terminal-profiles.dconf
See https://unix.stackexchange.com/a/456356
Note that the color theme I use are downloaded with Gogh
Global configuration
ln -s ~/dotfiles/regolith2/Xresources ~/.config/regolith2/Xresources
ln -s ~/dotfiles/regolith2/i3/config.d ~/.config/regolith2/i3/
ln -s ~/dotfiles/regolith2/i3xrocks/conf.d ~/.config/regolith2/i3xrocks/
Clone https://github.com/catppuccin/regolith
Then
# Install the regolith look
./install.sh
sudo python3 /usr/share/regolith-look/catppuccin/theme-switcher.py latte sky
# Install GTK flavored catppuccin
cd gtk && ./install.sh
Then using Gnome Tweaks, you can set the theme to Catppuccin Latte.
Status bar configuration
$ ls -l /usr/share/i3xrocks/conf.d
01_setup
70_rofication
80_time
90_battery
# Disable network notifications
gsettings set org.gnome.nm-applet disable-disconnected-notifications "true"
gsettings set org.gnome.nm-applet disable-connected-notifications "true"
On my X1 carbon, I like to remap the print screen key to the context menu. This can be done following this guide.
# /usr/share/X11/xkb/keycodes/evdev
default xkb_keycodes "evdev" {
// ...
// Custom
alias <MENU> = <PRSC>;
};
I also like to invert the function and the ctrl keys, this can easily be done in the BIOS.
In order to achieve this, I used a tool called keyd.
Also, it by holding the caps lock key and hjkl, you can use the directionnal keys.
ln -s ~/dotfiles/keyd/default.conf /etc/keyd/default.conf
sudo systemctl enable keyd && sudo systemctl start keyd
sudo keyd reload
See https://www.youtube.com/watch?v=6UsmrviNjXM&ab_channel=ziontee113-Healthy-Director-702
The font I use is called CommitMono. I patched it with Nerd Fonts, see the repository Florian-Merle/CommitMono-FontPatcher and its script FontPatcher/commit.sh
.
Note, that I do not like ligatures, so the script disables them.
- Thanks to @dizzyup for his Wavēy wallpaper collection.
- New wallpaper misty_mountains taken from here.
- Wallpapers: https://github.com/dharmx/walls/blob/main/tile/topo-mono.png
- https://unsplash.com/fr/photos/QY5U8JD3-tk with tint filter applied (#1e66f5) using https://www12.lunapic.com/editor/
# Use key notation to know what does a key do in vim
:help key-notation
# Use to find an i3 key name see https://www.reddit.com/r/i3wm/comments/4e65g8/comment/d1xccjb/?utm_source=share&utm_medium=web2x&context=3
xev -event keyboard
In order to theme Spotify, I used Spicetify. For more info, see the following guide. Use the advanced installation guide in order to setup the correct permissions on Spotify files.
git clone https://github.com/morpheusthewhite/spicetify-themes.git
cd spicetify-themes
cp -r * ~/.config/spicetify/Themes
spicetify config current_theme "Ziro"
spicetify config color_scheme "green-light"
spicetify apply
In order to get rid of notifications, see the following guide.
When at home, I like to use an Apple Magic Trackpad, but unlike the laptop Trackpad, I prefer the middle click to be triggered with two finger instead of being aera based.
In order to achieve this, the following command can be run whenever the trackpad is plugged in.
XX
being the id of the trackpad (this can be found with xinput list
), YYY
being the number of the property and Z, Z, Z
being the value for the property (this can, be found with xinpuit list-props XX
).
xinput set-prop XX YYY Z, Z, Z
xinput set-prop 23 345 0, 1
To automatically run the script when the trackpad is connected, I used udev with systemd. Systemd ensure the script is run by the user (not root).
# install
mkdir -p ~/.config/systemd/user
ln -s ~/dotfiles/systemd/user/connect-trackpad.service ~/.config/systemd/user/connect-trackpad.service
systemctl --user enable connect-trackpad.service
systemctl --user daemon-reload
# testing
systemctl --user start connect-trackpad.service
# when changing the service, you can disable it and re-enable it to apply changes
systemctl --user disable connect-trackpad.service
systemctl --user enable connect-trackpad.service
# monitor the service
journalctl --user -fu connect-trackpad
Udev works with rules.
# install
sudo ln -s ~/dotfiles/scripts/90-connect-trackpad.rules /etc/udev/rules.d/90-connect-trackpad.rules
sudo udevadm control --reload
sudo udevadm trigger
To build the rule, use the following command to find the relevent udev event.
udevadm monitor --environment
Then using the DEVPATH
, use the following command to find attributes (please note, that the path is prefixed by /sys
). --attribute-walk
find every attributes from the device and its parents.
udevadm info --attribute-walk --path="/sys/devices/pci0000:00/0000:00:14.0/usb3/3-10/3-10:1.0/bluetooth/hci0/hci0:256" | less
Finally, to build the rule, I used both the idProduct and idVendor.
kovidgoyal/kitty#1101 (comment)
ln -s ~/dotfiles/kitty/kitty.conf ~/.config/kitty/kitty.conf
sudo ln -s ~/dotfiles/scripts/cdiscord.sh /usr/bin/cdiscord
sudo ln -s ~/dotfiles/scripts/cspotify.sh /usr/bin/cspotify
sudo ln -s ~/dotfiles/scripts/ctelegram.sh /usr/bin/ctelegram
sudo ln -s ~/dotfiles/applications/discord.desktop /usr/share/applications/cdiscord.desktop
sudo ln -s ~/dotfiles/applications/spotify.desktop /usr/share/applications/cspotify.desktop
sudo ln -s ~/dotfiles/applications/telegram.desktop /usr/share/applications/ctelegram.desktop
In order to use the trackpad via bluetooth, the trackpad, should be disconnect, then turned off and on again and it should be available in the list of bluetooth devices. See https://github.com/mwyborski/Linux-Magic-Trackpad-2-Driver
- Improve zsh conf
- Fix Alt+{hjkl} mappings in vim
- Make gx work for opening url in browser
- https://github.com/Orange-OpenSource/hurl
- Try https://github.com/rest-nvim/rest.nvim
- Try https://orgmode.org/guide/index.html
- remove terminal plugin from nvim
- play with a new compositor https://www.reddit.com/r/unixporn/comments/s5i6i3/oc_an_xorg_compositor_forked_from_xcompmgr_with/
- win + a to go to parent
- win + [ for stacked
- win + ] for tabbed
- win + ; for horizontal
- win + ' for vertical