From 306f37bb7ef07ce7712ca23e73b3777234600f38 Mon Sep 17 00:00:00 2001 From: Andrew Coleman Date: Tue, 10 May 2022 13:58:50 -0400 Subject: [PATCH] update configs --- README.md | 116 +++ dot_bashrc | 37 +- dot_config/alacritty.yml | 939 ++++++++++++++++++ dot_config/bash/aliases.sh | 13 + dot_config/bash/asdf.sh | 3 + .../bash/bash-preexec.sh | 0 .../bash/bash-setup.sh | 18 + dot_config/bash/bat.sh | 4 + .../bash}/cargo.sh | 0 dot_config/bash/editor.sh | 8 + .../bash}/git-prompt.sh | 0 .../bash}/gitea.sh.tmpl | 0 .../bash}/go-setup.sh | 0 dot_config/bash/history.sh | 57 ++ dot_config/bash/just.bash | 123 +++ dot_config/bash/lscolors.sh | 1 + dot_config/bash/nix.sh | 3 + dot_config/bash/pager.sh | 3 + dot_config/bash/puts.sh | 3 + .../bash}/shell-prompt.sh | 2 + .../bash}/window.sh | 0 .../bash}/wsl-ssh-agent.sh.tmpl | 0 .../bash}/xhost.sh.tmpl | 0 dot_config/git/delta_gitconfig | 298 ++++++ dot_config/kitty/current-theme.conf | 21 + dot_config/kitty/kitty.conf | 14 + dot_config/lvim/config.lua | 163 +++ dot_config/nvim/init.vim | 201 +++- dot_gitconfig | 87 +- dot_vimrc | 6 + private_dot_aws/private_credentials.tmpl | 3 - private_dot_bashrc.d/aliases.sh | 37 - private_dot_bashrc.d/history.sh | 20 - .../kubernetes-wellsky.sh.tmpl | 2 - private_dot_bashrc.d/pager.sh | 8 - 35 files changed, 2013 insertions(+), 177 deletions(-) create mode 100644 README.md create mode 100644 dot_config/alacritty.yml create mode 100644 dot_config/bash/aliases.sh create mode 100644 dot_config/bash/asdf.sh rename dot_bash-preexec.sh => dot_config/bash/bash-preexec.sh (100%) rename private_dot_bashrc.d/bash-completion.sh => dot_config/bash/bash-setup.sh (51%) create mode 100644 dot_config/bash/bat.sh rename {private_dot_bashrc.d => dot_config/bash}/cargo.sh (100%) create mode 100644 dot_config/bash/editor.sh rename {private_dot_bashrc.d => dot_config/bash}/git-prompt.sh (100%) rename {private_dot_bashrc.d => dot_config/bash}/gitea.sh.tmpl (100%) rename {private_dot_bashrc.d => dot_config/bash}/go-setup.sh (100%) create mode 100644 dot_config/bash/history.sh create mode 100644 dot_config/bash/just.bash create mode 100644 dot_config/bash/lscolors.sh create mode 100644 dot_config/bash/nix.sh create mode 100644 dot_config/bash/pager.sh create mode 100644 dot_config/bash/puts.sh rename {private_dot_bashrc.d => dot_config/bash}/shell-prompt.sh (89%) rename {private_dot_bashrc.d => dot_config/bash}/window.sh (100%) rename {private_dot_bashrc.d => dot_config/bash}/wsl-ssh-agent.sh.tmpl (100%) rename {private_dot_bashrc.d => dot_config/bash}/xhost.sh.tmpl (100%) create mode 100644 dot_config/git/delta_gitconfig create mode 100644 dot_config/kitty/current-theme.conf create mode 100644 dot_config/kitty/kitty.conf create mode 100644 dot_config/lvim/config.lua delete mode 100644 private_dot_aws/private_credentials.tmpl delete mode 100644 private_dot_bashrc.d/aliases.sh delete mode 100644 private_dot_bashrc.d/history.sh delete mode 100644 private_dot_bashrc.d/kubernetes-wellsky.sh.tmpl delete mode 100644 private_dot_bashrc.d/pager.sh diff --git a/README.md b/README.md new file mode 100644 index 0000000..1b2a73e --- /dev/null +++ b/README.md @@ -0,0 +1,116 @@ +# ZFS encrypted home + +```bash +# create key, as root +dd if=/dev/urandom of=/etc/zfs/home.key bs=32 count=1 && chmod 600 /etc/zfs/home.key +# create pool +zpool create storage -O xattr=sa -O acltype=posixacl -O atime=off -O compression=lz4 -o ashift=12 /dev/DISK +# create home dataset +zfs create -O encryption=aes-256-gcm -O keyformat=raw -O keylocation=file:///etc/zfs/home.key -o mountpoint=/home storage/home +# create individual dataset +zfs create storage/home/andrew + +# enable zfs load key from file at boot +cat < /etc/systemd/system/zfs-load-key.service +[Unit] +Description=Load encryption keys +DefaultDependencies=no +After=zfs-import.target +Before=zfs-mount.service + +[Service] +Type=oneshot +RemainAfterExit=yes +ExecStart=/usr/sbin/zfs load-key -a +StandardInput=tty-force + +[Install] +WantedBy=zfs-mount.service +EOF + +# turn on services +systemctl enable zfs.target +systemctl enable zfs-import-cache +systemctl enable zfs-mount +systemctl enable zfs-import.target +systemctl enable zfs-load-key +``` + +# Arch / Manjaro + +```bash +pacman-mirrors --geoip +pamac install linux-api-headers linux-headers +pamac install zfs-dkms +zpool import -f storage +zpool set cachefile=/etc/zfs/zpool.cache storage +pamac install \ + atuin \ + base-devel \ + bash-completion \ + bat \ + bitwarden-cli \ + bottom \ + direnv \ + dust \ + exa \ + fd \ + fzf \ + git \ + git-delta \ + gitui \ + glances \ + go \ + hdparm \ + hexyl \ + htop \ + httpie \ + hyperfine \ + jq \ + just \ + kitty \ + libvirt \ + lzop \ + lsd \ + mhash \ + mosh \ + neovim \ + nmon \ + opendoas \ + pv \ + qemu \ + ripgrep \ + shfmt \ + starship \ + tealdeer \ + tmux \ + vim \ + virt-manager \ + zoxide +# not available by default +#jc mbuffer +pamac build lightly-qt +``` + +# Kitty + +```bash +curl -L https://sw.kovidgoyal.net/kitty/installer.sh | sh /dev/stdin +ln -s "$HOME/.local/kitty.app/bin/kitty" "$HOME/.local/bin/" +cp "$HOME/.local/kitty.app/share/applications/kitty.desktop" "$HOME/.local/share/applications/" +cp "$HOME/.local/kitty.app/share/applications/kitty-open.desktop" "$HOME/.local/share/applications/" +sed -i "s|Icon=kitty|Icon=$HOME/.local/kitty.app/share/icons/hicolor/256x256/apps/kitty.png|g" "$HOME/.local/share/applications/kitty*.desktop" +``` + +# Nix + +```bash +sh <(curl -L https://nixos.org/nix/install) --daemon +``` + +# Rust + +```bash +curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh +``` + diff --git a/dot_bashrc b/dot_bashrc index 1dbc241..1337816 100644 --- a/dot_bashrc +++ b/dot_bashrc @@ -1,35 +1,9 @@ # If not running interactively, don't do anything [[ $- != *i* ]] && return -# start in home directory -# shellcheck disable=SC2164 -if [ "$PWD" != "$HOME" ] && [ "$PWD" -ef "$HOME" ] ; then cd ; fi -# change $HOME on FreeBSD to /usr/home/andrew -# shellcheck disable=SC2164 -if [ -d "/usr$HOME" ] ; then export HOME=/usr$HOME ; cd ; fi - -# load system bashrc -for BASHRC in /etc/bashrc /etc/bash.bashrc /etc/bash/bashrc ; do - if [ -f "$BASHRC" ] ; then - # shellcheck source=/dev/null - . "$BASHRC" - fi -done -unset BASHRC - -# this assumes nvim is always installed for $EDITOR -EDITOR=nvim; export EDITOR - -# local paths -if ! [[ "$PATH" =~ $HOME/.local/bin:$HOME/bin: ]] -then - PATH="$HOME/.local/bin:$HOME/bin:$PATH" -fi -export PATH - # User specific aliases and functions -if [ -d ~/.bashrc.d ]; then - for rc in ~/.bashrc.d/*; do +if [ -d "$HOME/.config/bash" ]; then + for rc in "$HOME/.config/bash/*"; do if [ -f "$rc" ]; then # shellcheck source=/dev/null . "$rc" @@ -38,12 +12,6 @@ if [ -d ~/.bashrc.d ]; then fi unset rc -if [ -f "$HOME/.bash-preexec.sh" ] ; then - source "$HOME/.bash-preexec.sh" - eval "$("$HOME/.cargo/bin/atuin" init bash)" -fi - -# direnv hook if which direnv > /dev/null 2>&1 ; then eval "$(direnv hook bash)" fi @@ -53,3 +21,4 @@ if which zoxide > /dev/null 2>&1 ; then # shellcheck disable=SC2139 alias z="$(which zoxide)" fi + diff --git a/dot_config/alacritty.yml b/dot_config/alacritty.yml new file mode 100644 index 0000000..46e9683 --- /dev/null +++ b/dot_config/alacritty.yml @@ -0,0 +1,939 @@ +# Configuration for Alacritty, the GPU enhanced terminal emulator. + +# Import additional configuration files +# +# Imports are loaded in order, skipping all missing files, with the importing +# file being loaded last. If a field is already present in a previous import, it +# will be replaced. +# +# All imports must either be absolute paths starting with `/`, or paths relative +# to the user's home directory starting with `~/`. +#import: +# - /path/to/alacritty.yml + +# Any items in the `env` entry below will be added as +# environment variables. Some entries may override variables +# set by alacritty itself. +env: + # TERM variable + # + # This value is used to set the `$TERM` environment variable for + # each instance of Alacritty. If it is not present, alacritty will + # check the local terminfo database and use `alacritty` if it is + # available, otherwise `xterm-256color` is used. + TERM: xterm-256color + +window: + # Window dimensions (changes require restart) + # + # Number of lines/columns (not pixels) in the terminal. The number of columns + # must be at least `2`, while using a value of `0` for columns and lines will + # fall back to the window manager's recommended size. + dimensions: + columns: 120 + lines: 35 + + # Window position (changes require restart) + # + # Specified in number of pixels. + # If the position is not set, the window manager will handle the placement. + #position: + # x: 0 + # y: 0 + + # Window padding (changes require restart) + # + # Blank space added around the window in pixels. This padding is scaled + # by DPI and the specified value is always added at both opposing sides. + #padding: + # x: 0 + # y: 0 + + # Spread additional padding evenly around the terminal content. + #dynamic_padding: false + + # Window decorations + # + # Values for `decorations`: + # - full: Borders and title bar + # - none: Neither borders nor title bar + # + # Values for `decorations` (macOS only): + # - transparent: Title bar, transparent background and title bar buttons + # - buttonless: Title bar, transparent background and no title bar buttons + #decorations: full + + # Startup Mode (changes require restart) + # + # Values for `startup_mode`: + # - Windowed + # - Maximized + # - Fullscreen + # + # Values for `startup_mode` (macOS only): + # - SimpleFullscreen + #startup_mode: Windowed + + # Window title + #title: Alacritty + + # Allow terminal applications to change Alacritty's window title. + #dynamic_title: true + + # Window class (Linux/BSD only): + #class: + # Application instance name + #instance: Alacritty + # General application class + #general: Alacritty + + # GTK theme variant (Linux/BSD only) + # + # Override the variant of the GTK theme. Commonly supported values are `dark` + # and `light`. Set this to `None` to use the default theme variant. + #gtk_theme_variant: None + + # Background opacity + # + # Window opacity as a floating point number from `0.0` to `1.0`. + # The value `0.0` is completely transparent and `1.0` is opaque. + opacity: 0.90 + +#scrolling: + # Maximum number of lines in the scrollback buffer. + # Specifying '0' will disable scrolling. + #history: 10000 + + # Scrolling distance multiplier. + #multiplier: 3 + +# Font configuration +font: + # Normal (roman) font face + normal: + # Font family + # + # Default: + # - (macOS) Menlo + # - (Linux/BSD) monospace + # - (Windows) Consolas + family: Operator Mono + + # The `style` can be specified to pick a specific face. + style: Book + + # Bold font face + #bold: + # Font family + # + # If the bold family is not specified, it will fall back to the + # value specified for the normal font. + #family: monospace + + # The `style` can be specified to pick a specific face. + #style: Bold + + # Italic font face + #italic: + # Font family + # + # If the italic family is not specified, it will fall back to the + # value specified for the normal font. + #family: monospace + + # The `style` can be specified to pick a specific face. + #style: Italic + + # Bold italic font face + #bold_italic: + # Font family + # + # If the bold italic family is not specified, it will fall back to the + # value specified for the normal font. + #family: monospace + + # The `style` can be specified to pick a specific face. + #style: Bold Italic + + # Point size + size: 14.0 + + # Offset is the extra space around each character. `offset.y` can be thought + # of as modifying the line spacing, and `offset.x` as modifying the letter + # spacing. + offset: + x: 0 + y: -4 + + # Glyph offset determines the locations of the glyphs within their cells with + # the default being at the bottom. Increasing `x` moves the glyph to the + # right, increasing `y` moves the glyph upward. + #glyph_offset: + # x: 0 + # y: 0 + + # Thin stroke font rendering (macOS only) + # + # Thin strokes are suitable for retina displays, but for non-retina screens + # it is recommended to set `use_thin_strokes` to `false`. + #use_thin_strokes: true + +# If `true`, bold text is drawn using the bright color variants. +#draw_bold_text_with_bright_colors: false + +# Base16 Outrun Dark 256 - alacritty color config +# Hugo Delahousse (http://github.com/hugodelahousse/) +colors: + # Default colors + primary: + background: '0x00002a' + foreground: '0xd0d0fa' + + # Colors the cursor will use if `custom_cursor_colors` is true + cursor: + text: '0x00002a' + cursor: '0xd0d0fa' + + # Normal colors + normal: + black: '0x00002a' + red: '0xff4242' + green: '0x59f176' + yellow: '0xf3e877' + blue: '0x66b0ff' + magenta: '0xf10596' + cyan: '0x0ef0f0' + white: '0xd0d0fa' + + # Bright colors + bright: + black: '0x50507a' + red: '0xff4242' + green: '0x59f176' + yellow: '0xf3e877' + blue: '0x66b0ff' + magenta: '0xf10596' + cyan: '0x0ef0f0' + white: '0xf5f5ff' + + indexed_colors: + - { index: 16, color: '0xfc8d28' } + - { index: 17, color: '0xf003ef' } + - { index: 18, color: '0x20204a' } + - { index: 19, color: '0x30305a' } + - { index: 20, color: '0xb0b0da' } + - { index: 21, color: '0xe0e0ff' } + +# Base16 Monokai 256 - alacritty color config +# Wimer Hazenberg (http://www.monokai.nl) +colors: + # Default colors + primary: + background: '0x272822' + foreground: '0xf8f8f2' + + # Colors the cursor will use if `custom_cursor_colors` is true + cursor: + text: '0x272822' + cursor: '0xf8f8f2' + + # Normal colors + normal: + black: '0x272822' + red: '0xf92672' + green: '0xa6e22e' + yellow: '0xf4bf75' + blue: '0x66d9ef' + magenta: '0xae81ff' + cyan: '0xa1efe4' + white: '0xf8f8f2' + + # Bright colors + bright: + black: '0x75715e' + red: '0xf92672' + green: '0xa6e22e' + yellow: '0xf4bf75' + blue: '0x66d9ef' + magenta: '0xae81ff' + cyan: '0xa1efe4' + white: '0xf9f8f5' + + indexed_colors: + - { index: 16, color: '0xfd971f' } + - { index: 17, color: '0xcc6633' } + - { index: 18, color: '0x383830' } + - { index: 19, color: '0x49483e' } + - { index: 20, color: '0xa59f85' } + - { index: 21, color: '0xf5f4f1' } + +# Colors (Tomorrow Night) +#colors: + # Default colors + #primary: + # background: '#1d1f21' + # foreground: '#c5c8c6' + + # Bright and dim foreground colors + # + # The dimmed foreground color is calculated automatically if it is not + # present. If the bright foreground color is not set, or + # `draw_bold_text_with_bright_colors` is `false`, the normal foreground + # color will be used. + #dim_foreground: '#828482' + #bright_foreground: '#eaeaea' + + # Cursor colors + # + # Colors which should be used to draw the terminal cursor. + # + # Allowed values are CellForeground/CellBackground, which reference the + # affected cell, or hexadecimal colors like #ff00ff. + #cursor: + # text: CellBackground + # cursor: CellForeground + + # Vi mode cursor colors + # + # Colors for the cursor when the vi mode is active. + # + # Allowed values are CellForeground/CellBackground, which reference the + # affected cell, or hexadecimal colors like #ff00ff. + #vi_mode_cursor: + # text: CellBackground + # cursor: CellForeground + + # Search colors + # + # Colors used for the search bar and match highlighting. + #search: + # Allowed values are CellForeground/CellBackground, which reference the + # affected cell, or hexadecimal colors like #ff00ff. + #matches: + # foreground: '#000000' + # background: '#ffffff' + #focused_match: + # foreground: '#ffffff' + # background: '#000000' + + #bar: + # background: '#c5c8c6' + # foreground: '#1d1f21' + + # Keyboard regex hints + #hints: + # First character in the hint label + # + # Allowed values are CellForeground/CellBackground, which reference the + # affected cell, or hexadecimal colors like #ff00ff. + #start: + # foreground: '#1d1f21' + # background: '#e9ff5e' + + # All characters after the first one in the hint label + # + # Allowed values are CellForeground/CellBackground, which reference the + # affected cell, or hexadecimal colors like #ff00ff. + #end: + # foreground: '#e9ff5e' + # background: '#1d1f21' + + # Line indicator + # + # Color used for the indicator displaying the position in history during + # search and vi mode. + # + # By default, these will use the opposing primary color. + #line_indicator: + # foreground: None + # background: None + + # Selection colors + # + # Colors which should be used to draw the selection area. + # + # Allowed values are CellForeground/CellBackground, which reference the + # affected cell, or hexadecimal colors like #ff00ff. + #selection: + # text: CellBackground + # background: CellForeground + + # Normal colors + #normal: + # black: '#1d1f21' + # red: '#cc6666' + # green: '#b5bd68' + # yellow: '#f0c674' + # blue: '#81a2be' + # magenta: '#b294bb' + # cyan: '#8abeb7' + # white: '#c5c8c6' + + # Bright colors + #bright: + # black: '#666666' + # red: '#d54e53' + # green: '#b9ca4a' + # yellow: '#e7c547' + # blue: '#7aa6da' + # magenta: '#c397d8' + # cyan: '#70c0b1' + # white: '#eaeaea' + + # Dim colors + # + # If the dim colors are not set, they will be calculated automatically based + # on the `normal` colors. + #dim: + # black: '#131415' + # red: '#864343' + # green: '#777c44' + # yellow: '#9e824c' + # blue: '#556a7d' + # magenta: '#75617b' + # cyan: '#5b7d78' + # white: '#828482' + + # Indexed Colors + # + # The indexed colors include all colors from 16 to 256. + # When these are not set, they're filled with sensible defaults. + # + # Example: + # `- { index: 16, color: '#ff00ff' }` + # + #indexed_colors: [] + +# Bell +# +# The bell is rung every time the BEL control character is received. +#bell: + # Visual Bell Animation + # + # Animation effect for flashing the screen when the visual bell is rung. + # + # Values for `animation`: + # - Ease + # - EaseOut + # - EaseOutSine + # - EaseOutQuad + # - EaseOutCubic + # - EaseOutQuart + # - EaseOutQuint + # - EaseOutExpo + # - EaseOutCirc + # - Linear + #animation: EaseOutExpo + + # Duration of the visual bell flash in milliseconds. A `duration` of `0` will + # disable the visual bell animation. + #duration: 0 + + # Visual bell animation color. + #color: '#ffffff' + + # Bell Command + # + # This program is executed whenever the bell is rung. + # + # When set to `command: None`, no command will be executed. + # + # Example: + # command: + # program: notify-send + # args: ["Hello, World!"] + # + #command: None + +#selection: + # This string contains all characters that are used as separators for + # "semantic words" in Alacritty. + #semantic_escape_chars: ",│`|:\"' ()[]{}<>\t" + + # When set to `true`, selected text will be copied to the primary clipboard. + #save_to_clipboard: false + +cursor: + # Cursor style + style: + # Cursor shape + # + # Values for `shape`: + # - ▇ Block + # - _ Underline + # - | Beam + shape: Block + + # Cursor blinking state + # + # Values for `blinking`: + # - Never: Prevent the cursor from ever blinking + # - Off: Disable blinking by default + # - On: Enable blinking by default + # - Always: Force the cursor to always blink + blinking: On + + # Vi mode cursor style + # + # If the vi mode cursor style is `None` or not specified, it will fall back to + # the style of the active value of the normal cursor. + # + # See `cursor.style` for available options. + #vi_mode_style: None + + # Cursor blinking interval in milliseconds. + #blink_interval: 750 + + # If this is `true`, the cursor will be rendered as a hollow box when the + # window is not focused. + #unfocused_hollow: true + + # Thickness of the cursor relative to the cell width as floating point number + # from `0.0` to `1.0`. + #thickness: 0.15 + +# Live config reload (changes require restart) +live_config_reload: true + +# Shell +# +# You can set `shell.program` to the path of your favorite shell, e.g. +# `/bin/fish`. Entries in `shell.args` are passed unmodified as arguments to the +# shell. +# +# Default: +# - (macOS) /bin/bash --login +# - (Linux/BSD) user login shell +# - (Windows) powershell +#shell: +# program: /bin/bash +# args: +# - --login + +# Startup directory +# +# Directory the shell is started in. If this is unset, or `None`, the working +# directory of the parent process will be used. +#working_directory: None + +# Send ESC (\x1b) before characters when alt is pressed. +#alt_send_esc: true + +#mouse: + # Click settings + # + # The `double_click` and `triple_click` settings control the time + # alacritty should wait for accepting multiple clicks as one double + # or triple click. + #double_click: { threshold: 300 } + #triple_click: { threshold: 300 } + + # If this is `true`, the cursor is temporarily hidden when typing. + #hide_when_typing: false + +# Regex hints +# +# Terminal hints can be used to find text in the visible part of the terminal +# and pipe it to other applications. +#hints: + # Keys used for the hint labels. + #alphabet: "jfkdls;ahgurieowpq" + + # List with all available hints + # + # Each hint must have a `regex` and either an `action` or a `command` field. + # The fields `mouse`, `binding` and `post_processing` are optional. + # + # The fields `command`, `binding.key`, `binding.mods`, `binding.mode` and + # `mouse.mods` accept the same values as they do in the `key_bindings` section. + # + # The `mouse.enabled` field controls if the hint should be underlined while + # the mouse with all `mouse.mods` keys held or the vi mode cursor is above it. + # + # If the `post_processing` field is set to `true`, heuristics will be used to + # shorten the match if there are characters likely not to be part of the hint + # (e.g. a trailing `.`). This is most useful for URIs. + # + # Values for `action`: + # - Copy + # Copy the hint's text to the clipboard. + # - Paste + # Paste the hint's text to the terminal or search. + # - Select + # Select the hint's text. + # - MoveViModeCursor + # Move the vi mode cursor to the beginning of the hint. + #enabled: + # - regex: "(ipfs:|ipns:|magnet:|mailto:|gemini:|gopher:|https:|http:|news:|file:|git:|ssh:|ftp:)\ + # [^\u0000-\u001F\u007F-\u009F<>\"\\s{-}\\^⟨⟩`]+" + # command: xdg-open + # post_processing: true + # mouse: + # enabled: true + # mods: None + # binding: + # key: U + # mods: Control|Shift + +# Mouse bindings +# +# Mouse bindings are specified as a list of objects, much like the key +# bindings further below. +# +# To trigger mouse bindings when an application running within Alacritty +# captures the mouse, the `Shift` modifier is automatically added as a +# requirement. +# +# Each mouse binding will specify a: +# +# - `mouse`: +# +# - Middle +# - Left +# - Right +# - Numeric identifier such as `5` +# +# - `action` (see key bindings) +# +# And optionally: +# +# - `mods` (see key bindings) +#mouse_bindings: +# - { mouse: Middle, action: PasteSelection } + +# Key bindings +# +# Key bindings are specified as a list of objects. For example, this is the +# default paste binding: +# +# `- { key: V, mods: Control|Shift, action: Paste }` +# +# Each key binding will specify a: +# +# - `key`: Identifier of the key pressed +# +# - A-Z +# - F1-F24 +# - Key0-Key9 +# +# A full list with available key codes can be found here: +# https://docs.rs/glutin/*/glutin/event/enum.VirtualKeyCode.html#variants +# +# Instead of using the name of the keys, the `key` field also supports using +# the scancode of the desired key. Scancodes have to be specified as a +# decimal number. This command will allow you to display the hex scancodes +# for certain keys: +# +# `showkey --scancodes`. +# +# Then exactly one of: +# +# - `chars`: Send a byte sequence to the running application +# +# The `chars` field writes the specified string to the terminal. This makes +# it possible to pass escape sequences. To find escape codes for bindings +# like `PageUp` (`"\x1b[5~"`), you can run the command `showkey -a` outside +# of tmux. Note that applications use terminfo to map escape sequences back +# to keys. It is therefore required to update the terminfo when changing an +# escape sequence. +# +# - `action`: Execute a predefined action +# +# - ToggleViMode +# - SearchForward +# Start searching toward the right of the search origin. +# - SearchBackward +# Start searching toward the left of the search origin. +# - Copy +# - Paste +# - IncreaseFontSize +# - DecreaseFontSize +# - ResetFontSize +# - ScrollPageUp +# - ScrollPageDown +# - ScrollHalfPageUp +# - ScrollHalfPageDown +# - ScrollLineUp +# - ScrollLineDown +# - ScrollToTop +# - ScrollToBottom +# - ClearHistory +# Remove the terminal's scrollback history. +# - Hide +# Hide the Alacritty window. +# - Minimize +# Minimize the Alacritty window. +# - Quit +# Quit Alacritty. +# - ToggleFullscreen +# - SpawnNewInstance +# Spawn a new instance of Alacritty. +# - ClearLogNotice +# Clear Alacritty's UI warning and error notice. +# - ClearSelection +# Remove the active selection. +# - ReceiveChar +# - None +# +# - Vi mode exclusive actions: +# +# - Open +# Perform the action of the first matching hint under the vi mode cursor +# with `mouse.enabled` set to `true`. +# - ToggleNormalSelection +# - ToggleLineSelection +# - ToggleBlockSelection +# - ToggleSemanticSelection +# Toggle semantic selection based on `selection.semantic_escape_chars`. +# +# - Vi mode exclusive cursor motion actions: +# +# - Up +# One line up. +# - Down +# One line down. +# - Left +# One character left. +# - Right +# One character right. +# - First +# First column, or beginning of the line when already at the first column. +# - Last +# Last column, or beginning of the line when already at the last column. +# - FirstOccupied +# First non-empty cell in this terminal row, or first non-empty cell of +# the line when already at the first cell of the row. +# - High +# Top of the screen. +# - Middle +# Center of the screen. +# - Low +# Bottom of the screen. +# - SemanticLeft +# Start of the previous semantically separated word. +# - SemanticRight +# Start of the next semantically separated word. +# - SemanticLeftEnd +# End of the previous semantically separated word. +# - SemanticRightEnd +# End of the next semantically separated word. +# - WordLeft +# Start of the previous whitespace separated word. +# - WordRight +# Start of the next whitespace separated word. +# - WordLeftEnd +# End of the previous whitespace separated word. +# - WordRightEnd +# End of the next whitespace separated word. +# - Bracket +# Character matching the bracket at the cursor's location. +# - SearchNext +# Beginning of the next match. +# - SearchPrevious +# Beginning of the previous match. +# - SearchStart +# Start of the match to the left of the vi mode cursor. +# - SearchEnd +# End of the match to the right of the vi mode cursor. +# +# - Search mode exclusive actions: +# - SearchFocusNext +# Move the focus to the next search match. +# - SearchFocusPrevious +# Move the focus to the previous search match. +# - SearchConfirm +# - SearchCancel +# - SearchClear +# Reset the search regex. +# - SearchDeleteWord +# Delete the last word in the search regex. +# - SearchHistoryPrevious +# Go to the previous regex in the search history. +# - SearchHistoryNext +# Go to the next regex in the search history. +# +# - macOS exclusive actions: +# - ToggleSimpleFullscreen +# Enter fullscreen without occupying another space. +# +# - Linux/BSD exclusive actions: +# +# - CopySelection +# Copy from the selection buffer. +# - PasteSelection +# Paste from the selection buffer. +# +# - `command`: Fork and execute a specified command plus arguments +# +# The `command` field must be a map containing a `program` string and an +# `args` array of command line parameter strings. For example: +# `{ program: "alacritty", args: ["-e", "vttest"] }` +# +# And optionally: +# +# - `mods`: Key modifiers to filter binding actions +# +# - Command +# - Control +# - Option +# - Super +# - Shift +# - Alt +# +# Multiple `mods` can be combined using `|` like this: +# `mods: Control|Shift`. +# Whitespace and capitalization are relevant and must match the example. +# +# - `mode`: Indicate a binding for only specific terminal reported modes +# +# This is mainly used to send applications the correct escape sequences +# when in different modes. +# +# - AppCursor +# - AppKeypad +# - Search +# - Alt +# - Vi +# +# A `~` operator can be used before a mode to apply the binding whenever +# the mode is *not* active, e.g. `~Alt`. +# +# Bindings are always filled by default, but will be replaced when a new +# binding with the same triggers is defined. To unset a default binding, it can +# be mapped to the `ReceiveChar` action. Alternatively, you can use `None` for +# a no-op if you do not wish to receive input characters for that binding. +# +# If the same trigger is assigned to multiple actions, all of them are executed +# in the order they were defined in. +key_bindings: + - { key: N, mods: Shift|Control, action: SpawnNewInstance } + #- { key: Paste, action: Paste } + #- { key: Copy, action: Copy } + #- { key: L, mods: Control, action: ClearLogNotice } + #- { key: L, mods: Control, mode: ~Vi|~Search, chars: "\x0c" } + #- { key: PageUp, mods: Shift, mode: ~Alt, action: ScrollPageUp, } + #- { key: PageDown, mods: Shift, mode: ~Alt, action: ScrollPageDown } + #- { key: Home, mods: Shift, mode: ~Alt, action: ScrollToTop, } + #- { key: End, mods: Shift, mode: ~Alt, action: ScrollToBottom } + + # Vi Mode + #- { key: Space, mods: Shift|Control, mode: ~Search, action: ToggleViMode } + #- { key: Space, mods: Shift|Control, mode: Vi|~Search, action: ScrollToBottom } + #- { key: Escape, mode: Vi|~Search, action: ClearSelection } + #- { key: I, mode: Vi|~Search, action: ToggleViMode } + #- { key: I, mode: Vi|~Search, action: ScrollToBottom } + #- { key: C, mods: Control, mode: Vi|~Search, action: ToggleViMode } + #- { key: Y, mods: Control, mode: Vi|~Search, action: ScrollLineUp } + #- { key: E, mods: Control, mode: Vi|~Search, action: ScrollLineDown } + #- { key: G, mode: Vi|~Search, action: ScrollToTop } + #- { key: G, mods: Shift, mode: Vi|~Search, action: ScrollToBottom } + #- { key: B, mods: Control, mode: Vi|~Search, action: ScrollPageUp } + #- { key: F, mods: Control, mode: Vi|~Search, action: ScrollPageDown } + #- { key: U, mods: Control, mode: Vi|~Search, action: ScrollHalfPageUp } + #- { key: D, mods: Control, mode: Vi|~Search, action: ScrollHalfPageDown } + #- { key: Y, mode: Vi|~Search, action: Copy } + #- { key: Y, mode: Vi|~Search, action: ClearSelection } + #- { key: Copy, mode: Vi|~Search, action: ClearSelection } + #- { key: V, mode: Vi|~Search, action: ToggleNormalSelection } + #- { key: V, mods: Shift, mode: Vi|~Search, action: ToggleLineSelection } + #- { key: V, mods: Control, mode: Vi|~Search, action: ToggleBlockSelection } + #- { key: V, mods: Alt, mode: Vi|~Search, action: ToggleSemanticSelection } + #- { key: Return, mode: Vi|~Search, action: Open } + #- { key: K, mode: Vi|~Search, action: Up } + #- { key: J, mode: Vi|~Search, action: Down } + #- { key: H, mode: Vi|~Search, action: Left } + #- { key: L, mode: Vi|~Search, action: Right } + #- { key: Up, mode: Vi|~Search, action: Up } + #- { key: Down, mode: Vi|~Search, action: Down } + #- { key: Left, mode: Vi|~Search, action: Left } + #- { key: Right, mode: Vi|~Search, action: Right } + #- { key: Key0, mode: Vi|~Search, action: First } + #- { key: Key4, mods: Shift, mode: Vi|~Search, action: Last } + #- { key: Key6, mods: Shift, mode: Vi|~Search, action: FirstOccupied } + #- { key: H, mods: Shift, mode: Vi|~Search, action: High } + #- { key: M, mods: Shift, mode: Vi|~Search, action: Middle } + #- { key: L, mods: Shift, mode: Vi|~Search, action: Low } + #- { key: B, mode: Vi|~Search, action: SemanticLeft } + #- { key: W, mode: Vi|~Search, action: SemanticRight } + #- { key: E, mode: Vi|~Search, action: SemanticRightEnd } + #- { key: B, mods: Shift, mode: Vi|~Search, action: WordLeft } + #- { key: W, mods: Shift, mode: Vi|~Search, action: WordRight } + #- { key: E, mods: Shift, mode: Vi|~Search, action: WordRightEnd } + #- { key: Key5, mods: Shift, mode: Vi|~Search, action: Bracket } + #- { key: Slash, mode: Vi|~Search, action: SearchForward } + #- { key: Slash, mods: Shift, mode: Vi|~Search, action: SearchBackward } + #- { key: N, mode: Vi|~Search, action: SearchNext } + #- { key: N, mods: Shift, mode: Vi|~Search, action: SearchPrevious } + + # Search Mode + #- { key: Return, mode: Search|Vi, action: SearchConfirm } + #- { key: Escape, mode: Search, action: SearchCancel } + #- { key: C, mods: Control, mode: Search, action: SearchCancel } + #- { key: U, mods: Control, mode: Search, action: SearchClear } + #- { key: W, mods: Control, mode: Search, action: SearchDeleteWord } + #- { key: P, mods: Control, mode: Search, action: SearchHistoryPrevious } + #- { key: N, mods: Control, mode: Search, action: SearchHistoryNext } + #- { key: Up, mode: Search, action: SearchHistoryPrevious } + #- { key: Down, mode: Search, action: SearchHistoryNext } + #- { key: Return, mode: Search|~Vi, action: SearchFocusNext } + #- { key: Return, mods: Shift, mode: Search|~Vi, action: SearchFocusPrevious } + + # (Windows, Linux, and BSD only) + #- { key: V, mods: Control|Shift, mode: ~Vi, action: Paste } + #- { key: C, mods: Control|Shift, action: Copy } + #- { key: F, mods: Control|Shift, mode: ~Search, action: SearchForward } + #- { key: B, mods: Control|Shift, mode: ~Search, action: SearchBackward } + #- { key: C, mods: Control|Shift, mode: Vi|~Search, action: ClearSelection } + #- { key: Insert, mods: Shift, action: PasteSelection } + #- { key: Key0, mods: Control, action: ResetFontSize } + #- { key: Equals, mods: Control, action: IncreaseFontSize } + #- { key: Plus, mods: Control, action: IncreaseFontSize } + #- { key: NumpadAdd, mods: Control, action: IncreaseFontSize } + #- { key: Minus, mods: Control, action: DecreaseFontSize } + #- { key: NumpadSubtract, mods: Control, action: DecreaseFontSize } + + # (Windows only) + #- { key: Return, mods: Alt, action: ToggleFullscreen } + + # (macOS only) + #- { key: K, mods: Command, mode: ~Vi|~Search, chars: "\x0c" } + #- { key: K, mods: Command, mode: ~Vi|~Search, action: ClearHistory } + #- { key: Key0, mods: Command, action: ResetFontSize } + #- { key: Equals, mods: Command, action: IncreaseFontSize } + #- { key: Plus, mods: Command, action: IncreaseFontSize } + #- { key: NumpadAdd, mods: Command, action: IncreaseFontSize } + #- { key: Minus, mods: Command, action: DecreaseFontSize } + #- { key: NumpadSubtract, mods: Command, action: DecreaseFontSize } + #- { key: V, mods: Command, action: Paste } + #- { key: C, mods: Command, action: Copy } + #- { key: C, mods: Command, mode: Vi|~Search, action: ClearSelection } + #- { key: H, mods: Command, action: Hide } + #- { key: H, mods: Command|Alt, action: HideOtherApplications } + #- { key: M, mods: Command, action: Minimize } + #- { key: Q, mods: Command, action: Quit } + #- { key: W, mods: Command, action: Quit } + #- { key: N, mods: Command, action: SpawnNewInstance } + #- { key: F, mods: Command|Control, action: ToggleFullscreen } + #- { key: F, mods: Command, mode: ~Search, action: SearchForward } + #- { key: B, mods: Command, mode: ~Search, action: SearchBackward } + +#debug: + # Display the time it takes to redraw each frame. + #render_timer: false + + # Keep the log file after quitting Alacritty. + #persistent_logging: false + + # Log level + # + # Values for `log_level`: + # - Off + # - Error + # - Warn + # - Info + # - Debug + # - Trace + #log_level: Warn + + # Print all received window events. + #print_events: false diff --git a/dot_config/bash/aliases.sh b/dot_config/bash/aliases.sh new file mode 100644 index 0000000..975f7da --- /dev/null +++ b/dot_config/bash/aliases.sh @@ -0,0 +1,13 @@ +if which exa > /dev/null 2>&1 ; then + alias ls="exa" +else + alias ls="ls --color=auto" +fi +alias grep='grep --colour=auto' +alias egrep='egrep --colour=auto' +alias fgrep='fgrep --colour=auto' + +shopt -s expand_aliases + +alias m4b-tool='docker run -it --rm -u $(id -u):$(id -g) -v "$(pwd)":/mnt m4b-tool' +alias gcurl='curl --header "Authorization: Bearer $(gcloud auth print-identity-token)"' diff --git a/dot_config/bash/asdf.sh b/dot_config/bash/asdf.sh new file mode 100644 index 0000000..a9754c2 --- /dev/null +++ b/dot_config/bash/asdf.sh @@ -0,0 +1,3 @@ +if [ -f "$HOME/.asdf/asdf.sh" ] ; then + . "$HOME/.asdf/asdf.sh" +fi diff --git a/dot_bash-preexec.sh b/dot_config/bash/bash-preexec.sh similarity index 100% rename from dot_bash-preexec.sh rename to dot_config/bash/bash-preexec.sh diff --git a/private_dot_bashrc.d/bash-completion.sh b/dot_config/bash/bash-setup.sh similarity index 51% rename from private_dot_bashrc.d/bash-completion.sh rename to dot_config/bash/bash-setup.sh index 3d57b0d..a37430e 100644 --- a/private_dot_bashrc.d/bash-completion.sh +++ b/dot_config/bash/bash-setup.sh @@ -1,3 +1,13 @@ +# load system bashrc +for BASHRC in /etc/bashrc /etc/bash.bashrc /etc/bash/bashrc ; do + if [ -f "$BASHRC" ] ; then + # shellcheck source=/dev/null + . "$BASHRC" + fi +done +unset BASHRC + +# load system completions for rc in /etc/bash_completion /usr/local/share/bash-completion/bash_completion /usr/share/bash-completion/bash_completion ; do if [ -f "$rc" ] ; then . "$rc" @@ -15,3 +25,11 @@ fi unset rc complete -cf sudo + +# local paths +if ! [[ "$PATH" =~ $HOME/.local/bin:$HOME/bin: ]] +then + PATH="$HOME/.local/bin:$HOME/bin:$PATH" +fi +export PATH + diff --git a/dot_config/bash/bat.sh b/dot_config/bash/bat.sh new file mode 100644 index 0000000..a0d39fc --- /dev/null +++ b/dot_config/bash/bat.sh @@ -0,0 +1,4 @@ +#export BAT_THEME="Solarized (light)" +export BAT_THEME="Monokai Extended Light" +export MANPAGER="sh -c 'col -bx | bat -l man -p'" + diff --git a/private_dot_bashrc.d/cargo.sh b/dot_config/bash/cargo.sh similarity index 100% rename from private_dot_bashrc.d/cargo.sh rename to dot_config/bash/cargo.sh diff --git a/dot_config/bash/editor.sh b/dot_config/bash/editor.sh new file mode 100644 index 0000000..ddf8b3b --- /dev/null +++ b/dot_config/bash/editor.sh @@ -0,0 +1,8 @@ +EDITOR=vi +if which nvim > /dev/null 2>&1 ; then + EDITOR=nvim; +elif which vim > /dev/null 2>&1 ; then + EDITOR=vim +fi +export EDITOR + diff --git a/private_dot_bashrc.d/git-prompt.sh b/dot_config/bash/git-prompt.sh similarity index 100% rename from private_dot_bashrc.d/git-prompt.sh rename to dot_config/bash/git-prompt.sh diff --git a/private_dot_bashrc.d/gitea.sh.tmpl b/dot_config/bash/gitea.sh.tmpl similarity index 100% rename from private_dot_bashrc.d/gitea.sh.tmpl rename to dot_config/bash/gitea.sh.tmpl diff --git a/private_dot_bashrc.d/go-setup.sh b/dot_config/bash/go-setup.sh similarity index 100% rename from private_dot_bashrc.d/go-setup.sh rename to dot_config/bash/go-setup.sh diff --git a/dot_config/bash/history.sh b/dot_config/bash/history.sh new file mode 100644 index 0000000..1bad996 --- /dev/null +++ b/dot_config/bash/history.sh @@ -0,0 +1,57 @@ +if which atuin > /dev/null 2>&1 ; then + ATUIN_SESSION=$(atuin uuid) + export ATUIN_SESSION + + _atuin_preexec() { + id=$(atuin history start "$1") + export ATUIN_HISTORY_ID="$id" + } + + _atuin_precmd() { + local EXIT="$?" + + [[ -z "${ATUIN_HISTORY_ID}" ]] && return + + (RUST_LOG=error atuin history end "$ATUIN_HISTORY_ID" --exit $EXIT &) > /dev/null 2>&1 + } + + + __atuin_history () + { + tput rmkx + HISTORY="$(RUST_LOG=error atuin search -i "$BUFFER" 3>&1 1>&2 2>&3)" + tput smkx + + READLINE_LINE=${HISTORY} + READLINE_POINT=${#READLINE_LINE} + } + + + preexec_functions+=(_atuin_preexec) + precmd_functions+=(_atuin_precmd) + + if [[ -z $ATUIN_NOBIND ]]; then + bind -x '"\C-r": __atuin_history' + fi +else + # don't put duplicate lines or lines starting with space in the history. + # See bash(1) for more options + HISTCONTROL=ignoreboth + + ## + ## history: http://mywiki.wooledge.org/BashFAQ/088 + ## + + # Big history + HISTFILESIZE=10000 + HISTSIZE=10000 + HISTTIMEFORMAT="%Y-%m-%d %H:%M:%S " + + # history -a causes an immediate write of all new history lines + # (instead of upon shell exit) + PROMPT_COMMAND="history -a" + + # histappend which causes all new history lines to be appended, and ensures + # that multiple logins do not overwrite each other's history + shopt -s histappend +fi diff --git a/dot_config/bash/just.bash b/dot_config/bash/just.bash new file mode 100644 index 0000000..8ef93b6 --- /dev/null +++ b/dot_config/bash/just.bash @@ -0,0 +1,123 @@ +_just() { + local i cur prev opts cmds + COMPREPLY=() + cur="${COMP_WORDS[COMP_CWORD]}" + prev="${COMP_WORDS[COMP_CWORD-1]}" + cmd="" + opts="" + + for i in ${COMP_WORDS[@]} + do + case "${i}" in + "$1") + cmd="just" + ;; + + *) + ;; + esac + done + + case "${cmd}" in + just) + opts=" -q -u -v -e -l -h -V -f -d -c -s --check --dry-run --highlight --no-dotenv --no-highlight --quiet --shell-command --clear-shell-args --unsorted --unstable --verbose --changelog --choose --dump --edit --evaluate --fmt --init --list --summary --variables --help --version --chooser --color --dump-format --list-heading --list-prefix --justfile --set --shell --shell-arg --working-directory --command --completions --show --dotenv-filename --dotenv-path ... " + if [[ ${cur} == -* ]] ; then + COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") ) + return 0 + elif [[ ${COMP_CWORD} -eq 1 ]]; then + local recipes=$(just --summary --color never 2> /dev/null) + if [[ $? -eq 0 ]]; then + COMPREPLY=( $(compgen -W "${recipes}" -- "${cur}") ) + return 0 + fi + fi + case "${prev}" in + + --chooser) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --color) + COMPREPLY=($(compgen -W "auto always never" -- "${cur}")) + return 0 + ;; + --dump-format) + COMPREPLY=($(compgen -W "just json" -- "${cur}")) + return 0 + ;; + --list-heading) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --list-prefix) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --justfile) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + -f) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --set) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --shell) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --shell-arg) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --working-directory) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + -d) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --command) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + -c) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --completions) + COMPREPLY=($(compgen -W "zsh bash fish powershell elvish" -- "${cur}")) + return 0 + ;; + --show) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + -s) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --dotenv-filename) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + --dotenv-path) + COMPREPLY=($(compgen -f "${cur}")) + return 0 + ;; + *) + COMPREPLY=() + ;; + esac + COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") ) + return 0 + ;; + + esac +} + +complete -F _just -o bashdefault -o default just diff --git a/dot_config/bash/lscolors.sh b/dot_config/bash/lscolors.sh new file mode 100644 index 0000000..f82f188 --- /dev/null +++ b/dot_config/bash/lscolors.sh @@ -0,0 +1 @@ +export LS_COLORS="su=0:ca=0:*~=0;38;2;102;102;102:mh=0:do=0;38;2;0;0;0;48;2;255;106;193:pi=0;38;2;0;0;0;48;2;64;120;242:tw=0:sg=0:ln=0;38;2;255;106;193:ex=1;38;2;228;86;73:ow=0:mi=0;38;2;0;0;0;48;2;228;86;73:cd=0;38;2;255;106;193;48;2;51;51;51:rs=0:fi=0:bd=0;38;2;1;132;188;48;2;51;51;51:st=0:or=0;38;2;0;0;0;48;2;228;86;73:no=0:di=0;38;2;64;120;242:so=0;38;2;0;0;0;48;2;255;106;193:*.d=0;38;2;80;161;79:*.r=0;38;2;80;161;79:*.p=0;38;2;80;161;79:*.a=1;38;2;228;86;73:*.z=4;38;2;1;132;188:*.c=0;38;2;80;161;79:*.h=0;38;2;80;161;79:*.m=0;38;2;80;161;79:*.t=0;38;2;80;161;79:*.o=0;38;2;102;102;102:*.ex=0;38;2;80;161;79:*.nb=0;38;2;80;161;79:*.td=0;38;2;80;161;79:*.wv=0;38;2;255;106;193:*.ui=0;38;2;193;132;1:*.el=0;38;2;80;161;79:*.md=0;38;2;193;132;1:*.cr=0;38;2;80;161;79:*.mn=0;38;2;80;161;79:*.pm=0;38;2;80;161;79:*.ts=0;38;2;80;161;79:*css=0;38;2;80;161;79:*.di=0;38;2;80;161;79:*.go=0;38;2;80;161;79:*.fs=0;38;2;80;161;79:*.vb=0;38;2;80;161;79:*.rb=0;38;2;80;161;79:*.js=0;38;2;80;161;79:*.ps=0;38;2;228;86;73:*.lo=0;38;2;102;102;102:*.gz=4;38;2;1;132;188:*.py=0;38;2;80;161;79:*.hh=0;38;2;80;161;79:*.7z=4;38;2;1;132;188:*.cp=0;38;2;80;161;79:*.ml=0;38;2;80;161;79:*.kt=0;38;2;80;161;79:*.bz=4;38;2;1;132;188:*.la=0;38;2;102;102;102:*.sh=0;38;2;80;161;79:*.gv=0;38;2;80;161;79:*.ll=0;38;2;80;161;79:*.as=0;38;2;80;161;79:*.ko=1;38;2;228;86;73:*.bc=0;38;2;102;102;102:*.rm=0;38;2;255;106;193:*.jl=0;38;2;80;161;79:*.xz=4;38;2;1;132;188:*.so=1;38;2;228;86;73:*.hs=0;38;2;80;161;79:*.rs=0;38;2;80;161;79:*.cc=0;38;2;80;161;79:*.pp=0;38;2;80;161;79:*.cs=0;38;2;80;161;79:*.pl=0;38;2;80;161;79:*.hi=0;38;2;102;102;102:*.bmp=0;38;2;255;106;193:*TODO=1:*.tgz=4;38;2;1;132;188:*.zip=4;38;2;1;132;188:*.zsh=0;38;2;80;161;79:*.mp4=0;38;2;255;106;193:*.xcf=0;38;2;255;106;193:*.pbm=0;38;2;255;106;193:*.deb=4;38;2;1;132;188:*.inl=0;38;2;80;161;79:*.htc=0;38;2;80;161;79:*.inc=0;38;2;80;161;79:*.htm=0;38;2;193;132;1:*.tbz=4;38;2;1;132;188:*.epp=0;38;2;80;161;79:*.tml=0;38;2;193;132;1:*.cxx=0;38;2;80;161;79:*.ltx=0;38;2;80;161;79:*.ini=0;38;2;193;132;1:*.fls=0;38;2;102;102;102:*.tmp=0;38;2;102;102;102:*.bat=1;38;2;228;86;73:*.sbt=0;38;2;80;161;79:*.txt=0;38;2;193;132;1:*.iso=4;38;2;1;132;188:*.wmv=0;38;2;255;106;193:*.svg=0;38;2;255;106;193:*.swp=0;38;2;102;102;102:*.bag=4;38;2;1;132;188:*.ico=0;38;2;255;106;193:*.bak=0;38;2;102;102;102:*.sxi=0;38;2;228;86;73:*.pps=0;38;2;228;86;73:*.kts=0;38;2;80;161;79:*.mov=0;38;2;255;106;193:*.dmg=4;38;2;1;132;188:*.flv=0;38;2;255;106;193:*.blg=0;38;2;102;102;102:*.fon=0;38;2;255;106;193:*.rar=4;38;2;1;132;188:*.toc=0;38;2;102;102;102:*.rtf=0;38;2;228;86;73:*.log=0;38;2;102;102;102:*.yml=0;38;2;193;132;1:*.bin=4;38;2;1;132;188:*.ppt=0;38;2;228;86;73:*.hpp=0;38;2;80;161;79:*.idx=0;38;2;102;102;102:*.mir=0;38;2;80;161;79:*.pod=0;38;2;80;161;79:*.csx=0;38;2;80;161;79:*.hxx=0;38;2;80;161;79:*.pgm=0;38;2;255;106;193:*.tsx=0;38;2;80;161;79:*.odt=0;38;2;228;86;73:*.ipp=0;38;2;80;161;79:*.bz2=4;38;2;1;132;188:*.xml=0;38;2;193;132;1:*.ics=0;38;2;228;86;73:*.nix=0;38;2;193;132;1:*.pkg=4;38;2;1;132;188:*.dll=1;38;2;228;86;73:*.avi=0;38;2;255;106;193:*.fsi=0;38;2;80;161;79:*.jpg=0;38;2;255;106;193:*.m4a=0;38;2;255;106;193:*.otf=0;38;2;255;106;193:*.fsx=0;38;2;80;161;79:*.awk=0;38;2;80;161;79:*.eps=0;38;2;255;106;193:*.tar=4;38;2;1;132;188:*.swf=0;38;2;255;106;193:*.def=0;38;2;80;161;79:*.rpm=4;38;2;1;132;188:*.zst=4;38;2;1;132;188:*.bsh=0;38;2;80;161;79:*.sxw=0;38;2;228;86;73:*.vim=0;38;2;80;161;79:*.tcl=0;38;2;80;161;79:*.cgi=0;38;2;80;161;79:*.tex=0;38;2;80;161;79:*.pas=0;38;2;80;161;79:*.wma=0;38;2;255;106;193:*.csv=0;38;2;193;132;1:*.mpg=0;38;2;255;106;193:*.sql=0;38;2;80;161;79:*.dpr=0;38;2;80;161;79:*.mp3=0;38;2;255;106;193:*.png=0;38;2;255;106;193:*.ind=0;38;2;102;102;102:*.jar=4;38;2;1;132;188:*.apk=4;38;2;1;132;188:*.mkv=0;38;2;255;106;193:*.pyo=0;38;2;102;102;102:*.php=0;38;2;80;161;79:*.kex=0;38;2;228;86;73:*.ilg=0;38;2;102;102;102:*.bib=0;38;2;193;132;1:*.xlr=0;38;2;228;86;73:*.xls=0;38;2;228;86;73:*.h++=0;38;2;80;161;79:*.asa=0;38;2;80;161;79:*.pyc=0;38;2;102;102;102:*.mli=0;38;2;80;161;79:*.vob=0;38;2;255;106;193:*.pid=0;38;2;102;102;102:*.ppm=0;38;2;255;106;193:*.cpp=0;38;2;80;161;79:*.m4v=0;38;2;255;106;193:*.clj=0;38;2;80;161;79:*.gif=0;38;2;255;106;193:*.doc=0;38;2;228;86;73:*.com=1;38;2;228;86;73:*.vcd=4;38;2;1;132;188:*.exs=0;38;2;80;161;79:*.git=0;38;2;102;102;102:*.bst=0;38;2;193;132;1:*.pro=0;38;2;80;161;79:*.erl=0;38;2;80;161;79:*.img=4;38;2;1;132;188:*.aif=0;38;2;255;106;193:*.arj=4;38;2;1;132;188:*.rst=0;38;2;193;132;1:*.ttf=0;38;2;255;106;193:*.ods=0;38;2;228;86;73:*hgrc=0;38;2;80;161;79:*.aux=0;38;2;102;102;102:*.dox=0;38;2;80;161;79:*.fnt=0;38;2;255;106;193:*.bbl=0;38;2;102;102;102:*.psd=0;38;2;255;106;193:*.xmp=0;38;2;193;132;1:*.mid=0;38;2;255;106;193:*.ogg=0;38;2;255;106;193:*.bcf=0;38;2;102;102;102:*.cfg=0;38;2;193;132;1:*.exe=1;38;2;228;86;73:*.tif=0;38;2;255;106;193:*.dot=0;38;2;80;161;79:*.elm=0;38;2;80;161;79:*.pdf=0;38;2;228;86;73:*.odp=0;38;2;228;86;73:*.lua=0;38;2;80;161;79:*.c++=0;38;2;80;161;79:*.pyd=0;38;2;102;102;102:*.out=0;38;2;102;102;102:*.gvy=0;38;2;80;161;79:*.sty=0;38;2;102;102;102:*.ps1=0;38;2;80;161;79:*.wav=0;38;2;255;106;193:*.lisp=0;38;2;80;161;79:*.epub=0;38;2;228;86;73:*.flac=0;38;2;255;106;193:*.conf=0;38;2;193;132;1:*.toml=0;38;2;193;132;1:*.psd1=0;38;2;80;161;79:*.diff=0;38;2;80;161;79:*.opus=0;38;2;255;106;193:*.lock=0;38;2;102;102;102:*.tiff=0;38;2;255;106;193:*.json=0;38;2;193;132;1:*.fish=0;38;2;80;161;79:*.java=0;38;2;80;161;79:*.psm1=0;38;2;80;161;79:*.dart=0;38;2;80;161;79:*.xlsx=0;38;2;228;86;73:*.orig=0;38;2;102;102;102:*.webm=0;38;2;255;106;193:*.docx=0;38;2;228;86;73:*.jpeg=0;38;2;255;106;193:*.tbz2=4;38;2;1;132;188:*.yaml=0;38;2;193;132;1:*.less=0;38;2;80;161;79:*.purs=0;38;2;80;161;79:*.rlib=0;38;2;102;102;102:*.html=0;38;2;193;132;1:*.bash=0;38;2;80;161;79:*.h264=0;38;2;255;106;193:*.pptx=0;38;2;228;86;73:*.mpeg=0;38;2;255;106;193:*.hgrc=0;38;2;80;161;79:*.make=0;38;2;80;161;79:*.cabal=0;38;2;80;161;79:*.shtml=0;38;2;193;132;1:*README=0;38;2;250;250;250;48;2;193;132;1:*.class=0;38;2;102;102;102:*shadow=0;38;2;193;132;1:*.swift=0;38;2;80;161;79:*.xhtml=0;38;2;193;132;1:*.ipynb=0;38;2;80;161;79:*.cmake=0;38;2;80;161;79:*.cache=0;38;2;102;102;102:*passwd=0;38;2;193;132;1:*.mdown=0;38;2;193;132;1:*.dyn_o=0;38;2;102;102;102:*.scala=0;38;2;80;161;79:*.toast=4;38;2;1;132;188:*.patch=0;38;2;80;161;79:*TODO.md=1:*LICENSE=0;38;2;153;153;153:*.flake8=0;38;2;80;161;79:*.gradle=0;38;2;80;161;79:*.config=0;38;2;193;132;1:*.ignore=0;38;2;80;161;79:*.dyn_hi=0;38;2;102;102;102:*COPYING=0;38;2;153;153;153:*.matlab=0;38;2;80;161;79:*.groovy=0;38;2;80;161;79:*INSTALL=0;38;2;250;250;250;48;2;193;132;1:*setup.py=0;38;2;80;161;79:*TODO.txt=1:*Makefile=0;38;2;80;161;79:*.desktop=0;38;2;193;132;1:*.gemspec=0;38;2;80;161;79:*Doxyfile=0;38;2;80;161;79:*configure=0;38;2;80;161;79:*.DS_Store=0;38;2;102;102;102:*.rgignore=0;38;2;80;161;79:*README.md=0;38;2;250;250;250;48;2;193;132;1:*.fdignore=0;38;2;80;161;79:*.kdevelop=0;38;2;80;161;79:*.cmake.in=0;38;2;80;161;79:*COPYRIGHT=0;38;2;153;153;153:*.markdown=0;38;2;193;132;1:*CODEOWNERS=0;38;2;80;161;79:*.localized=0;38;2;102;102;102:*INSTALL.md=0;38;2;250;250;250;48;2;193;132;1:*Dockerfile=0;38;2;193;132;1:*.scons_opt=0;38;2;102;102;102:*README.txt=0;38;2;250;250;250;48;2;193;132;1:*SConscript=0;38;2;80;161;79:*.gitconfig=0;38;2;80;161;79:*SConstruct=0;38;2;80;161;79:*.gitignore=0;38;2;80;161;79:*.synctex.gz=0;38;2;102;102;102:*INSTALL.txt=0;38;2;250;250;250;48;2;193;132;1:*.gitmodules=0;38;2;80;161;79:*MANIFEST.in=0;38;2;80;161;79:*Makefile.am=0;38;2;80;161;79:*Makefile.in=0;38;2;102;102;102:*LICENSE-MIT=0;38;2;153;153;153:*.travis.yml=0;38;2;80;161;79:*appveyor.yml=0;38;2;80;161;79:*configure.ac=0;38;2;80;161;79:*.applescript=0;38;2;80;161;79:*CONTRIBUTORS=0;38;2;250;250;250;48;2;193;132;1:*.fdb_latexmk=0;38;2;102;102;102:*.clang-format=0;38;2;80;161;79:*CMakeLists.txt=0;38;2;80;161;79:*LICENSE-APACHE=0;38;2;153;153;153:*CMakeCache.txt=0;38;2;102;102;102:*.gitattributes=0;38;2;80;161;79:*CONTRIBUTORS.md=0;38;2;250;250;250;48;2;193;132;1:*requirements.txt=0;38;2;80;161;79:*CONTRIBUTORS.txt=0;38;2;250;250;250;48;2;193;132;1:*.sconsign.dblite=0;38;2;102;102;102:*package-lock.json=0;38;2;102;102;102:*.CFUserTextEncoding=0;38;2;102;102;102" diff --git a/dot_config/bash/nix.sh b/dot_config/bash/nix.sh new file mode 100644 index 0000000..ed99619 --- /dev/null +++ b/dot_config/bash/nix.sh @@ -0,0 +1,3 @@ +if [ -e "$HOME/.nix-profile/etc/profile.d/nix.sh" ]; then + . "$HOME/.nix-profile/etc/profile.d/nix.sh" +fi diff --git a/dot_config/bash/pager.sh b/dot_config/bash/pager.sh new file mode 100644 index 0000000..19986b2 --- /dev/null +++ b/dot_config/bash/pager.sh @@ -0,0 +1,3 @@ +LESS="-R"; export LESS +PAGER=less; export PAGER +DELTA_PAGER=less; export DELTA_PAGER diff --git a/dot_config/bash/puts.sh b/dot_config/bash/puts.sh new file mode 100644 index 0000000..962b1b4 --- /dev/null +++ b/dot_config/bash/puts.sh @@ -0,0 +1,3 @@ +function puts() { + ruby -r date -e "puts($*)" +} diff --git a/private_dot_bashrc.d/shell-prompt.sh b/dot_config/bash/shell-prompt.sh similarity index 89% rename from private_dot_bashrc.d/shell-prompt.sh rename to dot_config/bash/shell-prompt.sh index df8701c..f899efc 100644 --- a/private_dot_bashrc.d/shell-prompt.sh +++ b/dot_config/bash/shell-prompt.sh @@ -1,5 +1,7 @@ if [[ ${EUID} == 0 ]] ; then PS1='\[\033[01;31m\][\h\[\033[01;36m\] \W\[\033[01;31m\]]\$\[\033[00m\] ' +elif which starship > /dev/null 2>&1 ; then + eval "$(starship init bash)" else if type __git_ps1 > /dev/null 2>&1 ; then GIT_PS1_SHOWDIRTYSTATE=1 diff --git a/private_dot_bashrc.d/window.sh b/dot_config/bash/window.sh similarity index 100% rename from private_dot_bashrc.d/window.sh rename to dot_config/bash/window.sh diff --git a/private_dot_bashrc.d/wsl-ssh-agent.sh.tmpl b/dot_config/bash/wsl-ssh-agent.sh.tmpl similarity index 100% rename from private_dot_bashrc.d/wsl-ssh-agent.sh.tmpl rename to dot_config/bash/wsl-ssh-agent.sh.tmpl diff --git a/private_dot_bashrc.d/xhost.sh.tmpl b/dot_config/bash/xhost.sh.tmpl similarity index 100% rename from private_dot_bashrc.d/xhost.sh.tmpl rename to dot_config/bash/xhost.sh.tmpl diff --git a/dot_config/git/delta_gitconfig b/dot_config/git/delta_gitconfig new file mode 100644 index 0000000..295e753 --- /dev/null +++ b/dot_config/git/delta_gitconfig @@ -0,0 +1,298 @@ +# To use these themes, first include this file in your own gitconfig file: +# +# [include] +# path = PATH/TO/delta/themes.gitconfig +# +# Then, in your own gitconfig file, activate the chosen theme, e.g. +# +# [delta] +# features = kingfisher +# +# Please add your own themes to this file, and open a PR. +# +# Instructions: +# +# 1. The name of the theme must be the name of some sort of wild organism: +# mammal, bird, plant, mollusk -- whatever. It can be in any language. +# +# 2. Use `delta --show-config` to list all the style settings that are active in +# your current delta environment, but only include settings in your theme +# that are essential to its appearance. +# +# 3. Include either `dark = true` or `light = true` according to whether it is +# designed for a light or dark terminal background. (This marks a feature as +# a "theme", causing it to be picked up by `delta --show-themes`). +# +# 4. Feel free to include a comment line indicating who is the author of the +# theme. E.g. a link to your github user page. + +[delta "collared-trogon"] + # author: https://github.com/clnoll + commit-decoration-style = bold box ul + dark = true + file-decoration-style = none + file-style = omit + hunk-header-decoration-style = "#022b45" box ul + hunk-header-file-style = "#999999" + hunk-header-line-number-style = bold "#003300" + hunk-header-style = file line-number syntax + line-numbers = true + line-numbers-left-style = "#022b45" + line-numbers-minus-style = "#80002a" + line-numbers-plus-style = "#003300" + line-numbers-right-style = "#022b45" + line-numbers-zero-style = "#999999" + minus-emph-style = normal "#80002a" + minus-style = normal "#330011" + plus-emph-style = syntax "#003300" + plus-style = syntax "#001a00" + syntax-theme = Nord + +[delta "coracias-caudatus"] + # author: https://github.com/clnoll + commit-decoration-style = ol "#7536ff" + commit-style = "#200078" + file-decoration-style = none + file-style = omit + hunk-header-decoration-style = "#cfd6ff" ul + hunk-header-file-style = "#858dff" + hunk-header-line-number-style = "#7536ff" + hunk-header-style = file line-number syntax + light = true + line-numbers = true + line-numbers-left-format = "{nm:>4} ." + line-numbers-left-style = "#e3ab02" + line-numbers-minus-style = "#ff38b6" + line-numbers-plus-style = "#00e0c2" + line-numbers-right-format = "{np:>4} " + line-numbers-right-style = white + line-numbers-zero-style = "#cccccc" + minus-emph-style = bold "#ff3838" "#ffe3f7" + minus-style = "#ff0080" + plus-emph-style = "#008a81" bold "#00ffbf" + plus-style = syntax "#cffff3" + syntax-theme = Github + +[delta "hoopoe"] + # author: https://github.com/dandavison + light = true + pink = "#ffe0e0" + dark-pink = "#ffc0c0" + green = "#d0ffd0" + dark-green = "#a0efa0" + dark-green-2 = "#067a00" + minus-style = normal hoopoe.pink + minus-emph-style = normal hoopoe.dark-pink + minus-non-emph-style = minus-style + plus-style = syntax hoopoe.green + plus-emph-style = syntax hoopoe.dark-green + plus-non-emph-style = plus-style + minus-empty-line-marker-style = minus-style + plus-empty-line-marker-style = plus-style + commit-decoration-style = blue ol + commit-style = raw + file-style = omit + hunk-header-decoration-style = blue box + hunk-header-file-style = red + hunk-header-line-number-style = hoopoe.dark-green-2 + hunk-header-style = file #line-number syntax + syntax-theme = GitHub + zero-style = syntax + +[delta "tangara-chilensis"] + # author: https://github.com/clnoll + commit-decoration-style = bold box ul "#34fd50" + dark = true + file-decoration-style = none + file-style = omit + hunk-header-decoration-style = "#00b494" box ul + hunk-header-file-style = "#999999" + hunk-header-line-number-style = bold "#03a4ff" + hunk-header-style = file line-number syntax + line-numbers = true + line-numbers-left-style = black + line-numbers-minus-style = "#B10036" + line-numbers-plus-style = "#03a4ff" + line-numbers-right-style = black + line-numbers-zero-style = "#999999" + minus-emph-style = normal "#de004e" + minus-style = normal "#990017" + plus-emph-style = syntax "#03a4ff" + plus-style = syntax "#450eff" + side-by-side = true + syntax-theme = Vibrant Sunburst + +[delta "villsau"] + # author: https://github.com/torarnv + dark = true + file-style = omit + hunk-header-decoration-style = omit + hunk-header-file-style = magenta + hunk-header-line-number-style = dim magenta + hunk-header-style = file line-number syntax + line-numbers = false + minus-emph-style = bold red 52 + minus-empty-line-marker-style = normal "#3f0001" + minus-non-emph-style = dim red + minus-style = bold red + plus-emph-style = bold green 22 + plus-empty-line-marker-style = normal "#002800" + plus-non-emph-style = dim green + plus-style = bold green + syntax-theme = OneHalfDark + whitespace-error-style = reverse red + zero-style = dim syntax + +[delta "woolly-mammoth"] + # author: https://github.com/Kr1ss-XD + commit-decoration-style = 232 130 box + commit-style = 232 bold italic 130 + dark = true + file-added-label = [+] + file-copied-label = [C] + file-decoration-style = "#606018" overline + file-modified-label = [M] + file-removed-label = [-] + file-renamed-label = [R] + file-style = 232 bold 184 + hunk-header-decoration-style = none + hunk-header-style = syntax bold italic 237 + line-numbers = true + line-numbers-left-format = "{nm:>1}┊" + line-numbers-left-style = red + line-numbers-minus-style = red italic black + line-numbers-plus-style = green italic black + line-numbers-right-format = "{np:>1}┊" + line-numbers-right-style = green + line-numbers-zero-style = "#545474" italic + minus-emph-style = syntax bold "#780000" + minus-style = syntax "#400000" + plus-emph-style = syntax bold "#007800" + plus-style = syntax "#004000" + syntax-theme = Vibrant Sunburst + whitespace-error-style = "#280050" reverse + zero-style = syntax + blame-format = "{author:<18} ({commit:>7}) ┊{timestamp:^16}┊ " + blame-palette = "#101010 #200020 #002800 #000028 #202000 #280000 #002020 #002800 #202020" + +[delta "calochortus-lyallii"] + # author: https://github.com/manojkarthick + commit-decoration-style = none + dark = true + file-added-label = [+] + file-copied-label = [C] + file-decoration-style = none + file-modified-label = [M] + file-removed-label = [-] + file-renamed-label = [R] + file-style = 232 bold 184 + hunk-header-decoration-style = none + hunk-header-file-style = "#999999" + hunk-header-line-number-style = bold "#03a4ff" + hunk-header-style = file line-number syntax + line-numbers = true + line-numbers-left-style = black + line-numbers-minus-style = "#B10036" + line-numbers-plus-style = "#03a4ff" + line-numbers-right-style = black + line-numbers-zero-style = "#999999" + minus-emph-style = syntax bold "#780000" + minus-style = syntax "#400000" + plus-emph-style = syntax bold "#007800" + plus-style = syntax "#004000" + whitespace-error-style = "#280050" reverse + zero-style = syntax + syntax-theme = Nord + +[delta "mantis-shrimp"] + #author: https://github.com/2kabhishek + dark = true + side-by-side = true + navigate = true + keep-plus-minus-markers = true + hyperlinks = true + file-added-label = [+] + file-copied-label = [==] + file-modified-label = [*] + file-removed-label = [-] + file-renamed-label = [->] + file-style = omit + zero-style = syntax + syntax-theme = Monokai Extended + commit-decoration-style ="#11ce16" box + commit-style = "#ffd21a" bold italic + hunk-header-decoration-style = "#1688f0" box ul + hunk-header-file-style = "#c63bee" ul bold + hunk-header-line-number-style = "#ffd21a" box bold + hunk-header-style = file line-number syntax bold italic + line-numbers = true + line-numbers-left-format = "{nm:>1}|" + line-numbers-left-style = "#1688f0" + line-numbers-minus-style = "#ff0051" bold + line-numbers-plus-style = "#03e57f" bold + line-numbers-right-format = "{np:>1}|" + line-numbers-right-style = "#1688f0" + line-numbers-zero-style = "#aaaaaa" italic + minus-emph-style = syntax bold "#b80000" + minus-style = syntax "#5d001e" + plus-emph-style = syntax bold "#007800" + plus-style = syntax "#004433" + whitespace-error-style = "#280050" + +[delta "mantis-shrimp-lite"] + #author: https://github.com/2kabhishek + dark = true + side-by-side = true + navigate = true + keep-plus-minus-markers = true + file-added-label = [+] + file-copied-label = [==] + file-modified-label = [*] + file-removed-label = [-] + file-renamed-label = [->] + file-style = omit + zero-style = syntax + syntax-theme = Monokai Extended + commit-decoration-style = green box + commit-style = yellow bold italic + hunk-header-decoration-style = blue box ul + hunk-header-file-style = purple ul bold + hunk-header-line-number-style = yellow box bold + hunk-header-style = file line-number syntax bold italic + line-numbers = true + line-numbers-left-format = "{nm:>1}|" + line-numbers-left-style = blue + line-numbers-minus-style = red bold + line-numbers-plus-style = green bold + line-numbers-right-format = "{np:>1}|" + line-numbers-right-style = blue + line-numbers-zero-style = white italic + minus-emph-style = syntax bold red + plus-emph-style = syntax bold green + whitespace-error-style = purple bold + +[delta "zebra-dark"] + minus-style = syntax "#330f0f" + minus-emph-style = syntax "#4f1917" + plus-style = syntax "#0e2f19" + plus-emph-style = syntax "#174525" + map-styles = \ + bold purple => syntax "#330f29", \ + bold blue => syntax "#271344", \ + bold cyan => syntax "#0d3531", \ + bold yellow => syntax "#222f14" + zero-style = syntax + whitespace-error-style = "#aaaaaa" + +[delta "zebra-light"] + minus-style = syntax "#fbdada" + minus-emph-style = syntax "#f6b6b6" + plus-style = syntax "#d6ffd6" + plus-emph-style = syntax "#adffad" + map-styles = \ + bold purple => syntax "#feecf7", \ + bold blue => syntax "#e5dff6", \ + bold cyan => syntax "#d8fdf6", \ + bold yellow => syntax "#f4ffe0" + zero-style = syntax + whitespace-error-style = "#aaaaaa" diff --git a/dot_config/kitty/current-theme.conf b/dot_config/kitty/current-theme.conf new file mode 100644 index 0000000..a3ab41f --- /dev/null +++ b/dot_config/kitty/current-theme.conf @@ -0,0 +1,21 @@ +background #f8f8f8 +foreground #2a2b33 +cursor #bbbbbb +selection_background #e5e5e6 +color0 #000000 +color8 #000000 +color1 #de3d35 +color9 #de3d35 +color2 #3e953a +color10 #3e953a +color3 #d2b67b +color11 #d2b67b +color4 #2f5af3 +color12 #2f5af3 +color5 #950095 +color13 #a00095 +color6 #3e953a +color14 #3e953a +color7 #bbbbbb +color15 #ffffff +selection_foreground #2a2b33 diff --git a/dot_config/kitty/kitty.conf b/dot_config/kitty/kitty.conf new file mode 100644 index 0000000..49fa05f --- /dev/null +++ b/dot_config/kitty/kitty.conf @@ -0,0 +1,14 @@ +font_family Operator Mono Book +#bold_font Operator Mono Bold +#italic_font Operator Mono Italic +#bold_italic_font Operator Mono Bold Italic +font_size 14.0 +cursor_shape block +shell_integration no-cursor +tab_bar_edge top + + +# BEGIN_KITTY_THEME +# Atom One Light +include current-theme.conf +# END_KITTY_THEME diff --git a/dot_config/lvim/config.lua b/dot_config/lvim/config.lua new file mode 100644 index 0000000..50d3940 --- /dev/null +++ b/dot_config/lvim/config.lua @@ -0,0 +1,163 @@ +-- general +lvim.log.level = "warn" +lvim.format_on_save = true +-- vim.o.background = "light" +lvim.colorscheme = "base16-one-light" + +-- keymappings [view all the defaults by pressing Lk] +lvim.leader = "space" +-- add your own keymapping +-- lvim.keys.normal_mode[""] = ":w" +-- unmap a default keymapping +-- lvim.keys.normal_mode[""] = false +-- edit a default keymapping +-- lvim.keys.normal_mode[""] = ":q" +lvim.keys.normal_mode[""] = ":bprevious" +lvim.keys.normal_mode[""] = ":bnext" +lvim.keys.normal_mode[""] = ":pastetoggle" + +vim.cmd [[ +" Relative numbering +function! NumberToggle() + if(&relativenumber == 1) + set nornu + set number + else + set rnu + endif +endfunc + +" Toggle between normal and relative numbering. +noremap :call NumberToggle() +]] + +-- Change Telescope navigation to use j and k for navigation and n and p for history in both input and normal mode. +-- we use protected-mode (pcall) just in case the plugin wasn't loaded yet. +-- local _, actions = pcall(require, "telescope.actions") +-- lvim.builtin.telescope.defaults.mappings = { +-- -- for input mode +-- i = { +-- [""] = actions.move_selection_next, +-- [""] = actions.move_selection_previous, +-- [""] = actions.cycle_history_next, +-- [""] = actions.cycle_history_prev, +-- }, +-- -- for normal mode +-- n = { +-- [""] = actions.move_selection_next, +-- [""] = actions.move_selection_previous, +-- }, +-- } + +-- Use which-key to add extra bindings with the leader-key prefix +-- lvim.builtin.which_key.mappings["P"] = { "Telescope projects", "Projects" } +-- lvim.builtin.which_key.mappings["t"] = { +-- name = "+Trouble", +-- r = { "Trouble lsp_references", "References" }, +-- f = { "Trouble lsp_definitions", "Definitions" }, +-- d = { "Trouble lsp_document_diagnostics", "Diagnostics" }, +-- q = { "Trouble quickfix", "QuickFix" }, +-- l = { "Trouble loclist", "LocationList" }, +-- w = { "Trouble lsp_workspace_diagnostics", "Diagnostics" }, +-- } + +-- TODO: User Config for predefined plugins +-- After changing plugin config exit and reopen LunarVim, Run :PackerInstall :PackerCompile +lvim.builtin.dashboard.active = true +lvim.builtin.notify.active = true +lvim.builtin.terminal.active = true +lvim.builtin.nvimtree.setup.view.side = "left" +lvim.builtin.nvimtree.show_icons.git = 0 + +-- if you don't want all the parsers change this to a table of the ones you want +lvim.builtin.treesitter.ensure_installed = { + "bash", + "c", + "json", + "lua", + "python", + "rust", + "yaml", +} + +lvim.builtin.treesitter.ignore_install = { "haskell" } +lvim.builtin.treesitter.highlight.enabled = true + +-- generic LSP settings + +-- ---@usage disable automatic installation of servers +-- lvim.lsp.automatic_servers_installation = false + +-- ---@usage Select which servers should be configured manually. Requires `:LvimCacheRest` to take effect. +-- See the full default list `:lua print(vim.inspect(lvim.lsp.override))` +-- vim.list_extend(lvim.lsp.override, { "pyright" }) + +-- ---@usage setup a server -- see: https://www.lunarvim.org/languages/#overriding-the-default-configuration +-- local opts = {} -- check the lspconfig documentation for a list of all possible options +-- require("lvim.lsp.manager").setup("pylsp", opts) + +-- -- you can set a custom on_attach function that will be used for all the language servers +-- -- See +-- lvim.lsp.on_attach_callback = function(client, bufnr) +-- local function buf_set_option(...) +-- vim.api.nvim_buf_set_option(bufnr, ...) +-- end +-- --Enable completion triggered by +-- buf_set_option("omnifunc", "v:lua.vim.lsp.omnifunc") +-- end + +-- -- set a formatter, this will override the language server formatting capabilities (if it exists) +-- local formatters = require "lvim.lsp.null-ls.formatters" +-- formatters.setup { +-- { command = "black", filetypes = { "python" } }, +-- { command = "isort", filetypes = { "python" } }, +-- { +-- -- each formatter accepts a list of options identical to https://github.com/jose-elias-alvarez/null-ls.nvim/blob/main/doc/BUILTINS.md#Configuration +-- command = "prettier", +-- ---@usage arguments to pass to the formatter +-- -- these cannot contain whitespaces, options such as `--line-width 80` become either `{'--line-width', '80'}` or `{'--line-width=80'}` +-- extra_args = { "--print-with", "100" }, +-- ---@usage specify which filetypes to enable. By default a providers will attach to all the filetypes it supports. +-- filetypes = { "typescript", "typescriptreact" }, +-- }, +-- } + +-- -- set additional linters +-- local linters = require "lvim.lsp.null-ls.linters" +-- linters.setup { +-- { command = "flake8", filetypes = { "python" } }, +-- { +-- -- each linter accepts a list of options identical to https://github.com/jose-elias-alvarez/null-ls.nvim/blob/main/doc/BUILTINS.md#Configuration +-- command = "shellcheck", +-- ---@usage arguments to pass to the formatter +-- -- these cannot contain whitespaces, options such as `--line-width 80` become either `{'--line-width', '80'}` or `{'--line-width=80'}` +-- extra_args = { "--severity", "warning" }, +-- }, +-- { +-- command = "codespell", +-- ---@usage specify which filetypes to enable. By default a providers will attach to all the filetypes it supports. +-- filetypes = { "javascript", "python" }, +-- }, +-- } + +-- Additional Plugins +lvim.plugins = { + {"RRethy/nvim-base16"}, + {"rebelot/kanagawa.nvim"}, + {"LunarVim/Colorschemes"}, +} +-- {"folke/tokyonight.nvim"}, +-- { +-- "folke/trouble.nvim", +-- cmd = "TroubleToggle", +-- }, +-- } + +-- Autocommands (https://neovim.io/doc/user/autocmd.html) +-- lvim.autocommands.custom_groups = { +-- { "BufWinEnter", "*.lua", "setlocal ts=8 sw=8" }, +-- } +lvim.autocommands.custom_groups = { + { "FileType", "make", "set noexpandtab shiftwidth=8 softtabstop=0" }, + { "BufNewFile,BufRead", "justfile", "setf automake expandtab shiftwidth=8 softtabstop=0" }, +} diff --git a/dot_config/nvim/init.vim b/dot_config/nvim/init.vim index 6410db2..709a3de 100644 --- a/dot_config/nvim/init.vim +++ b/dot_config/nvim/init.vim @@ -1,3 +1,5 @@ +"let g:ale_disable_lsp = 1 + call plug#begin('~/.config/nvim/autoload/plugged') Plug 'junegunn/vim-easy-align' Plug 'dense-analysis/ale' @@ -6,19 +8,23 @@ Plug 'vim-ruby/vim-ruby' Plug 'hashivim/vim-terraform' Plug 'cespare/vim-toml' Plug 'ntpeters/vim-better-whitespace' -Plug 'pearofducks/ansible-vim' +"Plug 'pearofducks/ansible-vim' Plug 'itchyny/vim-gitbranch' Plug 'rust-lang/rust.vim' Plug 'airblade/vim-gitgutter' -Plug 'elixir-editors/vim-elixir' +"Plug 'elixir-editors/vim-elixir' Plug 'junegunn/fzf', { 'do': { -> fzf#install() } } Plug 'junegunn/fzf.vim' -Plug 'https://tpope.io/vim/fugitive.git' Plug 'vim-airline/vim-airline' Plug 'vim-airline/vim-airline-themes' Plug 'kyazdani42/nvim-web-devicons' Plug 'kyazdani42/nvim-tree.lua' Plug 'svermeulen/vimpeccable' +Plug 'sp5/nvim-colors-solarized' +"Plug 'neoclide/coc.nvim', {'branch': 'release'} +Plug 'preservim/nerdtree' +Plug 'NoahTheDuke/vim-just' +Plug 'dewyze/vim-tada' call plug#end() set nocompatible @@ -44,15 +50,13 @@ set termguicolors set visualbell set noerrorbells set whichwrap=<,>,[,],b, -"set background=light set backspace=indent,eol,start set number set autoread -" set mouse=a set nobackup +set nowritebackup set nowb set noswapfile -syntax on let mapleader = " " syntax on @@ -67,31 +71,37 @@ let g:terraform_fmt_on_save = 1 autocmd FileType html set shiftwidth=4 softtabstop=4 tabstop=4 autocmd FileType javascript set shiftwidth=4 softtabstop=4 tabstop=4 autocmd FileType htmldjango set shiftwidth=4 softtabstop=4 tabstop=4 +autocmd FileType just set shiftwidth=4 softtabstop=4 tabstop=4 autocmd BufNewFile,BufRead *.tera set syntax=django -autocmd BufNewFile,BufRead justfile setf make "expandtab shiftwidth=8 softtabstop=0 +" autocmd BufNewFile,BufRead justfile setf make expandtab shiftwidth=8 softtabstop=0 +autocmd FileType *.md set expandtab " Center screen when scrolling search results nmap n nzz nmap N Nzz +"colorscheme solarized let g:airline_powerline_fonts=1 -"let g:airline_theme='papercolor' -let g:airline_theme='base16_eighties' +let g:airline_theme='base16_one_light' +let g:airline_theme='owo' let g:airline#extensions#tabline#enabled = 1 + noremap :bp noremap :bn - set pastetoggle= " highlight trailing whitespace -highlight ExtraWhitespace ctermbg=red guibg=red +highlight ExtraWhitespace ctermbg=lightblue guibg=lightblue match ExtraWhitespace /\s\+$/ autocmd BufWinEnter * match ExtraWhitespace /\s\+$/ autocmd InsertEnter * match ExtraWhitespace /\s\+\%#\@1 :source ~/.config/nvim/init.vim \| :PlugInstall map s :StripWhitespace nnoremap g :Rg +nnoremap p :Files nnoremap l :Buffers nnoremap :call SetNewPassword() @@ -130,11 +141,173 @@ endfunc noremap :call NumberToggle() " File Browser -nnoremap :NvimTreeToggle +nnoremap e :NvimTreeToggle nnoremap r :NvimTreeRefresh nnoremap n :NvimTreeFindFile let g:nvim_tree_auto_close = 1 " let g:nvim_tree_quit_on_open = 1 let g:nvim_tree_git_hl = 1 -set guifont=OperatorMono\ Nerd\ Font:h16 +"set guifont=OperatorMono\ Nerd\ Font:h16 + +" Set internal encoding of vim, not needed on neovim, since coc.nvim using some +" unicode characters in the file autoload/float.vim +set encoding=utf-8 + +" TextEdit might fail if hidden is not set. +set hidden + +" Give more space for displaying messages. +"set cmdheight=1 + +" Having longer updatetime (default is 4000 ms = 4 s) leads to noticeable +" delays and poor user experience. +set updatetime=300 + +" Don't pass messages to |ins-completion-menu|. +set shortmess+=c + +" Always show the signcolumn, otherwise it would shift the text each time +" diagnostics appear/become resolved. +"if has("nvim-0.5.0") || has("patch-8.1.1564") + " Recently vim can merge signcolumn and number column into one +" set signcolumn=number +"else +" set signcolumn=yes +"endif + +" Use tab for trigger completion with characters ahead and navigate. +" NOTE: Use command ':verbose imap ' to make sure tab is not mapped by +" other plugin before putting this into your config. +"inoremap +" \ pumvisible() ? "\" : +" \ check_back_space() ? "\" : +" \ coc#refresh() +"inoremap pumvisible() ? "\" : "\" + +"function! s:check_back_space() abort +" let col = col('.') - 1 +" return !col || getline('.')[col - 1] =~# '\s' +"endfunction + +" Use to trigger completion. +"if has('nvim') +" inoremap coc#refresh() +"else +" inoremap coc#refresh() +"endif + +" Make auto-select the first completion item and notify coc.nvim to +" format on enter, could be remapped by other vim plugin +"inoremap pumvisible() ? coc#_select_confirm() +" \: "\u\\=coc#on_enter()\" + +" Use `[g` and `]g` to navigate diagnostics +" Use `:CocDiagnostics` to get all diagnostics of current buffer in location list. +"nmap [g (coc-diagnostic-prev) +"nmap ]g (coc-diagnostic-next) + +" GoTo code navigation. +"nmap gd (coc-definition) +"nmap gy (coc-type-definition) +"nmap gi (coc-implementation) +"nmap gr (coc-references) + +" Use K to show documentation in preview window. +"nnoremap K :call show_documentation() + +"function! s:show_documentation() +" if (index(['vim','help'], &filetype) >= 0) +" execute 'h '.expand('') +" elseif (coc#rpc#ready()) +" call CocActionAsync('doHover') +" else +" execute '!' . &keywordprg . " " . expand('') +" endif +"endfunction + +" Highlight the symbol and its references when holding the cursor. +"autocmd CursorHold * silent call CocActionAsync('highlight') + +" Symbol renaming. +"nmap rn (coc-rename) + +" Formatting selected code. +"xmap f (coc-format-selected) +"nmap f (coc-format-selected) + +"augroup mygroup +" autocmd! + " Setup formatexpr specified filetype(s). +" autocmd FileType typescript,json setl formatexpr=CocAction('formatSelected') + " Update signature help on jump placeholder. +" autocmd User CocJumpPlaceholder call CocActionAsync('showSignatureHelp') +"augroup end +" +" Applying codeAction to the selected region. +" Example: `aap` for current paragraph +"xmap a (coc-codeaction-selected) +"nmap a (coc-codeaction-selected) + +" Remap keys for applying codeAction to the current buffer. +"nmap ac (coc-codeaction) +" Apply AutoFix to problem on the current line. +"nmap qf (coc-fix-current) + +" Map function and class text objects +" NOTE: Requires 'textDocument.documentSymbol' support from the language server. +"xmap if (coc-funcobj-i) +"omap if (coc-funcobj-i) +"xmap af (coc-funcobj-a) +"omap af (coc-funcobj-a) +"xmap ic (coc-classobj-i) +"omap ic (coc-classobj-i) +"xmap ac (coc-classobj-a) +"omap ac (coc-classobj-a) + +" Remap and for scroll float windows/popups. +"if has('nvim-0.4.0') || has('patch-8.2.0750') +" nnoremap coc#float#has_scroll() ? coc#float#scroll(1) : "\" +" nnoremap coc#float#has_scroll() ? coc#float#scroll(0) : "\" +" inoremap coc#float#has_scroll() ? "\=coc#float#scroll(1)\" : "\" +" inoremap coc#float#has_scroll() ? "\=coc#float#scroll(0)\" : "\" +" vnoremap coc#float#has_scroll() ? coc#float#scroll(1) : "\" +" vnoremap coc#float#has_scroll() ? coc#float#scroll(0) : "\" +"endif + +" Use CTRL-S for selections ranges. +" Requires 'textDocument/selectionRange' support of language server. +"nmap (coc-range-select) +"xmap (coc-range-select) + +" Add `:Format` command to format current buffer. +"command! -nargs=0 Format :call CocAction('format') + +" Add `:Fold` command to fold current buffer. +"command! -nargs=? Fold :call CocAction('fold', ) + +" Add `:OR` command for organize imports of the current buffer. +"command! -nargs=0 OR :call CocAction('runCommand', 'editor.action.organizeImport') + +" Add (Neo)Vim's native statusline support. +" NOTE: Please see `:h coc-status` for integrations with external plugins that +" provide custom statusline: lightline.vim, vim-airline. +"set statusline^=%{coc#status()}%{get(b:,'coc_current_function','')} + +" Mappings for CoCList +" Show all diagnostics. +"nnoremap a :CocList diagnostics +" Manage extensions. +"nnoremap e :CocList extensions +" Show commands. +"nnoremap c :CocList commands +" Find symbol of current document. +"nnoremap o :CocList outline +" Search workspace symbols. +"nnoremap s :CocList -I symbols +" Do default action for next item. +"nnoremap j :CocNext +" Do default action for previous item. +"nnoremap k :CocPrev +" Resume latest coc list. +"nnoremap p :CocListResume diff --git a/dot_gitconfig b/dot_gitconfig index b056220..3763ac1 100644 --- a/dot_gitconfig +++ b/dot_gitconfig @@ -1,32 +1,5 @@ -[delta "woolly-mammoth"] - # author: https://github.com/Kr1ss-XD - commit-decoration-style = 232 130 box - commit-style = 232 bold 130 - dark = true - file-added-label = [+] - file-copied-label = [C] - file-decoration-style = "#606018" overline - file-modified-label = [M] - file-removed-label = [-] - file-renamed-label = [R] - file-style = 232 bold 184 - hunk-header-decoration-style = none - hunk-header-style = syntax bold 237 - line-numbers = true - line-numbers-left-format = "{nm:>1}┊" - line-numbers-left-style = red - line-numbers-minus-style = red black - line-numbers-plus-style = green black - line-numbers-right-format = "{np:>1}┊" - line-numbers-right-style = green - line-numbers-zero-style = "#545474" - minus-emph-style = syntax bold "#780000" - minus-style = syntax "#400000" - plus-emph-style = syntax bold "#007800" - plus-style = syntax "#004000" - syntax-theme = Vibrant Sunburst - whitespace-error-style = "#280050" reverse - zero-style = syntax +[include] + path = /home/andrew/.config/git/delta.gitconfig [push] default = simple @@ -48,34 +21,31 @@ defaultBranch = main [delta] - features = woolly-mammoth #decorations hoopoe - -[delta "hoopoe"] - # author: https://github.com/dandavison - commit-decoration-style = blue ol - commit-style = raw - file-style = omit - hunk-header-decoration-style = blue box - hunk-header-file-style = red - hunk-header-line-number-style = "#067a00" - hunk-header-style = file line-number syntax - light = true - minus-emph-style = normal "#ffc0c0" - minus-empty-line-marker-style = normal "#ffe0e0" - minus-non-emph-style = normal "#ffe0e0" - minus-style = normal "#ffe0e0" - plus-emph-style = syntax "#a0efa0" - plus-empty-line-marker-style = normal "#d0ffd0" - plus-non-emph-style = syntax "#d0ffd0" - plus-style = syntax "#d0ffd0" - syntax-theme = GitHub - zero-style = syntax - -[delta "decorations"] - #commit-decoration-style = bold yellow box - #file-style = bold blue - file-decoration-style = blue ol - hunk-header-style = omit + line-numbers = true + # author: https://github.com/dandavison + light = true + pink = "#ffe0e0" + dark-pink = "#ffc0c0" + green = "#d0ffd0" + dark-green = "#a0efa0" + dark-green-2 = "#067a00" + minus-style = normal hoopoe.pink + minus-emph-style = normal hoopoe.dark-pink + minus-non-emph-style = minus-style + plus-style = syntax hoopoe.green + plus-emph-style = syntax hoopoe.dark-green + plus-non-emph-style = plus-style + minus-empty-line-marker-style = minus-style + plus-empty-line-marker-style = plus-style + commit-decoration-style = blue ol + commit-style = raw + file-style = omit + hunk-header-decoration-style = blue box + hunk-header-file-style = red + hunk-header-line-number-style = hoopoe.dark-green-2 + hunk-header-style = file #line-number syntax + syntax-theme = GitHub + zero-style = syntax [rebase] autoStash = true @@ -118,6 +88,5 @@ --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 + 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)' -# gone = ! "git fetch -p && git for-each-ref --format '%(refname:short) %(upstream:track)' | awk '$2 == \"[gone]\" {print $1}' | xargs -r git branch -D" diff --git a/dot_vimrc b/dot_vimrc index 9ea39f1..a9c5f6c 100644 --- a/dot_vimrc +++ b/dot_vimrc @@ -6,3 +6,9 @@ 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 diff --git a/private_dot_aws/private_credentials.tmpl b/private_dot_aws/private_credentials.tmpl deleted file mode 100644 index 50a9e8e..0000000 --- a/private_dot_aws/private_credentials.tmpl +++ /dev/null @@ -1,3 +0,0 @@ -[default] -aws_access_key_id = {{ (bitwardenFields "item" "Wellsky-AWS").access_key_id.value }} -aws_secret_access_key = {{ (bitwardenFields "item" "Wellsky-AWS").secret_access_key.value }} diff --git a/private_dot_bashrc.d/aliases.sh b/private_dot_bashrc.d/aliases.sh deleted file mode 100644 index 115ddc2..0000000 --- a/private_dot_bashrc.d/aliases.sh +++ /dev/null @@ -1,37 +0,0 @@ -if which lsd > /dev/null 2>&1 ; then - alias ls="lsd" -else - alias ls="ls --color=auto" -fi -alias grep='grep --colour=auto' -alias egrep='egrep --colour=auto' -alias fgrep='fgrep --colour=auto' - -shopt -s expand_aliases - -# ex - archive extractor -# usage: ex -ex () -{ - if [ -f $1 ] ; then - case $1 in - *.tar.bz2) tar xjf $1 ;; - *.tar.gz) tar xzf $1 ;; - *.bz2) bunzip2 $1 ;; - *.rar) unrar x $1 ;; - *.gz) gunzip $1 ;; - *.tar) tar xf $1 ;; - *.tbz2) tar xjf $1 ;; - *.tgz) tar xzf $1 ;; - *.zip) unzip $1 ;; - *.Z) uncompress $1;; - *.7z) 7z x $1 ;; - *) echo "'$1' cannot be extracted via ex()" ;; - esac - else - echo "'$1' is not a valid file" - fi -} - -alias m4b-tool='docker run -it --rm -u $(id -u):$(id -g) -v "$(pwd)":/mnt m4b-tool' -alias gcurl='curl --header "Authorization: Bearer $(gcloud auth print-identity-token)"' diff --git a/private_dot_bashrc.d/history.sh b/private_dot_bashrc.d/history.sh deleted file mode 100644 index aeab937..0000000 --- a/private_dot_bashrc.d/history.sh +++ /dev/null @@ -1,20 +0,0 @@ -# don't put duplicate lines or lines starting with space in the history. -# See bash(1) for more options -HISTCONTROL=ignoreboth - -## -## history: http://mywiki.wooledge.org/BashFAQ/088 -## - -# Big history -HISTFILESIZE=10000 -HISTSIZE=10000 -HISTTIMEFORMAT="%Y-%m-%d %H:%M:%S " - -# history -a causes an immediate write of all new history lines -# (instead of upon shell exit) -PROMPT_COMMAND="history -a" - -# histappend which causes all new history lines to be appended, and ensures -# that multiple logins do not overwrite each other's history -shopt -s histappend diff --git a/private_dot_bashrc.d/kubernetes-wellsky.sh.tmpl b/private_dot_bashrc.d/kubernetes-wellsky.sh.tmpl deleted file mode 100644 index 5a3a0c6..0000000 --- a/private_dot_bashrc.d/kubernetes-wellsky.sh.tmpl +++ /dev/null @@ -1,2 +0,0 @@ -export KUBECTL=$(which kubectl) -export KOPS_STATE_STORE={{- (bitwarden "item" "Wellsky-Kubernetes").notes }} diff --git a/private_dot_bashrc.d/pager.sh b/private_dot_bashrc.d/pager.sh deleted file mode 100644 index f4b4086..0000000 --- a/private_dot_bashrc.d/pager.sh +++ /dev/null @@ -1,8 +0,0 @@ -LESS="-R"; export LESS -if which most > /dev/null 2>&1 ; then - PAGER=most -else - PAGER=less -fi -export PAGER -DELTA_PAGER=less; export DELTA_PAGER