Skip to content

Instantly share code, notes, and snippets.

View KuangyeChen's full-sized avatar

Kuangye Chen KuangyeChen

View GitHub Profile
@KuangyeChen
KuangyeChen / linux_py_setup.sh
Created October 18, 2022 15:36
Setup pyenv / pipx / poetry in linux.
#!/usr/bin/env sh
git clone https://github.com/pyenv/pyenv.git ~/.pyenv
git clone https://github.com/pyenv/pyenv-virtualenv.git ~/.pyenv/plugins/pyenv-virtualenv
python3 -m pip install --user pipx
#!/usr/bin/env sh
curl -fLo ~/.vim/autoload/plug.vim --create-dirs \
https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
vim -c "PlugInstall" -c ":q" -c ":q" -c ":q" -c ":q"
#!/usr/bin/env sh
sh -c "$(curl -fsLS chezmoi.io/get)" -- init --ssh --apply "KuangyeChen"
@KuangyeChen
KuangyeChen / printe_color_code.sh
Last active June 19, 2022 06:18
Print color with color code
for i in {0..255}; do
print -Pn "%K{$i} %k%F{$i}${(l:3::0:)i}%f " ${${(M)$((i%6)):#3}:+$'\n'};
done
@KuangyeChen
KuangyeChen / install_oh_my_zsh.bash
Last active January 7, 2023 03:28
Install oh-my-zsh related stuff.
#!/usr/bin/env bash
set -e
function log_section() {
printf "\033[0;32m==>\033[0m\033[1m ${*}\033[0m\n"
}
function log_warning() {
printf "\033[1mWARN\033[0m: ${*}\n"
@KuangyeChen
KuangyeChen / brew_install_all.bash
Last active July 3, 2022 00:56
Install all brew formulae and casks
#!/usr/bin/env bash
set -e
function log_section() {
printf "\033[0;32m==>\033[0m\033[1m ${*}\033[0m\n"
}
function log_warning() {
printf "\033[1mWARN\033[0m: ${*}\n"