Closed yndajas closed 2 years ago
I suggest we configure iTerm via its config file (eg https://github.com/erbridge/dotfiles/blob/main/iterm/com.googlecode.iterm2.plist - I have a lot of settings in there, but twe could do a minimal version of that) and wrap it with a question about overwriting existing config like we do for the
.zshrc
. If they say "no" we could then link them to the instructions to do it themselves once they switch over. What do you think?
This sounds good. Some research suggested there might be some permissions issues with writing/overwriting files in ~/Library/Preferences
, but in testing it seems to write new files okay at least. I wonder if there's an easy way to get a default plist without reinstalling 🤔
Also, any thoughts on ligatures? I've got them enabled for now, but it does create a bit of a visual abstraction from the individual characters you type
I think no ligatures by default. If you're not expecting them to be there, it can be pretty confusing.
@erbridge I've addressed the line-specific comments you had, added a step to set up the iTerm2 plist (tested and working on my local) and updated the commit message
Changes in this PR
The Brewfile includes the prompt Starship, but it doesn't install a Nerd Font, which is a prerequisite
@see https://starship.rs/guide/#%F0%9F%9A%80-installation
This adds a Homebrew font manager via tap, then a Nerd Font via cask (Fira Code, which supports ligatures)
After the Homebrew bundle installation is complete, if the install script is being run in Terminal, it will set the app's default profile ("Basic") to the installed Nerd Font. It won't change fonts in other terminal emulators - the current API for iTerm2 requires a Python script to change settings programmatically
Fixes #25
To do
run_with_retry
from #26 to fail gracefully (i.e. continue through the rest of the script) if something goes wrong (e.g. the user has renamed/removed the "Basic" Terminal profile)Comments
@erbridge curious what you think of this solution. It doesn't completely address "leaving people with required follow up actions they need to take for the thing to be useful" if we assume that people will follow the closing advice to "use the newly installed iTerm.app in future", but it does at least install the font and update Terminal, should the user be running the script from there
If a user is using or switches to iTerm2, they'd have the font ready for use on their system but would need to set it manually - unless we figure out a Python script to automate that