-
Download the IBM Plex font.
-
Follow the link to the Github releases page. Download the OpenType font from the latest release.
-
To install, after decompressing, drag all subfolders of the
OpenTypefolder to Font Book.
-
-
In terminal, run
xcode-select --installto download developer tools. -
Follow these steps to set up a new SSH key for this device.
-
Now clone this repo over SSH and destroy the dummy SSH config created in the previous step:
git clone --recursive git@github.com:cterdam/cfg.git ~/llz/cfg rm ~/.ssh/config
-
Add
~/llzto the Finder side bar and Dock. -
Set up terminal appearance by importing
termto terminal profiles. -
Install Oh My Zsh.
- After Oh My Zsh is installed and launched, install ZSH theme and plugins.
-
Install Conda.
-
Install Golang.
-
Install Node.js.
-
Install Rust.
-
Use the command found on the website. Prepend
sudoand run it. -
The installer might show some commands to run after installation. You can still run them to avoid any surprises, but the
zshrcis supposed to take care of configuring the correct paths once activated.
-
-
Install homebrew.
- Upon finishing installation, the script will print a 'Next steps' section which mentions two commands to run in order to add homebrew to PATH. Run them.
-
Now install Neovim with
brew install neovim.-
Install yarn with
sudo npm install --global yarn.- This is for markdown-preview, and possibly some COC extensions.
-
Install silicon with
brew install silicon.- This is for vim-silicon.
-
Install code-minimap with
cargo install --locked code-minimap- This is for minimap.vim.
-
Install universal-ctags with
brew install --HEAD universal-ctags- This is for vista.vim.
-
-
Install tmux with
brew install tmux.-
Also install Tmux Plugin Manager with
git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm. -
Don't worry about installing actual plugins for now:
dot/tmux.confwill take care of it.
-
-
We have not dealt with
zshrcin the new system yet, but the Conda and Oh My Zsh installation scripts should have created one in the home directory. Read it through, but everything there should already be incorporated intozshrcwhich will be installed later. So just delete it so we can use our own shell script:rm $HOME/.zshrc -
Now activate the shell scripts:
-
Link
dot/zshrcto the realzshrclocation:ln -s $HOME/llz/cfg/dot/zshrc $HOME/.zshrc
-
Restart shell, then restart again. Now type
PrefixShift + Ito install tmux plugins.Prefixis the tmux prefix, by defaultCtrl+b.
-
Ensure ownership of vim and COC folders:
mkdir -p $HOME/.vim $HOME/.config sudo chown -R `whoami` $HOME/.vim sudo chown -R $(whoami) $HOME/.config
-
Now run
sudo nvimand it will auto install all plugins, including COC plugins.
-
- Obtain
.xyz.ascfrom another machine, and put it in$LLZDOT - Import the key into the local GPG agent:
gpg --import $LLZDOT/.xyz.asc- Importing the public key should be unnecessary.
- Find the Key ID of the public key with
gpg --list-keys - Give the key the highest trust:
gpg --edit-key <KEY_ID>
-
Install Docker.
-
Install Jekyll for GitHub pages.
-
The link basically says run these:
brew install chruby ruby-install xz ruby-install ruby 3.4.1 ruby -v # 3.4.1 or above sudo gem install jekyll
-
-
Install Liberation Fonts.
-
To install, simply download the TTF file from the latest release.
-
This is for the English resume.
-
-
Install MacTeX, the recommended LaTeX distribution for macOS.
-
Test
latexmkandlatexindent. Iflatexindentdoes not work, install the following packages:sudo cpan install YAML::Tiny File::HomeDir Unicode::GCString
-
-
Install Rime for Chinese input.
-
Rime needs to be used with its plum package manager, which is already incorporated as a submodule.
-
Install all default Rime packages:
cd $HOME/llz/cfg/plum bash rime-install :all
-
Then install the WU HAN Chinese and Cantonese Soeng-Ping packages:
bash rime-install cterdam/hubehua cterdam/jyutsp
-
Deploy Rime engine. Log out and log back in.
-
-
Install other UNIX tools:
brew install gpg bat fzf git-delta git-lfs less tree tldr shellcheck jq reattach-to-user-namespace coreutils brew install xquartz --cask pip install vim-vint ipython black isort
reattach-to-user-namespaceis needed for thetmux-yankplugin.xquartzis needed for clipboard forwarding with SSH remote.
-
Install Java.
-
Install JupyterLab Desktop.
-
Install Octave with
brew install octave. -
Install tools for C#:
-
To conveniently open files with vim from Finder, after finishing the above instructions, install MacVim.
-
Open MacVim Preferences, and set "After last window closes" to "Quit MacVim".
-
Open this location in Finder:
cd $LLZHOME/cfg/fts/dummy open .
-
Select all files, and press
Command + Option + I. Select MacVim in the "Open with" menu, and click on "Change All...".
-
To use an SSH key to connect to remote:
-
On the server, insert local public keys into this file. Comment lines can start with
#.vim ~/.ssh/authorized_keys -
Locally, register an entry in
~/.ssh/config.- Ensure
xauthis installed on server.
- Ensure
-
-
Change the default shell to
zsh:chsh -s $(which zsh)
This section is a summary of native instructions from GitHub found here.
-
Produce a new pair of keys:
ssh-keygen -t ed25519 -C "your_email@example.com"Name the key after the device and save it in
~/.ssh. -
Link that keypair to
llzandllz.pub:ln -s ~/.ssh/<KEY_NAME> ~/.ssh/llz ln -s ~/.ssh/<KEY_NAME>.pub ~/.ssh/llz.pub
-
Copy the contents of
llz.pub-
If on macOS:
cat ~/.ssh/llz.pub | pbcopy
And add it to GitHub here both as an Authentication key and as a Signing key.
-
-
Create the
~/.ssh/configfile, and insert this content:Host github.com IdentityFile ~/.ssh/llz
git clone --depth=1 https://github.com/romkatv/powerlevel10k.git ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/themes/powerlevel10k
git clone https://github.com/esc/conda-zsh-completion ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/plugins/conda-zsh-completion
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
git clone https://github.com/KellieOwczarczak/conda.plugin.zsh.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/conda-
Append the new filetype extension name, without the dot, as a new line into
$LLZHOME/cfg/fts/ftlist. Do not leave empty lines in the file.- After inserting, sort all lines in the file. This can be done either in nvim
by
:1,%sort, or in the shell withsort -o $LLZHOME/cfg/fts/ftlist{,}.
- After inserting, sort all lines in the file. This can be done either in nvim
by
-
Then repopulate the
dummyfolder:repopft $LLZHOME/cfg/fts/dummy $LLZHOME/cfg/fts/ftlist
- It may simply create the needed new file(s), or print out other diagnostic messages.
Follow them to fix the
dummyfolder and theftlistfile. If things are complicated, just remove thedummydirectory altogether, and run the command again.
- It may simply create the needed new file(s), or print out other diagnostic messages.
Follow them to fix the
-
Then, follow instructions in this section to register the new filetypes.
-
Conda cannot install.
-
If installation cannot start, change install to for the current user only, as opposed for all users.
-
If installation ultimately fails, change the owner of shell config files to the current user:
sudo chown -R $USER ~/.bash_profile ~/.config/fish/config.fish ~/.tcshrc ~/.xonshrc ~/.zshrc
-
-
After macOS update, some things fall apart. E.g.
gitdisappears.- Reinstall Xcode Command Line Tools tools with
xcode-select --install.
- Reinstall Xcode Command Line Tools tools with
-
COC Java plugin crashes.
- This happens when the language server is started on the same directory multiple
times. Just clear cache with
:CocCommand java.clean.workspace.
- This happens when the language server is started on the same directory multiple
times. Just clear cache with
-
A different Java version is needed.
-
Any Java LTS version should work just fine, but if for any reason a lower version of Java is needed (e.g. Search Engines course), then the
jdtforcoc-javamight not work correctly. In that case follow this issue to replace the automatically-downloadedjdtwith an older version which works with lower versions of Java. Specifically,Version 57 of JDT Lang Sever works fine https://download.eclipse.org/jdtls/milestones/0.57.0/ Quick hack for those who are facing this issue Replace all directories/files in ~/.config/coc/extensions/coc-java-data/server with directories/files from above extracted JDT lang server tar.
-
-
Rust installation script needs to alter shell files which are nonexistent.
- Just use the graphic installer. After running the installer, the installed
Rust environment might not be in
$PATHright away, but the ourzshrcshould take care of that once activated.
- Just use the graphic installer. After running the installer, the installed
Rust environment might not be in
-
Vim installed through brew does not seem to replace system vim.
- Upon finishing installing the brew version, run
which vimand you might see that it's still the system vim (and not the brew vim) which gets evoked. This is because brew-installed apps are not given priority in PATH. Don't worry about it;dot/zshrcwill fix this.
- Upon finishing installing the brew version, run
Use git submodule status --recursive to see all submodules.
If submodule folders appear empty after cloning, run this to download all:
git submodule update --init --recursiveNote that updating the parent repo will not automatically update submodules. To update submodules:
git submodule update --recursive --remoteOr, if cloning this parent repo for the first time, run this to download everything:
git clone --recursive <project url>