Configurations and color scheme are stored in vimrc
and vim
directory.
Set up git editor to vim, exclude .DS_Store
and .vscode
directory, add an alias git graph
.
Configure oh-my-zsh theme and plugins
Implement a function trash()
to trash instead of rm
file, 😭😭😭, a rm accidient is the direct cause of this function.
In newer version, on macOS, use AppleScript to call Finder App to delete posix file, this is mucher than naively move to trash in older version, which evokes problems like delete files with name confliction.
On Linux, call gio trash
, I havn't tested the function, as I don't have a linux desktop envioronment.
After all, the install script and the function is write by new bing with following requirements
write a shell function t which calls macOS system api on macOS and gio trash on Linux to move a file to trash, it take files in current directory as arguments, if the input is empty, display help message for usage, and implement --help flag
Create symbolics links for dotfiles, and check if .zshrc
has sources .my_zshrc
, if not, append code to source .my_zshrc
in .zshrc
If on macOS, create a symbolic link to iCloud Drive directory.
install dotfiles with
./install.sh
if you are a swift programming language learn, your can install by running
swift run
I perfer to write script in swift. the install script first check if the links or files with name to be create exist, you need to manually delete those files before install.