4 ms·
The extra configuration around setting up git to track $HOME is interesting. My setup is pretty lame compared to that: I just have a ~/.local/dotfiles/ git rep
by bloopernova 5y ago
The extra configuration around setting up git to track $HOME is interesting.
My setup is pretty lame compared to that: I just have a ~/.local/dotfiles/ git repo and symlink my various files from that repo.
The "git config status.showUntrackedFiles no" is a nice touch, I'll have to try that sometime.
NixOS home manager seems pretty cool, but that feels like a huge dependency. It also isn't available on my MacOS client work machine so sharing between multiple computers might be difficult (for me, at least)
I'll take this opportunity to shill my quick/rough setup guide for various tools like fzf, fd, ripgrep on zsh on MacOS. It's a gist, so I don't get any ad revenue: https://gist.github.com/aclarknexient/0ffcb98aa262c585c49d4b3f3ae24019 https://gist.github.com/aclarknexient/0ffcb98aa262c585c49d4b...
- maweki 5y agoIt seems like you could get value out of stow. It would manage the symlinking for you.
- bloopernova 5y agoI do keep meaning to look into that. Thankfully I'm not jumping onto new computers every day, so I haven't had to automate the setup of a new instance of my dotfiles repo.
- mschwaig 5y agoI guess you cannot install Nix on that Mac because you are not admin? In general you can install the Nix Package Manager and home-manager an macOS. There were some rough edges when macOS Catalina came out, but that should be resolved now. The way it works will probably require admin rights though (https://nixos.org/manual/nix/stable/installation/installing-binary.html#macos-installation-a-namesect-macos-installation-change-store-prefixaa-namesect-macos-installation-encrypted-volumeaa-namesect-macos-installation-symlinkaa-namesect-macos-installation-recommended-notesa https://nixos.org/manual/nix/stable/installation/installing-...).
- bloopernova 5y agoRight now the IT security dept requires that any software is approved by committee, repackaged and hosted internally. So it's a huge hurdle to overcome. It's just easier to use symlinks.
- eddieroger 5y agoInteresting setup - thank you for sharing. I've SSH'd in to hundreds machines between home and work, and never thought to check `$SSH_CONNECTION` to see if I was remotely connected or not and take actions on that fact. So clever to have a different prompt when remoting in or not. Your setup is more complicated than mine, and maybe even than what I want, but I'm excited to take some inspiration from it and maybe incorporate some of this to my setup.
- bloopernova 5y agoI really like to hear feedback like that! I'm really glad you found something useful in the guide. If you have any criticism or changes, please let me know.
- folkrav 5y agoI basically do the same but use `stow` and a `~/.dotfiles` repo. ~/.dotfiles/ fish/ .config/fish/... neovim/ .config/nvim/... link.sh link.sh #!/usr/bin/env bash ARGS=$@ DEFAULT_DIRS=$(echo */) DIRS_TO_STOW=${ARGS:=$DEFAULT_DIRS} for dir_name in $DIRS_TO_STOW; do echo "Linking $dir_name..." stow --restow --no-folding $dir_name done I then run `./link.sh` to re-create symlinks for everything or `./link.sh foo bar` to re-link some in particular.
- yjftsjthsd-h 5y ago> My setup is pretty lame compared to that: I just have a ~/.local/dotfiles/ git repo and symlink my various files from that repo. Same here; I did add a shell script to actually make the symlinks (the bulk of which is a single for loop because so many files go to ~/.$FILE), but a "real" tool to manage things always seemed like overkill. In fairness, that probably only works because my configs are mostly the same between machines.
- lloeki 5y agoGot a similar repo: https://github.com/lloeki/dotfiles https://github.com/lloeki/dotfiles A couple of differences though. - there's a setup script to do the basic symlinks, automatically from the files in the "home" subdir by prepending the names with . - then for shell stuff everything is sourced from either shell, bash, or zsh subdirs, all in modular files - shell dir content is autoloaded based on +x - there are polyfills for bash that makes it more zsh-like (stuff like precmd) - each shell module tests for tool presence and is a noop or sets up a fallback when the tool is not available, so I can clone this on any system and have it still work, gracefully degrading down to zero deps except the shell itself - it also attempts to provide a uniform experience across bash versions and OSes (darwin, linux) - prompt is minimal (workdir, dirname only, not the full path), increases with detail progressively and in a hierarchical order (root if root, host if ssh, workdir, vcs branch if in repo, vcs status as symbols if nonempty, venv name if virtualenv, "nix" if in nix shell)