295 lines
6.4 KiB
Bash
Executable File
295 lines
6.4 KiB
Bash
Executable File
#!/bin/sh
|
|
|
|
[ -n "${DEBUG-}" ] && set -x
|
|
|
|
cd "$(dirname "$0")" || exit 1
|
|
|
|
mkdir -p "$HOME/.config"
|
|
|
|
cat <<EOF >"$HOME/.wezterm.lua"
|
|
local wezterm = require 'wezterm'
|
|
local config = {}
|
|
|
|
if wezterm.config_builder then
|
|
config = wezterm.config_builder()
|
|
end
|
|
|
|
config.font = wezterm.font_with_fallback({
|
|
{ family = 'Operator Mono', weight = 'Book' },
|
|
'Symbols Nerd Font'
|
|
})
|
|
config.font_size = 22.0
|
|
-- config.color_scheme = 'One Light (base16)'
|
|
config.color_scheme = 'Windows 10 (base16)'
|
|
config.window_background_opacity = 0.9
|
|
config.initial_rows = 30
|
|
config.initial_cols = 120
|
|
config.use_fancy_tab_bar = false
|
|
config.mouse_bindings = {
|
|
{
|
|
event = { Up = { streak = 1, button = 'Left' } },
|
|
mods = 'CTRL',
|
|
action = wezterm.action.OpenLinkAtMouseCursor,
|
|
},
|
|
}
|
|
config.keys = {
|
|
-- Make Ctrl-b equivalent to Alt-b which many line editors interpret as backward-word
|
|
{key="b", mods="CTRL", action=wezterm.action{SendString="\x1bb"}},
|
|
-- Make Ctrl-f equivalent to Alt-f which many line editors interpret as forward-word
|
|
{key="f", mods="CTRL", action=wezterm.action{SendString="\x1bf"}},
|
|
}
|
|
|
|
return config
|
|
EOF
|
|
|
|
cat <<EOF >"$HOME/.config/starship.toml"
|
|
[container]
|
|
disabled=true
|
|
EOF
|
|
|
|
mkdir -p "$HOME/.config/helix/themes"
|
|
cat <<EOF >"$HOME/.config/helix/themes/mylight.toml"
|
|
inherits = "onelight"
|
|
|
|
"comment" = { fg = "grey" }
|
|
"comment.line" = { fg = "grey" }
|
|
"comment.block" = { fg = "grey" }
|
|
"comment.block.documentation" = { fg = "grey" }
|
|
EOF
|
|
|
|
cat <<EOF >"$HOME/.config/helix/config.toml"
|
|
# theme = "mylight"
|
|
theme = "molokai"
|
|
|
|
[editor]
|
|
true-color = true
|
|
color-modes = true
|
|
idle-timeout = 75
|
|
mouse = false
|
|
bufferline = "multiple"
|
|
auto-pairs = false
|
|
|
|
[editor.indent-guides]
|
|
render = true
|
|
|
|
[editor.cursor-shape]
|
|
insert = "bar"
|
|
normal = "block"
|
|
select = "underline"
|
|
|
|
[editor.whitespace.render]
|
|
tab = "all"
|
|
|
|
[editor.soft-wrap]
|
|
enable = true
|
|
EOF
|
|
|
|
mkdir -p "$HOME/.config/kitty"
|
|
cat <<EOF >"$HOME/.config/kitty/kitty.conf"
|
|
font_family Operator Mono Book
|
|
bold_font Operator Mono Bold
|
|
italic_font Operator Mono Italic
|
|
bold_italic_font Operator Mono Bold Italic
|
|
font_size 20.0
|
|
cursor_shape block
|
|
shell_integration no-cursor
|
|
tab_bar_edge top
|
|
remember_window_size yes
|
|
initial_window_width 130c
|
|
initial_window_height 35c
|
|
copy_on_select yes
|
|
|
|
symbol_map U+23FB-U+23FE,U+2665,U+26A1,U+2B58,U+E000-U+E00A,U+E0A0-U+E0A3,U+E0B0-U+E0D4,U+E200-U+E2A9,U+E300-U+E3E3,U+E5FA-U+E6AA,U+E700-U+E7C5,U+EA60-U+EBEB,U+F000-U+F2E0,U+F300-U+F32F,U+F400-U+F4A9,U+F500-U+F8FF,U+F0001-U+F1AF0 Symbols Nerd Font
|
|
|
|
# BEGIN_KITTY_THEME
|
|
include dark-theme.conf
|
|
# END_KITTY_THEME
|
|
EOF
|
|
|
|
cat <<EOF >"$HOME/.config/kitty/light-theme.conf"
|
|
# vim:ft=kitty
|
|
## name: One Half Light
|
|
## author: Son A. Pham
|
|
## license: MIT
|
|
## upstream: https://raw.githubusercontent.com/sonph/onehalf/master/kitty/onehalf-light.conf
|
|
## blurb: Clean, vibrant and pleasing color scheme
|
|
|
|
foreground #383A42
|
|
background #FAFAFA
|
|
selection_foreground #383A42
|
|
selection_background #BFCEFF
|
|
url_color #F0F0F0
|
|
|
|
# black
|
|
color0 #383A42
|
|
color8 #383A42
|
|
|
|
# red
|
|
color1 #E45649
|
|
color9 #E45649
|
|
|
|
# green
|
|
color2 #40A14F
|
|
color10 #40A14F
|
|
|
|
# yellow
|
|
color3 #C18401
|
|
color11 #C18401
|
|
|
|
# blue
|
|
color4 #0184BC
|
|
color12 #0184BC
|
|
|
|
# magenta
|
|
color5 #A626A4
|
|
color13 #A626A4
|
|
|
|
# cyan
|
|
color6 #0997B3
|
|
color14 #0997B3
|
|
|
|
# white
|
|
color7 #FAFAFA
|
|
color15 #FAFAFA
|
|
EOF
|
|
|
|
cat <<EOF >"$HOME/.config/kitty/dark-theme.conf"
|
|
# vim:ft=kitty
|
|
|
|
## name: Campbell
|
|
## author: Microsoft
|
|
## blurb: The default theme of Microsoft's terminals, including Windows Terminal and cmd.
|
|
|
|
# The basic colors
|
|
foreground #cccccc
|
|
background #0c0c0c
|
|
selection_background #ffffff
|
|
|
|
# Cursor colors
|
|
cursor #ffffff
|
|
|
|
# The basic 16 colors
|
|
# black
|
|
color0 #0c0c0c
|
|
color8 #767676
|
|
|
|
# red
|
|
color1 #c50f1f
|
|
color9 #e74856
|
|
|
|
# green
|
|
color2 #13a10e
|
|
color10 #16c60c
|
|
|
|
# yellow
|
|
color3 #f19c00
|
|
color11 #f9f1a5
|
|
|
|
# blue
|
|
color4 #0037da
|
|
color12 #3b78ff
|
|
|
|
# magenta
|
|
color5 #881798
|
|
color13 #b4009e
|
|
|
|
# cyan
|
|
color6 #3a96dd
|
|
color14 #61d6d6
|
|
|
|
# white
|
|
color7 #cccccc
|
|
color15 #f2f2f2
|
|
EOF
|
|
|
|
curl -sLo "$HOME/.config/themes.gitconfig" "https://raw.githubusercontent.com/dandavison/delta/main/themes.gitconfig"
|
|
cat <<EOF >"$HOME/.gitconfig"
|
|
[include]
|
|
path = "~/.config/themes.gitconfig"
|
|
|
|
[push]
|
|
default = simple
|
|
|
|
[user]
|
|
name = Andrew Coleman
|
|
email = penguincoder@gmail.com
|
|
|
|
[advice]
|
|
detachedHead = false
|
|
|
|
[core]
|
|
filemode = true
|
|
eol = lf
|
|
autocrlf = input
|
|
pager = delta
|
|
|
|
[init]
|
|
defaultBranch = main
|
|
|
|
[delta]
|
|
line-numbers = true
|
|
file-style = omit
|
|
hunk-header-style = file
|
|
|
|
[rebase]
|
|
autoStash = true
|
|
|
|
[merge]
|
|
tool = vimdiff
|
|
conflictstyle = diff3
|
|
prompt = false
|
|
|
|
[pull]
|
|
rebase = true
|
|
|
|
[color]
|
|
branch = auto
|
|
diff = auto
|
|
status = auto
|
|
ui = true
|
|
|
|
[color "branch"]
|
|
current = yellow reverse
|
|
local = yellow
|
|
remote = green
|
|
|
|
[color "status"]
|
|
added = yellow
|
|
changed = green
|
|
untracked = red
|
|
|
|
[alias]
|
|
logp = log --pretty=format:'%h %ad | %s%d [%an]' --graph --date=short
|
|
lg = log --graph --date-order --first-parent \
|
|
--pretty=format:'%C(auto)%h%Creset %C(auto)%d%Creset %s %C(green)(%ad) %C(bold cyan)<%an>%Creset'
|
|
lgb = log --graph --date-order --branches --first-parent \
|
|
--pretty=format:'%C(auto)%h%Creset %C(auto)%d%Creset %s %C(green)(%ad) %C(bold cyan)<%an>%Creset'
|
|
lga = log --graph --date-order --all \
|
|
--pretty=format:'%C(auto)%h%Creset %C(auto)%d%Creset %s %C(green)(%ad) %C(bold cyan)<%an>%Creset'
|
|
up = pull --rebase
|
|
branches-last-updated = branch -rv --sort=committerdate --format='%(HEAD) %(color:green)%(committerdate:relative)%(color:reset)\t%(color:magenta)%(authorname)%(color:reset)\t%(color:yellow)%(refname:short)%(color:reset)'
|
|
EOF
|
|
|
|
cat <<EOF >"$HOME/.tmux.conf"
|
|
set-option -g update-environment "SSH_AUTH_SOCK SSH_CONNECTION"
|
|
EOF
|
|
|
|
cat <<EOF >"$HOME/.vimrc"
|
|
" gratis https://swordandsignals.com/2020/12/13/5-lines-in-vimrc.html
|
|
set hlsearch " highlight all search results
|
|
set ignorecase " do case insensitive search
|
|
set incsearch " show incremental search results as you type
|
|
set number " display line number
|
|
set noswapfile " disable swap file
|
|
" can also be summarized as
|
|
set hls ic is nu noswf
|
|
" from https://www.guckes.net/vim/setup.html
|
|
set ai nocp ek hid ru sc vb wmnu noeb noet nosol
|
|
set bs=2 fo=cqrt ls=2 shm=at ww=<,>,h,l
|
|
set comments=b:#,:%,n:>
|
|
set list listchars=tab:>=,trail:-
|
|
set viminfo=%,'50,\"100,:100,n~/.viminfo
|
|
EOF
|
|
|
|
install -m 640 ./.zshrc "$HOME/"
|