Welcome to my dotfiles đź‘‹! I use dotbot to manage the files.
I'd discourage just forking this repo, because lots of things here are specific to my workflow. Don't shoot yourself in the foot! Feel free to copy what you like though.
config/espanso/default.yml- text expansions for espansoconfig/home-manager/- my home-manager config (I am slowly trying to move more and more of my package-management and other config into home-manager)/nix- contains files that are managed by home-managerconfig/regolith- configuration for regolith ≅ Ubuntu + i3nvim- neovim configuration and pluginsgitconfig- git configuration
My Doom-Emacs files are in a separate repo.
Xcompose- Compose key file for the German neo keyboard layouttrydactylrc- tridactyl configuration for Vim navigation in Firefox
In case we want to push stuff to GitHub:
sudo apt update
sudo apt install git python3 curl neovim Install nix with:
curl --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix | sh -s -- install # See https://github.com/DeterminateSystems/nix-installerInstall the repo:
git clone --depth 1 --recurse-submodules -j8 git@github.com:sonofhypnos/dotfiles.git ~/.dotfilesThen run ./install.sh (make sure you have emacs and neovim installed).
./install.sh will also ask you if you want to recompile your home-manager config.
Put the following at the top of the bashrc (if you are using the local one):
if [[ $TERM = "tramp" ]]; then
unset RPROMPT
unset RPS1
PS1="$ "
unsetopt zle
unsetopt rcs # Inhibit loading of further config files
return
fiMake sure you have more swap disk space than RAM, so you can use the swap partition for sleep with disk. (If you forget this, it's fine you can make a swap file)
Get UUID:
blkid | grep swapAdd swap to grub:
sudo vim /etc/default/grubAppend resume= at the end of already existing "quiet splash" or similar:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash
resume=UUID=2763225c-d330-4d26-82a3-76ef82dfc3f0"Regenerate grub config: On Debian/Ubuntu/Mint:
sudo update-grupbRegenerate initramfs (on Debian/Ubuntu/Mint) (this is needed to make sure the resume hook is in the initramfs (an os thingy in your RAM loaded at boot time)):
sudo update-initramfs -urestart. Afterwards, sudo systemctl hibernate, should work.
sudo apt update
sudo apt install git python3 curl neovim Install nix with:
curl --proto '=https' --tlsv1.2 -sSf -L https://install.determinate.systems/nix | sh -s -- install # See https://github.com/DeterminateSystems/nix-installerSystem-wide (didn't work on ubuntu last time I tried):
sudo localectl --no-convert set-x11-keymap de pc105 neo_qwertzEnable with (if it doesn't work go to next step):
setxkbmap de neo_qwertzEnable neo keyboard with GNOME (not required on ubuntu last time I checked):
gsettings set org.gnome.desktop.input-sources show-all-sources trueDownload your dotfiles:
git clone --depth 1 --recurse-submodules -j8 git@github.com:sonofhypnos/dotfiles.git ~/.dotfilesnix-shell -p home-manager
cd ~/.dotfiles/config/home-manager/
home-manager switch -b backup --flake .#tassiloAfter running the above we want to add home-manager independent of home-manager:
nix profile add home-managerfinally we run the dotfiles install script:
cd ~/.dotfiles
./install- Check the latest way of installing regolith here
Remove the keybindings config from regolith (since you configure it manually):
Add your favorite look:
sudo apt install regolith-look-*The above doesn't literally work sadly:
sudo apt install regolith-look-blackhole sudo snap install steam
sudo snap install aws-cli --classic #Amazon website mentions snap version is maintained, so up to date.
Important applications to install via apt:
sudo apt install npm
sudo apt install pulseaudio-utils # Useful for audio via commandline
sudo apt install kazam #Not working via nix
# Needed for copilot with emacsDownload the latest Chrome version and run:
sudo apt install ./google-chrome-stable_current_amd64.deb
sudo apt install ./code_1.101.1-1750254731_amd64.deb
Same for 1password and run (you cannot install 1password via snap since it will be sandboxed and can't do everything you want):
sudo apt install ./1password-latest.deb -
go to 1password and enable developer setings
-
disable default keybinds in 1password, because they conflict with Ctrl+a on neoqwertz layout
-
Download the most recent version of anki (don't try APT (too old), nix or snap (too sandboxed)) and install it manually.
Fixes Nix apps (dropbox, signal, chrome) getting bwrap: Permission denied:
echo 'kernel.apparmor_restrict_unprivileged_userns = 0' | sudo tee /etc/sysctl.d/20-apparmor-donotrestrict.conf
sudo sysctl --systemTest the fix:
unshare --user --map-root-user echo "success"Set .dotfiles/bin/pdf.sh as the default application for PDFs.
Also enable org-protocol (refer to your notes for how to setup or debug org-protocol).
Install Dropbox by downloading the latest .deb file and use apt install ./dropbox-file.deb to install it.
Run Dropbox once on the command line with:
dropbox start -iIt will ask you to connect Dropbox with this laptop by opening a URL for login.
- Fix my entire backup setup (In my new setup, I will only backup user-owned things.)
- First you need to manually install two addons below. Download their files (use wget, since Firefox will try to install them by default) and then go to "Tools > Plugins" in Zotero to install them.
- The Better BibTeX addon. Zotero will otherwise think something is wrong if you try to export things in the Better BibTeX format. Download the latest version from the release from the GitHub repository
- This addon for duplicates if you want to handle them: https://github.com/ChenglongMa/zoplicate/releases/tag/3.0.8
- Make sure that the versions of the addons are compatible with your Zotero version.
- Configure auto-export for your Zotero library entries. Go to "File > Export Library...". Check the box for "Keep updated". This option will not exist if you have not added the Better BibTeX addon! We are currently storing them under
~/repos/bibliography/My Library.bib. You have to manually set the auto-export folder.
So far, we always backed up all our files including files under / like /var/. Turns out our backup is getting really complicated though, because doing it like this requires us to run our backup as root, which messes with us being able to get prompted through a GUI by our backup. I could write a nicer backup that takes care of this. What seems like a more pleasant solution is to decide that everything under root will have to be configured manually, and while the idea of having logs of what happened after my laptop crashes is pleasant, who in practice is going to investigate this for my desktop laptop anyway. I don't have the time for that either.
This also makes another thing more uncomplicated. I think it probably makes a lot of sense to separate out our home directory to be on a different disk than the root directory. Last time I put ~/repos on a separate disk, because it was so large, but that was then inconvenient when we were jumping out of repos in Emacs.
Set GNOME's dark theme preference explicitly:
gsettings set org.gnome.desktop.interface gtk-theme 'Yaru-dark'
gsettings set org.gnome.desktop.interface color-scheme 'prefer-dark'We enable:
16 = 0x10 - enable sync command (s)
32 = 0x20 - enable remount read-only (u)
64 = 0x40 - enable signalling of processes (term, kill, oom-kill) (f)
128 = 0x80 - allow reboot/poweroff (b)
Check if /etc/sysctl.d/99-sysrq.conf exists.
Check the current value of the commands via:
cat /proc/sys/kernel/sysrqs, u, b is probably enabled, so the value is 176 on Ubuntu. If the value is something else, perhaps you have other keys enabled and you would want to change the command below.
echo 'kernel.sysrq = 240' | sudo tee /etc/sysctl.d/99-sysrq.conf
sudo sysctl -pTest if killing memory is working via:
python3 -c "x=[0]*10**8; input('Press Enter to exit or Ctrl+C to kill: ')"- Forget the things below on setting up your backup for root! We are going to only backup things owned by the user in the future. Fewer problems with permissions. We just manually edit the configuration for root and document it well.
- You will have to remove the
~/.config/systemddirectory created by home-manager once, so that we can first write the files from dotbot there, before we proceed to add the ones from home-manager.
To check when your timers are running next, you can run:
systemctl --user list-timersfor your user-level timers.
NOTE: We are trying without fingerprint for a while now, because we suspect it is the culprit that broke login with chrome not working anymore (chrome needs access to the keyring to decrypt its profile and so it looses things if we loose the keyring (or so the theory). I think it is easier to just not use the fingerprint feature probably.)
sudo apt update
sudo apt install fprintd libpam-fprintdScan your fingerprint (NOTE: it is important that we add our user here, otherwise the fingerprint will be used for root, but that is not the correct fingerprint if you want to log into root, which requires the fingerprint from a user with root access):
sudo fprintd-enroll tassiloAfter add
sudo pam-auth-updateAnd select fingerprint from the menu
Your org-roam notes are backed up with github. We do not use git-dropbox anymore, since it is confusing to set up and it is slower than regular git. We thought it might be a good idea to use to allow us to store more data (like images), but it doesn't actually work well for that purpose. If we have too much data, downloading your repository becomes so slow as to be impossible. Instead, we just store images outside of our notes, which makes way more sense in the first place. Clone your repository:
git clone git@github.com:sonofhypnos/org-roam.git org-roam(Possibly because they need root access)
sudo apt install logwatchYou might have to install anki addons again. Anki addons you usually like to use: Image Occlusion Enhanced Review Heatmap Flexible Cloze 2 Batch Note editing Search and replace tags
(use Flexible Cloze 2 min note type)
Compile your config (last time you compiled your config on 30.2 it took just 2 minutes). Install further dependencies inside doom (depends on node 20+ which you can install with nix):
Run:
M-x: copilot-install-server
So far we don't have a proper solution to secrets.
To use trashcli in root, use:
sudo mkdir /.Trash-1001
sudo chown $(whoami):$(whoami) /.Trash-1001(Trash-cli needs there to be a trash directory)
On the ThinkPad T460, the magic key just requires you to press Fn. Just Fn+F is going to kill the application with the most memory etc.
More documentation on the magic key bitmap.
If lock on your backup and there aren't two processes currently accessing at the same time:
borg break-lock borgbase:./repo- we could change our bios such that we power on our device at midnight and then allow our backup to run.
- Add secrets for backup
- Add secrets for SSH (check which ones you want on desktop or other machines etc.)
- Note: there is a problem, because we need the home-manager setup thing, but to get that zshrc and bashrc need to be set up if we want to add things under
~/binto the path, but this is done by home-manager:- Insight: we do not need to properly install home-manager: we can use
nix-shell -p home-managerand then install home-manager with home-manager! (This worked for me on a new install flawlessly)
- Insight: we do not need to properly install home-manager: we can use
- Fix your version control setup with Dropbox? Using a remote to backup your stuff doesn't work, because your repository is too big. Probably the easiest solution is to just give up on having a remote and to just use ... instead.
- Find a fix for the fact that home-manager wants to sandbox my applications when I do not want that
- Try bash with starship, fzf and bash-completion and see if you can get rid of zsh as something you need to install extra.
- Remove or fix the script where we are automatically trying to install home-manager and nix. They don't work in their current form, because they already expect scripts we added to our
/binto be in the path. - Create better action logging tools/lifelogging tools for LLMs to process:
- Archive URLs with all of the text I read
- Enable eye-tracking and use that to extract what text on a page I am reading
- Make sure that things are still working without needing to install home-manager? (Or do we want that?)
- Make sure install does not do weird things when we haven't installed Emacs
- By now I know instead of copying and modifying things under
/etc/share/regolith/conf.d/I can just overwrite them in~/config/regolith2/Xresources. That is what theset_from_xresourcekeybinds are for. Undoing that would be nice to do before or after we move to regolith 3.0 - Same for neovim (for committing with git for example)
- Move all dotbot stuff that I only need for my home to nix already (optional)
- Create a bootstrap script to install nix and setup home-manager (for now I gave up on this, because nix doesn't like to work with root as docker does.)
- Create better paths for shell (use
$HOMEinstead of/home/tassilo) - Move more configuration to home-manager and make it declarative.