clean code

Signed-off-by: Lee Tang <i@d0zingcat.dev>
This commit is contained in:
Lee Tang
2023-01-15 10:39:07 +08:00
parent bcbbed8e30
commit 3ea9ab0d06
5 changed files with 51 additions and 3948 deletions

2
.gitignore vendored
View File

@@ -4,5 +4,5 @@ raycast/extensions
raycast/config.json
*.env
.git/
ssh/
#ssh/
.DS_Store

File diff suppressed because it is too large Load Diff

View File

@@ -1,31 +1,40 @@
[init]
defaultBranch = main
defaultBranch = main
[user]
email = i@d0zingcat.dev
name = Lee Tang
signingkey = ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICWNAdF4p781cI/fIyHAEw+JgRxnoKX5BBk+xyr6r09W
[url "https://"]
insteadOf = git://
[core]
editor = nvim
excludesfile = /Users/d0zingcat/.config/git/.gitignore
email = i@d0zingcat.dev
name = Lee Tang
signingkey = ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPaVruhhL4O9BiAncnW1wH3jc7/hsqsXLknA8Xtnjjee
[commit]
gpgsign = true
gpgsign = true
[gpg]
format = ssh
format = ssh
[gpg "ssh"]
program = "/Applications/1Password.app/Contents/MacOS/op-ssh-sign"
program = "/Applications/1Password.app/Contents/MacOS/op-ssh-sign"
[url "https://"]
insteadOf = git://
[core]
editor = nvim
excludesfile = /Users/d0zingcat/.config/git/.gitignore
[pager]
difftool = true
[diff]
external = difft
tool = difftastic
[difftool]
prompt = false
[difftool "difftastic"]
cmd = difft "$LOCAL" "$REMOTE"
[alias]
lg = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
pr = pull --rebase origin

View File

@@ -6,7 +6,6 @@ FILES=(
.gitignore
.zshrc
.zlogin
.tmux.conf
.ideavimrc
@@ -25,7 +24,7 @@ CONFIG_FILES=(
)
CUSTOM_FILES=(
# "ssh/config .ssh/config"
"ssh/config .ssh/config"
"git/config .gitconfig"
)
@@ -121,6 +120,7 @@ function recover() {
if [ "$OS" = 'Darwin' ]; then
export PATH=/usr/local/bin/:$PATH
xcode-select --install
defaults write -g ApplePressAndHoldEnabled -bool false
elif [ "$OS" = 'Linux' ]; then
export PATH=/home/linuxbrew/.linuxbrew/bin/:$PATH
fi
@@ -173,6 +173,9 @@ function recover() {
if [ $is_linux -eq 1 ] && [ $release_name = $RELEASE_ARCH ]
then
sudo pacman -S - < pkglist.txt
elif [ $is_macos -eq 1 ]
then
mkdir -p ~/.1password && ln -s ~/Library/Group\ Containers/2BUA8C4S2C.com.1password/t/agent.sock ~/.1password/agent.sock
fi
# others

24
ssh/config Normal file
View File

@@ -0,0 +1,24 @@
Host *
IdentityAgent "~/.1password/agent.sock"
ServerAliveInterval 60
Host github.com
Hostname ssh.github.com
Port 443
User git
# Personal GitHub
Host personalgit
Hostname ssh.github.com
Port 443
User git
IdentityFile ~/.ssh/personal_git.pub
IdentitiesOnly yes
# Work GitHub
Host workgit
Hostname ssh.github.com
Port 443
User git
IdentityFile ~/.ssh/work_git.pub
IdentitiesOnly yes