Stuff that I use a lot when I set up a new computer, or start a new project.
See the Mac Essentials document.
zsh
is the default shell since macOS Catalina. These articles on Scripting OS X, by Armin Briegel, are a good primer on zsh
and the changes from bash
.
zshrc
goes in/etc/
, and is executed for all users.zshrc
goes in~/
, and is for the current user only.
Adding to $PATH, examples:
PATH=$PATH:~/opt/bin # New path at end
PATH=~/opt/bin:$PATH # New path first
I am now using oh-my-zsh, as their git plugin is very nice, and I lurrrve the Powerlevel10k theme.
Install these bits:
Download the latest version of the app from here, or go to the iTerm2 Website.
Download these fonts before importing the settings, so the fonts in the settings are already there. Otherwise, it'll default to a different font when you import, and you'll have to set them again later:
- Download the MesloLSGS NF font and install.
- Download the (not free) Dank Mono font and install. If licensed, it should be in your Gumroad library.
Go to iTerm2 ▶︎ Preferences ▶︎ Profiles ▶︎ Other Actions… ▶︎ Import JSON Profiles… and select and open mboszko-term.json
from this repo. Select the new mboszko
profile and click Other Actions… ▶︎ Set as Default, and then you can delete the old default profile.
I already have the Yoncé colors (see below) as part of my profile, but you can also get them from the Yoncé repo
By default, word jumps (option + → or ←) and word deletions (option + backspace) do not work. To enable these, go to iTerm ▶︎ Preferences ▶︎ Profiles ▶︎ Keys ▶︎ Key Mappings ▶︎ Presets... ▶︎ Natural Text Editing ▶︎ Boom! Head explodes! (I do have this set in the profile linked above.)
sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
- Installation instructions with a helpful section about VS Code config
- Powerlevel10k git repo
Clone the repository:
git clone --depth=1 https://github.com/romkatv/powerlevel10k.git ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/themes/powerlevel10k
If you're not going to use this repo's .zshrc
, set ZSH_THEME="powerlevel10k/powerlevel10k"
in ~/.zshrc
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
If you're not going to use this repo's .zshrc
, add the plugin to ~/.zshrc
:
plugins=(
# other plugins...
zsh-autosuggestions
)
The zsh-syntax-highlighting authors recommend manual installation over the use of a framework or plugin manager.
But I'm going to ignore that recommendation. Clone the repository in oh-my-zsh's plugins directory:
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
If you're not going to use this repo's .zshrc
, add the plugin to ~/.zshrc
. It needs to be the last plugin listed:
plugins=(
# other plugins...
zsh-syntax-highlighting
)
Maybe install these macOS specific tools. The Trash one is especially handy.
At this point, copy .zshrc
and .p10k.zsh
from this repo into your ~/
user directory, and then open a new iTerm window. If you set the iTerm fonts properly at the beginning, you should be all set.
I have made a fork of Yoncé, “Queen Bey-inspired themes for all your favs,” based on the original by Mina Markham. I love the colors, and there are presets for iTerm (already included in my profile here), Slack, Alfred, VS Code, etc.
I need to make a segment about settings and layout for Visual Studio Code, but for now it's my primary editor.
TODO: I think I'm moving to
pipenv
for all of my environment stuff, so this needs to be updated
- Download the latest Python (3.10.2, as of this writing) and install
- run
Update Shell Profile.command
andInstall Certificates.command
- Use
virtualenv
andvirtualenvwrapper
for every project sudo -H pip3 install --upgrade virtualenv
sudo -H pip3 install --upgrade virtualenvwrapper
- Make sure that the
.bashrc
is updated with my default Python settings cd ~/dev
andmkproject PROJECT_NAME_HERE
to start a new venv and project
pip3 install blessings
for Pythonblessings
for printing colors and other formatting to the terminal.pip3 install bpython
to installbpython
, a Python REPL wrapper that adds definition pop-ups and syntax coloring
I just got the Microsoft Sculpt Ergonomic Desktop (L5V-00001), and I'm trying it out, so I guess we'll see if it sticks. But if you are using it, here's how to makie it more comfortable with macOS:
- Install Karabiner-Elements, and import the macOS friendlly customizations for the keyboard.