Update dotfiles/.profile, dotfiles/.env, dotfiles/.gitconfig, dotfiles/.local/delta/themes.gitconfig, dotfiles/.config/ripgreprc, dotfiles/.config/batrc

This commit is contained in:
Brian Zalewski 2022-11-02 15:26:20 +00:00
parent f6bb7882e4
commit 09478d9ef7
6 changed files with 484 additions and 0 deletions

11
dotfiles/.config/batrc Normal file
View file

@ -0,0 +1,11 @@
# Set the theme to "TwoDark"
--theme="TwoDark"
# Show line numbers, Git modifications and file header (but no grid)
--style="numbers,changes,header"
# Use italic text on the terminal (not supported on all terminals)
--italic-text=always
# Use C++ syntax for Arduino .ino files
--map-syntax "*.ino:C++"

View file

@ -0,0 +1,21 @@
# Don't let ripgrep vomit really long lines to my terminal, and show a preview.
--max-columns=150
--max-columns-preview
# Add my 'web' type.
--type-add
web:*.{html,css,js}*
# Using glob patterns to include/exclude files or folders
--glob=!git/*
# or
--glob
!git/*
# Set the colors.
--colors=line:none
--colors=line:style:bold
# Because who cares about case!?
--smart-case

92
dotfiles/.env Normal file
View file

@ -0,0 +1,92 @@
AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY
### Restic
RESTIC_REPOSITORY_FILE Name of file containing the repository location (replaces --repository-file)
RESTIC_REPOSITORY Location of repository (replaces -r)
RESTIC_PASSWORD_FILE Location of password file (replaces --password-file)
RESTIC_PASSWORD The actual password for the repository
RESTIC_PASSWORD_COMMAND Command printing the password for the repository to stdout
RESTIC_KEY_HINT ID of key to try decrypting first, before other keys
RESTIC_CACHE_DIR Location of the cache directory
RESTIC_COMPRESSION Compression mode (only available for repository format version 2)
RESTIC_PROGRESS_FPS Frames per second by which the progress bar is updated
RESTIC_PACK_SIZE Target size for pack files
TMPDIR Location for temporary files
AWS_ACCESS_KEY_ID Amazon S3 access key ID
AWS_SECRET_ACCESS_KEY Amazon S3 secret access key
AWS_SESSION_TOKEN Amazon S3 temporary session token
AWS_DEFAULT_REGION Amazon S3 default region
AWS_PROFILE Amazon credentials profile (alternative to specifying key and region)
AWS_SHARED_CREDENTIALS_FILE Location of the AWS CLI shared credentials file (default: ~/.aws/credentials)
ST_AUTH Auth URL for keystone v1 authentication
ST_USER Username for keystone v1 authentication
ST_KEY Password for keystone v1 authentication
OS_AUTH_URL Auth URL for keystone authentication
OS_REGION_NAME Region name for keystone authentication
OS_USERNAME Username for keystone authentication
OS_USER_ID User ID for keystone v3 authentication
OS_PASSWORD Password for keystone authentication
OS_TENANT_ID Tenant ID for keystone v2 authentication
OS_TENANT_NAME Tenant name for keystone v2 authentication
OS_USER_DOMAIN_NAME User domain name for keystone authentication
OS_USER_DOMAIN_ID User domain ID for keystone v3 authentication
OS_PROJECT_NAME Project name for keystone authentication
OS_PROJECT_DOMAIN_NAME Project domain name for keystone authentication
OS_PROJECT_DOMAIN_ID Project domain ID for keystone v3 authentication
OS_TRUST_ID Trust ID for keystone v3 authentication
OS_APPLICATION_CREDENTIAL_ID Application Credential ID (keystone v3)
OS_APPLICATION_CREDENTIAL_NAME Application Credential Name (keystone v3)
OS_APPLICATION_CREDENTIAL_SECRET Application Credential Secret (keystone v3)
OS_STORAGE_URL Storage URL for token authentication
OS_AUTH_TOKEN Auth token for token authentication
B2_ACCOUNT_ID Account ID or applicationKeyId for Backblaze B2
B2_ACCOUNT_KEY Account Key or applicationKey for Backblaze B2
AZURE_ACCOUNT_NAME Account name for Azure
AZURE_ACCOUNT_KEY Account key for Azure
AZURE_ACCOUNT_SAS Shared access signatures (SAS) for Azure
GOOGLE_PROJECT_ID Project ID for Google Cloud Storage
GOOGLE_APPLICATION_CREDENTIALS Application Credentials for Google Cloud Storage (e.g. $HOME/.config/gs-secret-restic-key.json)
RCLONE_BWLIMIT rclone bandwidth limit
### Wazuh
WAZUH_MANAGER
Specifies the manager IP address or hostname. If you want to specify multiple managers, you can add them separated by commas. See address.
WAZUH_MANAGER_PORT
Specifies the manager connection port. See port.
WAZUH_PROTOCOL
Sets the communication protocol between the manager and the agent. Accepts UDP and TCP. The default is TCP. See protocol.
WAZUH_REGISTRATION_SERVER
Specifies the Wazuh registration server, used for the agent registration. See manager_address. If empty, the value set in WAZUH_MANAGER will be used.
WAZUH_REGISTRATION_PORT
Specifies the port used by the Wazuh registration server. See port.
WAZUH_REGISTRATION_PASSWORD
Sets password used to authenticate during register, stored in etc/authd.pass. See authorization_pass_path
WAZUH_KEEP_ALIVE_INTERVAL
Sets the time between agent checks for manager connection. See notify_time.
WAZUH_TIME_RECONNECT
Sets the time interval for the agent to reconnect with the Wazuh manager when connectivity is lost. See time-reconnect.
WAZUH_REGISTRATION_CA
Host SSL validation need of Certificate of Authority. This option specifies the CA path. See server_ca_path.
WAZUH_REGISTRATION_CERTIFICATE
The SSL agent verification needs a CA signed certificate and the respective key. This option specifies the certificate path. See agent_certificate_path.
WAZUH_REGISTRATION_KEY
Specifies the key path completing the required variables with WAZUH_REGISTRATION_CERTIFICATE for the SSL agent verification process. See agent_key_path.
WAZUH_AGENT_NAME
Designates the agent's name. By default, it will be the computer name. See agent_name.
WAZUH_AGENT_GROUP
Assigns the agent to one or more existing groups (separated by commas). See agent_groups.
ENROLLMENT_DELAY
Assigns the time that agentd should wait after a successful registration. See delay_after_enrollment.

View file

@ -1,3 +1,5 @@
[include]
path = ~/.local/delta/themes.gitconfig
[advice] [advice]
detachedHead = false detachedHead = false
[alias] [alias]
@ -21,7 +23,28 @@
excludesfile = ~/.gitignore excludesfile = ~/.gitignore
autocrlf = input autocrlf = input
attributesfile = ~/.gitattributes attributesfile = ~/.gitattributes
pager = delta
[delta]
decorations = true
features = side-by-side decorations hyperlinks interactive navigate unobtrusive-line-numbers woolly-mammoth zebra-dark
hyperlinks = true
interactive = true
map-styles = bold purple => syntax magenta, bold cyan => syntax blue
navigate = true
side-by-side = true
unobtrusive-line-numbers = true
[delta "interactive"]
keep-plus-minus-markers = false
[delta "decorations"]
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
[diff] [diff]
colorMoved = default
ignoresubmodules = dirty ignoresubmodules = dirty
[diff "image"] [diff "image"]
command = compare $2 $1 png:- | montage -geometry +4+4 $2 - $1 png:- | display -title \"$1\" - command = compare $2 $1 png:- | montage -geometry +4+4 $2 - $1 png:- | display -title \"$1\" -
@ -29,7 +52,10 @@
prompt = false prompt = false
[credential] [credential]
helper = cache --timeout=3600 helper = cache --timeout=3600
[interactive]
diffFilter = delta --color-only --features=interactive
[merge] [merge]
conflictstyle = diff3
tool = kdiff3 tool = kdiff3
[pull] [pull]
rebase = true rebase = true

View file

@ -0,0 +1,309 @@
[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"
[delta "chameleon"]
#author: https://github.com/AirOnSkin
dark = true
line-numbers = true
side-by-side = true
keep-plus-minus-markers = false
syntax-theme = Nord
file-style = "#434C5E" bold
file-decoration-style = "#434C5E" ul
file-added-label = [+]
file-copied-label = [==]
file-modified-label = [*]
file-removed-label = [-]
file-renamed-label = [->]
hunk-header-style = omit
line-numbers-left-format = " {nm:>3} │"
line-numbers-left-style = red
line-numbers-right-format = " {np:>3} │"
line-numbers-right-style = green
line-numbers-minus-style = red italic black
line-numbers-plus-style = green italic black
line-numbers-zero-style = "#434C5E" italic
minus-style = bold red
minus-emph-style = bold "#202020" "#FF5555"
minus-non-emph-style = bold
plus-style = bold green
plus-emph-style = bold "#202020" "#50FA7B"
plus-non-emph-style = bold
zero-style = syntax
blame-code-style = syntax
blame-format = "{author:<18} ({commit:>9}) {timestamp:^16}"
blame-palette = "#2E3440" "#3B4252" "#434C5E" "#4C566A"
merge-conflict-begin-symbol = ~
merge-conflict-end-symbol = ~
merge-conflict-ours-diff-header-style = "#F1FA8C" bold
merge-conflict-ours-diff-header-decoration-style = "#434C5E" box
merge-conflict-theirs-diff-header-style = "#F1FA8C" bold
merge-conflict-theirs-diff-header-decoration-style = "#434C5E" box

View file

@ -227,6 +227,25 @@ if [ -f "$HOME/.local/asdf/asdf.sh" ]; then
. "$HOME/.local/asdf/asdf.sh" . "$HOME/.local/asdf/asdf.sh"
fi fi
### bat
if command -v bat > /dev/null; then
export BAT_CONFIG_PATH="$HOME/.config/batrc"
alias cat='bat --paging=never'
export MANPAGER="sh -c 'col -bx | bat -l man -p'"
alias bathelp='bat --plain --language=help'
help() {
"$@" --help 2>&1 | bathelp
}
fi
### BitWarden
# https://bitwarden.com/help/cli/#using-an-api-key
# BW_CLIENTID client_id
# BW_CLIENTSECRET
### Elastic Agent
# https://www.elastic.co/guide/en/fleet/current/agent-environment-variables.html#env-common-vars
### fzf ### fzf
if command -v fzf > /dev/null && command -v fd > /dev/null; then if command -v fzf > /dev/null && command -v fd > /dev/null; then
export FZF_DEFAULT_COMMAND='fd --type f --strip-cwd-prefix --hidden --follow --exclude .git' export FZF_DEFAULT_COMMAND='fd --type f --strip-cwd-prefix --hidden --follow --exclude .git'
@ -255,6 +274,12 @@ if [ ! -d "$POETRY_HOME" ]; then
fi fi
export PATH="$POETRY_HOME/bin:$PATH" export PATH="$POETRY_HOME/bin:$PATH"
### Rear
# https://github.com/rear/rear/blob/master/doc/user-guide/03-configuration.adoc
### ripgrep
export RIPGREP_CONFIG_PATH="$HOME/.config/ripgreprc"
### Ruby ### Ruby
export GEM_HOME="$HOME/.local/gems" export GEM_HOME="$HOME/.local/gems"
if [ ! -d "$GEM_HOME" ]; then if [ ! -d "$GEM_HOME" ]; then