mirror of
https://github.com/ivuorinen/dotfiles.git
synced 2026-02-04 18:48:52 +00:00
Compare commits
24 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
94e58b307b | ||
| 98aca096a9 | |||
| 121e31c7d4 | |||
| f6bcd10ac5 | |||
| 619c772fcc | |||
| 746d44151c | |||
| b9585209be | |||
| 930dcf00c4 | |||
| bb8e3bba56 | |||
| 6431c2e6dc | |||
| 248eca1ae6 | |||
| 4b1ab2e1b8 | |||
| c0f537439b | |||
| 9ab132d37c | |||
| 2b9ddc232b | |||
| 1a244ce0b1 | |||
| fdc0f45b23 | |||
| 3fa90eef3b | |||
| 7ea7c12f0b | |||
| f76492b942 | |||
| 7947340663 | |||
| 300c48b1e9 | |||
| 772527cc66 | |||
|
|
370fdcbcbe |
@@ -19,7 +19,7 @@ indent_size = 1
|
|||||||
indent_size = 1
|
indent_size = 1
|
||||||
indent_style = tab
|
indent_style = tab
|
||||||
|
|
||||||
[{local/bin/*,**/*.sh,**/zshrc,config/*}]
|
[{local/bin/*,**/*.sh,**/zshrc,config/*,scripts/*}]
|
||||||
shell_variant = bash # --language-variant
|
shell_variant = bash # --language-variant
|
||||||
binary_next_line = true
|
binary_next_line = true
|
||||||
switch_case_indent = true # --case-indent
|
switch_case_indent = true # --case-indent
|
||||||
|
|||||||
1
.github/workflows/changelog.yml
vendored
1
.github/workflows/changelog.yml
vendored
@@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
name: Debug Changelog # Workflow name displayed on GitHub
|
name: Debug Changelog # Workflow name displayed on GitHub
|
||||||
on:
|
on:
|
||||||
workflow_dispatch: # Trigger manually
|
workflow_dispatch: # Trigger manually
|
||||||
|
|||||||
1
.github/workflows/linters.yml
vendored
1
.github/workflows/linters.yml
vendored
@@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
name: reviewdog
|
name: reviewdog
|
||||||
on: [push]
|
on: [push]
|
||||||
jobs:
|
jobs:
|
||||||
|
|||||||
16
.github/workflows/new-release.yml
vendored
16
.github/workflows/new-release.yml
vendored
@@ -1,21 +1,24 @@
|
|||||||
name: Release Daily State # Workflow name displayed on GitHub
|
---
|
||||||
|
name: Release Daily State
|
||||||
on:
|
on:
|
||||||
workflow_dispatch: # Trigger manually
|
workflow_dispatch:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '30 20 * * *' # UTC is 2-3 hours behind Europe/Helsinki, my timezone
|
- cron: '0 21 * * *' # 00:00 at Europe/Helsinki
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
jobs:
|
jobs:
|
||||||
new-daily-release:
|
new-daily-release:
|
||||||
runs-on: self-hosted
|
runs-on: self-hosted
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
outputs:
|
outputs:
|
||||||
created: ${{ steps.daily-version.outputs.created }}
|
created: ${{ steps.daily-version.outputs.created }}
|
||||||
version: ${{ steps.daily-version.outputs.version }}
|
version: ${{ steps.daily-version.outputs.version }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4 # Checkout our working repository
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Create tag if necessary
|
- name: Create tag if necessary
|
||||||
uses: fregante/daily-version-action@v2
|
uses: fregante/daily-version-action@v2
|
||||||
id: daily-version
|
id: daily-version
|
||||||
|
|
||||||
- name: Create changelog text
|
- name: Create changelog text
|
||||||
if: steps.daily-version.outputs.created
|
if: steps.daily-version.outputs.created
|
||||||
id: changelog
|
id: changelog
|
||||||
@@ -23,6 +26,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
config_file: .github/tag-changelog-config.js
|
config_file: .github/tag-changelog-config.js
|
||||||
|
|
||||||
- name: Create release
|
- name: Create release
|
||||||
if: steps.daily-version.outputs.created
|
if: steps.daily-version.outputs.created
|
||||||
uses: actions/create-release@latest
|
uses: actions/create-release@latest
|
||||||
|
|||||||
1
.github/workflows/semantic-pr.yml
vendored
1
.github/workflows/semantic-pr.yml
vendored
@@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
name: Semantic PR
|
name: Semantic PR
|
||||||
|
|
||||||
on:
|
on:
|
||||||
|
|||||||
9
.github/workflows/update-submodules.yml
vendored
9
.github/workflows/update-submodules.yml
vendored
@@ -1,13 +1,14 @@
|
|||||||
|
---
|
||||||
name: Update submodules
|
name: Update submodules
|
||||||
on:
|
on:
|
||||||
schedule: [{ cron: 0 3 * * * }]
|
schedule: [{ cron: 0 3 * * * }]
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
issues: write
|
|
||||||
pull-requests: write
|
|
||||||
jobs:
|
jobs:
|
||||||
update-submodules:
|
update-submodules:
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
issues: write
|
||||||
|
pull-requests: write
|
||||||
runs-on: self-hosted
|
runs-on: self-hosted
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
|
|||||||
50
.pre-commit-config.yaml
Normal file
50
.pre-commit-config.yaml
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
repos:
|
||||||
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||||
|
rev: v4.6.0
|
||||||
|
hooks:
|
||||||
|
- id: trailing-whitespace
|
||||||
|
args: [--markdown-linebreak-ext=md]
|
||||||
|
- id: check-case-conflict
|
||||||
|
- id: check-merge-conflict
|
||||||
|
- id: check-shebang-scripts-are-executable
|
||||||
|
- id: check-symlinks
|
||||||
|
- id: check-toml
|
||||||
|
- id: check-xml
|
||||||
|
- id: check-yaml
|
||||||
|
args: [--allow-multiple-documents]
|
||||||
|
- id: end-of-file-fixer
|
||||||
|
- id: mixed-line-ending
|
||||||
|
args: [--fix=auto]
|
||||||
|
- id: pretty-format-json
|
||||||
|
args: [--autofix, --no-sort-keys]
|
||||||
|
|
||||||
|
- repo: https://github.com/igorshubovych/markdownlint-cli
|
||||||
|
rev: v0.41.0
|
||||||
|
hooks:
|
||||||
|
- id: markdownlint
|
||||||
|
args: [-c, .markdownlint.yaml, --fix]
|
||||||
|
|
||||||
|
- repo: https://github.com/adrienverge/yamllint
|
||||||
|
rev: v1.35.1
|
||||||
|
hooks:
|
||||||
|
- id: yamllint
|
||||||
|
|
||||||
|
- repo: https://github.com/pre-commit/mirrors-prettier
|
||||||
|
rev: v4.0.0-alpha.8
|
||||||
|
hooks:
|
||||||
|
- id: prettier
|
||||||
|
|
||||||
|
- repo: https://github.com/shellcheck-py/shellcheck-py
|
||||||
|
rev: v0.10.0.1
|
||||||
|
hooks:
|
||||||
|
- id: shellcheck
|
||||||
|
|
||||||
|
- repo: https://github.com/scop/pre-commit-shfmt
|
||||||
|
rev: v3.9.0-1
|
||||||
|
hooks:
|
||||||
|
- id: shfmt
|
||||||
|
|
||||||
|
- repo: https://github.com/rhysd/actionlint
|
||||||
|
rev: v1.7.1
|
||||||
|
hooks:
|
||||||
|
- id: actionlint
|
||||||
@@ -1,5 +1,4 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
plugins: ['prettier-plugin-sh'],
|
|
||||||
...require('@ivuorinen/prettier-config'),
|
...require('@ivuorinen/prettier-config'),
|
||||||
trailingComma: 'all',
|
trailingComma: 'all',
|
||||||
// Add custom options below:
|
// Add custom options below:
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
3.12.5
|
3.12.6
|
||||||
|
|||||||
0
.yamlignore
Normal file
0
.yamlignore
Normal file
@@ -1,32 +1,30 @@
|
|||||||
|
asdf-plugin-manager 1.3.1
|
||||||
|
nodejs 22.8.0
|
||||||
|
golang 1.23.1
|
||||||
|
python 3.12.6
|
||||||
|
ruby 3.3.4
|
||||||
|
rust 1.81.0
|
||||||
|
direnv 2.34.0
|
||||||
|
eza 0.19.3
|
||||||
|
fd 10.2.0
|
||||||
1password-cli 2.30.0
|
1password-cli 2.30.0
|
||||||
age 1.2.0
|
age 1.2.0
|
||||||
asdf-plugin-manager 1.3.1
|
|
||||||
bottom 0.10.2
|
bottom 0.10.2
|
||||||
direnv 2.34.0
|
|
||||||
dotenv-linter 3.3.0
|
dotenv-linter 3.3.0
|
||||||
editorconfig-checker 2.8.0
|
editorconfig-checker 2.8.0
|
||||||
eza 0.19.0
|
github-cli 2.56.0
|
||||||
fd 10.2.0
|
|
||||||
github-cli 2.55.0
|
|
||||||
golang 1.23.0
|
|
||||||
hadolint 2.12.0
|
hadolint 2.12.0
|
||||||
kubectl 1.31.0
|
kubectl 1.31.1
|
||||||
lazygit 0.43.1
|
|
||||||
markdownlint-cli2 0.13.0
|
|
||||||
nodejs 22.8.0
|
|
||||||
pipx 1.7.1
|
pipx 1.7.1
|
||||||
pre-commit 3.8.0
|
pre-commit 3.8.0
|
||||||
python 3.12.5
|
ripgrep 14.1.1
|
||||||
ripgrep 14.1.0
|
|
||||||
ruby 3.3.4
|
|
||||||
rust 1.80.1
|
|
||||||
semgrep system
|
|
||||||
shellcheck 0.10.0
|
shellcheck 0.10.0
|
||||||
shfmt 3.9.0
|
shfmt 3.9.0
|
||||||
terragrunt 0.67.1
|
terragrunt 0.67.5
|
||||||
tf-summarize 0.3.10
|
tf-summarize 0.3.10
|
||||||
vault 1.17.5+ent
|
|
||||||
yamllint 1.35.1
|
yamllint 1.35.1
|
||||||
yq 4.44.3
|
yq 4.44.3
|
||||||
bats 1.11.0
|
bats 1.11.0
|
||||||
gitleaks 8.18.4
|
gitleaks 8.18.4
|
||||||
|
delta 0.18.1
|
||||||
|
lazygit 0.44.0
|
||||||
|
|||||||
@@ -53,9 +53,9 @@ alias flush="dscacheutil -flushcache"
|
|||||||
alias updatedb="sudo /usr/libexec/locate.updatedb"
|
alias updatedb="sudo /usr/libexec/locate.updatedb"
|
||||||
|
|
||||||
# tmux: automatically attach or create session with name 'main'
|
# tmux: automatically attach or create session with name 'main'
|
||||||
alias tmux='tmux new-session -A -s main'
|
alias tm='command tmux new-session -A -s main'
|
||||||
# tmux: attach or create new session
|
# tmux: attach or create new session
|
||||||
alias ta='tmux attach || tmux'
|
alias ta='command tmux attach || command tmux'
|
||||||
|
|
||||||
# nvim
|
# nvim
|
||||||
alias nvim-ks='NVIM_APPNAME="nvim-kickstart" nvim'
|
alias nvim-ks='NVIM_APPNAME="nvim-kickstart" nvim'
|
||||||
@@ -122,6 +122,7 @@ X_ALIAS_FILES=(
|
|||||||
"$HOME/.config/alias-$(hostname)-secret"
|
"$HOME/.config/alias-$(hostname)-secret"
|
||||||
)
|
)
|
||||||
for aliasFile in "${X_ALIAS_FILES[@]}"; do
|
for aliasFile in "${X_ALIAS_FILES[@]}"; do
|
||||||
|
# shellcheck source=$HOME/.config/alias-secret
|
||||||
[ -f "$aliasFile" ] && source "$aliasFile" && msg "Sourced $aliasFile"
|
[ -f "$aliasFile" ] && source "$aliasFile" && msg "Sourced $aliasFile"
|
||||||
done
|
done
|
||||||
unset X_ALIAS_FILES
|
unset X_ALIAS_FILES
|
||||||
|
|||||||
3
config/asdf-direnv/zshrc
Normal file
3
config/asdf-direnv/zshrc
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
### Do not edit. This was autogenerated by 'asdf direnv setup' ###
|
||||||
|
export ASDF_DIRENV_BIN="$(asdf where direnv)/bin/direnv"
|
||||||
|
eval "$($ASDF_DIRENV_BIN hook zsh)"
|
||||||
@@ -1,7 +1,6 @@
|
|||||||
1password-cli https://github.com/NeoHsu/asdf-1password-cli.git f5d5aab
|
1password-cli https://github.com/NeoHsu/asdf-1password-cli.git f5d5aab
|
||||||
age https://github.com/threkk/asdf-age.git 4df80a0
|
age https://github.com/threkk/asdf-age.git 4df80a0
|
||||||
asdf-plugin-manager https://github.com/asdf-community/asdf-plugin-manager.git dfb44cb
|
asdf-plugin-manager https://github.com/asdf-community/asdf-plugin-manager.git ecd1642
|
||||||
bats https://github.com/timgluz/asdf-bats.git 299551f
|
|
||||||
bottom https://github.com/carbonteq/asdf-btm.git fd8a55a
|
bottom https://github.com/carbonteq/asdf-btm.git fd8a55a
|
||||||
direnv https://github.com/asdf-community/asdf-direnv.git a2219c2
|
direnv https://github.com/asdf-community/asdf-direnv.git a2219c2
|
||||||
dotenv-linter https://github.com/wesleimp/asdf-dotenv-linter.git 1369f53
|
dotenv-linter https://github.com/wesleimp/asdf-dotenv-linter.git 1369f53
|
||||||
@@ -9,24 +8,20 @@ editorconfig-checker https://github.com/gabitchov/asdf-editorconfig-checker.git
|
|||||||
eza https://github.com/lwiechec/asdf-eza.git eee3d59
|
eza https://github.com/lwiechec/asdf-eza.git eee3d59
|
||||||
fd https://gitlab.com/wt0f/asdf-fd.git 17d56e0
|
fd https://gitlab.com/wt0f/asdf-fd.git 17d56e0
|
||||||
github-cli https://github.com/bartlomiejdanek/asdf-github-cli.git e0605b7
|
github-cli https://github.com/bartlomiejdanek/asdf-github-cli.git e0605b7
|
||||||
gitleaks https://github.com/jmcvetta/asdf-gitleaks.git 0cc0d7e
|
|
||||||
golang https://github.com/asdf-community/asdf-golang.git 0e86b1d
|
golang https://github.com/asdf-community/asdf-golang.git 0e86b1d
|
||||||
hadolint https://github.com/devlincashman/asdf-hadolint.git 335e230
|
hadolint https://github.com/devlincashman/asdf-hadolint.git 335e230
|
||||||
kubectl https://github.com/asdf-community/asdf-kubectl.git cbe6df4
|
kubectl https://github.com/asdf-community/asdf-kubectl.git cbe6df4
|
||||||
lazygit https://github.com/nklmilojevic/asdf-lazygit.git 78e04f1
|
lazygit https://github.com/nklmilojevic/asdf-lazygit.git 78e04f1
|
||||||
markdownlint-cli2 https://github.com/paulo-ferraz-oliveira/asdf-markdownlint-cli2.git 6acd080
|
nodejs https://github.com/asdf-vm/asdf-nodejs.git c5b7c40
|
||||||
nodejs https://github.com/asdf-vm/asdf-nodejs.git c36e6f0
|
|
||||||
pipx https://github.com/yozachar/asdf-pipx.git 31db618
|
pipx https://github.com/yozachar/asdf-pipx.git 31db618
|
||||||
pre-commit https://github.com/jonathanmorley/asdf-pre-commit.git 26bfc42
|
pre-commit https://github.com/jonathanmorley/asdf-pre-commit.git 26bfc42
|
||||||
python https://github.com/asdf-community/asdf-python 7b0af87
|
python https://github.com/asdf-community/asdf-python 7b0af87
|
||||||
ripgrep https://gitlab.com/wt0f/asdf-ripgrep.git e836665
|
ripgrep https://gitlab.com/wt0f/asdf-ripgrep.git e836665
|
||||||
ruby https://github.com/asdf-vm/asdf-ruby.git 27f78c9
|
ruby https://github.com/asdf-vm/asdf-ruby.git 27f78c9
|
||||||
rust https://github.com/code-lever/asdf-rust.git 95acf4f
|
rust https://github.com/code-lever/asdf-rust.git 95acf4f
|
||||||
semgrep https://github.com/brentjanderson/asdf-semgrep.git 13ff78b
|
shellcheck https://github.com/luizm/asdf-shellcheck.git 780d78d
|
||||||
shellcheck https://github.com/luizm/asdf-shellcheck.git 66200ff
|
|
||||||
shfmt https://github.com/luizm/asdf-shfmt.git a42c5ff
|
shfmt https://github.com/luizm/asdf-shfmt.git a42c5ff
|
||||||
terragrunt https://github.com/ohmer/asdf-terragrunt.git 4a6651a
|
terragrunt https://github.com/ohmer/asdf-terragrunt.git 4a6651a
|
||||||
tf-summarize https://github.com/adamcrews/asdf-tf-summarize.git 880ad26
|
tf-summarize https://github.com/adamcrews/asdf-tf-summarize.git 880ad26
|
||||||
vault https://github.com/asdf-community/asdf-hashicorp.git f1602b6
|
yamllint https://github.com/ericcornelissen/asdf-yamllint.git 2f4fd4c
|
||||||
yamllint https://github.com/ericcornelissen/asdf-yamllint.git d8c041a
|
|
||||||
yq https://github.com/sudermanjr/asdf-yq.git 772992f
|
yq https://github.com/sudermanjr/asdf-yq.git 772992f
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
[global]
|
[global]
|
||||||
disable_stdin = true
|
disable_stdin = true
|
||||||
|
load_dotenv = true
|
||||||
|
hide_env_diff = true
|
||||||
|
|
||||||
[whitelist]
|
[whitelist]
|
||||||
prefix = [
|
prefix = [
|
||||||
|
|||||||
@@ -93,7 +93,7 @@ darknotify_alacritty()
|
|||||||
}
|
}
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
darknotify_alacritty
|
# darknotify_alacritty
|
||||||
|
|
||||||
# Function to list installed Homebrew packages using bkt caching
|
# Function to list installed Homebrew packages using bkt caching
|
||||||
brew_installed()
|
brew_installed()
|
||||||
@@ -147,7 +147,7 @@ rector()
|
|||||||
{
|
{
|
||||||
local php="${1:-82}"
|
local php="${1:-82}"
|
||||||
docker run -v "$(pwd)":/project rector/rector:latest process \
|
docker run -v "$(pwd)":/project rector/rector:latest process \
|
||||||
"/project/$1" \
|
"/project/" \
|
||||||
--set "php${php}" \
|
--set "php${php}" \
|
||||||
--autoload-file /project/vendor/autoload.php
|
--autoload-file /project/vendor/autoload.php
|
||||||
}
|
}
|
||||||
@@ -270,6 +270,7 @@ export BASH_COMPLETION_USER_FILE="${XDG_CONFIG_HOME}/bash-completion/bash_comple
|
|||||||
|
|
||||||
# History env variables
|
# History env variables
|
||||||
export HIST_STAMPS="yyyy-mm-dd"
|
export HIST_STAMPS="yyyy-mm-dd"
|
||||||
|
export HISTFILE="${XDG_STATE_HOME}/zsh/history"
|
||||||
# Larger bash history (allow 32³ entries; default is 500)
|
# Larger bash history (allow 32³ entries; default is 500)
|
||||||
export HISTSIZE=32768
|
export HISTSIZE=32768
|
||||||
export HISTFILESIZE=$HISTSIZE
|
export HISTFILESIZE=$HISTSIZE
|
||||||
@@ -328,6 +329,7 @@ export ASDF_CONFIG_FILE="${XDG_CONFIG_HOME}/asdf/asdfrc"
|
|||||||
export ASDF_DATA_DIR="${ASDF_DIR}"
|
export ASDF_DATA_DIR="${ASDF_DIR}"
|
||||||
export ASDF_PLUGIN_MANAGER_PLUGIN_VERSIONS_FILENAME="${XDG_CONFIG_HOME}/asdf/plugin-versions"
|
export ASDF_PLUGIN_MANAGER_PLUGIN_VERSIONS_FILENAME="${XDG_CONFIG_HOME}/asdf/plugin-versions"
|
||||||
export ASDF_LOG_FILE="${XDG_CACHE_HOME}/asdf/asdf.log"
|
export ASDF_LOG_FILE="${XDG_CACHE_HOME}/asdf/asdf.log"
|
||||||
|
export ASDF_FORCE_PREPEND=yes
|
||||||
## Default package files
|
## Default package files
|
||||||
export ASDF_CRATE_DEFAULT_PACKAGES_FILE="${XDG_CONFIG_HOME}/asdf/cargo-packages"
|
export ASDF_CRATE_DEFAULT_PACKAGES_FILE="${XDG_CONFIG_HOME}/asdf/cargo-packages"
|
||||||
export ASDF_GEM_DEFAULT_PACKAGES_FILE="${XDG_CONFIG_HOME}/asdf/gem-packages"
|
export ASDF_GEM_DEFAULT_PACKAGES_FILE="${XDG_CONFIG_HOME}/asdf/gem-packages"
|
||||||
@@ -341,6 +343,23 @@ export ASDF_NODEJS_LEGACY_FILE_DYNAMIC_STRATEGY="latest_available"
|
|||||||
## Add asdf to path
|
## Add asdf to path
|
||||||
export PATH="${ASDF_DIR}/bin:${PATH}"
|
export PATH="${ASDF_DIR}/bin:${PATH}"
|
||||||
|
|
||||||
|
# aws
|
||||||
|
# https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html
|
||||||
|
# https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-envvars.html
|
||||||
|
# https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-profiles.html
|
||||||
|
msg "Setting up AWS configuration"
|
||||||
|
export AWS_CONFIG_FILE="${XDG_STATE_HOME}/aws/config"
|
||||||
|
export AWS_SHARED_CREDENTIALS_FILE="${XDG_STATE_HOME}/aws/credentials"
|
||||||
|
export AWS_DATA_PATH="${XDG_DATA_HOME}/aws"
|
||||||
|
export AWS_DEFAULT_REGION="eu-west-1"
|
||||||
|
export AWS_DEFAULT_OUTPUT="table"
|
||||||
|
export AWS_CONFIGURE_KEYS=true
|
||||||
|
export AWS_CONFIGURE_REGION=true
|
||||||
|
export AWS_CONFIGURE_OUTPUT=true
|
||||||
|
export AWS_CONFIGURE_PROFILE=true
|
||||||
|
export AWS_CONFIGURE_PROMPT=true
|
||||||
|
export AWS_CONFIGURE_PROMPT_DEFAULT="default"
|
||||||
|
|
||||||
# bob manages nvim versions
|
# bob manages nvim versions
|
||||||
msg "Setting up bob configuration"
|
msg "Setting up bob configuration"
|
||||||
x-path-prepend "$XDG_DATA_HOME/bob/nvim-bin"
|
x-path-prepend "$XDG_DATA_HOME/bob/nvim-bin"
|
||||||
@@ -370,11 +389,12 @@ export PATH="$COMPOSER_BIN:$PATH"
|
|||||||
# direnv, https://direnv.net/
|
# direnv, https://direnv.net/
|
||||||
# https://direnv.net/docs/hook.html
|
# https://direnv.net/docs/hook.html
|
||||||
# Set the hook to show the direnv message in a different color
|
# Set the hook to show the direnv message in a different color
|
||||||
export DIRENV_LOG_FORMAT=$'\033[2mdirenv: %s\033[0m'
|
# export DIRENV_LOG_FORMAT=$'\033[2mdirenv: %s\033[0m'
|
||||||
|
export DIRENV_LOG_FORMAT=
|
||||||
|
|
||||||
# docker, https://docs.docker.com/engine/reference/commandline/cli/
|
# docker, https://docs.docker.com/engine/reference/commandline/cli/
|
||||||
msg "Setting up Docker configuration"
|
msg "Setting up Docker configuration"
|
||||||
export DOCKER_CONFIG="$XDG_CONFIG_HOME/docker"
|
export DOCKER_CONFIG="${XDG_CONFIG_HOME}/docker"
|
||||||
x-dc "$DOCKER_CONFIG"
|
x-dc "$DOCKER_CONFIG"
|
||||||
# Docker: Disable snyk ad
|
# Docker: Disable snyk ad
|
||||||
export DOCKER_SCAN_SUGGEST=false
|
export DOCKER_SCAN_SUGGEST=false
|
||||||
@@ -388,7 +408,7 @@ x-have ffmpeg && x-dc "$FFMPEG_DATADIR"
|
|||||||
# GnuPG
|
# GnuPG
|
||||||
# https://gnupg.org/documentation/manuals/gnupg/Invoking-GPG.html
|
# https://gnupg.org/documentation/manuals/gnupg/Invoking-GPG.html
|
||||||
msg "Setting up GnuPG configuration"
|
msg "Setting up GnuPG configuration"
|
||||||
export GNUPGHOME="$XDG_DATA_HOME/gnupg"
|
export GNUPGHOME="${XDG_DATA_HOME}/gnupg"
|
||||||
|
|
||||||
# Go
|
# Go
|
||||||
# https://golang.org/doc/code.html
|
# https://golang.org/doc/code.html
|
||||||
@@ -448,6 +468,7 @@ msg "Setting up Rust/Cargo configuration"
|
|||||||
export RUSTUP_HOME="$XDG_DATA_HOME/rustup"
|
export RUSTUP_HOME="$XDG_DATA_HOME/rustup"
|
||||||
export CARGO_HOME="$XDG_DATA_HOME/cargo"
|
export CARGO_HOME="$XDG_DATA_HOME/cargo"
|
||||||
export PATH="$CARGO_HOME/bin:$PATH"
|
export PATH="$CARGO_HOME/bin:$PATH"
|
||||||
|
export RUST_WITHOUT=rust-docs
|
||||||
|
|
||||||
# screen
|
# screen
|
||||||
# https://www.gnu.org/software/screen/manual/screen.html
|
# https://www.gnu.org/software/screen/manual/screen.html
|
||||||
|
|||||||
@@ -17,11 +17,12 @@
|
|||||||
llog = log --pretty=fuller
|
llog = log --pretty=fuller
|
||||||
logs = log --graph --pretty=format:'%C(magenta)%h%Creset -%C(red)%d%Creset %s %C(dim green)(%cr) %C(cyan)<%an>%Creset' --abbrev-commit
|
logs = log --graph --pretty=format:'%C(magenta)%h%Creset -%C(red)%d%Creset %s %C(dim green)(%cr) %C(cyan)<%an>%Creset' --abbrev-commit
|
||||||
nah = !git reset --hard && git clean -df
|
nah = !git reset --hard && git clean -df
|
||||||
|
recent = "!r() { count=$1; git for-each-ref --sort=-committerdate refs/heads --format='%(HEAD)%(color:yellow)%(refname:short)|%(color:bold green)%(committerdate:relative)|%(color:blue)%(subject)|%(color:magenta)%(authorname)%(color:reset)' --color=always --count=${count:=10} | column -ts'|';}; r"
|
||||||
reset-origin = !git fetch origin && git reset --hard origin/master && git clean -f -d
|
reset-origin = !git fetch origin && git reset --hard origin/master && git clean -f -d
|
||||||
reset-upstream = !git fetch upstream && git reset --hard upstream/master && git clean -f -d
|
reset-upstream = !git fetch upstream && git reset --hard upstream/master && git clean -f -d
|
||||||
recent = "!r() { count=$1; git for-each-ref --sort=-committerdate refs/heads --format='%(HEAD)%(color:yellow)%(refname:short)|%(color:bold green)%(committerdate:relative)|%(color:blue)%(subject)|%(color:magenta)%(authorname)%(color:reset)' --color=always --count=${count:=10} | column -ts'|';}; r"
|
|
||||||
rl = reflog --format='%C(auto)%h %<|(20)%gd %C(blue)%cr%C(reset) %gs (%s)'
|
rl = reflog --format='%C(auto)%h %<|(20)%gd %C(blue)%cr%C(reset) %gs (%s)'
|
||||||
tagdate = log --date-order --graph --tags --simplify-by-decoration --pretty=format:\"%ai %h %d\"
|
tagdate = log --date-order --graph --tags --simplify-by-decoration --pretty=format:\"%ai %h %d\"
|
||||||
|
undo = reset --soft HEAD^
|
||||||
undo-commit = reset HEAD~ --soft
|
undo-commit = reset HEAD~ --soft
|
||||||
|
|
||||||
[filter "lfs"]
|
[filter "lfs"]
|
||||||
@@ -30,15 +31,6 @@
|
|||||||
process = git-lfs filter-process
|
process = git-lfs filter-process
|
||||||
required = true
|
required = true
|
||||||
|
|
||||||
[diff]
|
|
||||||
tool = difftastic
|
|
||||||
|
|
||||||
[difftool]
|
|
||||||
prompt = false
|
|
||||||
|
|
||||||
[difftool "difftastic"]
|
|
||||||
cmd = difft "$LOCAL" "$REMOTE"
|
|
||||||
|
|
||||||
[color]
|
[color]
|
||||||
ui = true
|
ui = true
|
||||||
diff = auto
|
diff = auto
|
||||||
|
|||||||
Submodule config/nvim-kickstart updated: 7fb183eee3...d1d9f7b214
@@ -32,4 +32,4 @@
|
|||||||
"NEWS.md": "6520"
|
"NEWS.md": "6520"
|
||||||
},
|
},
|
||||||
"version": 6
|
"version": 6
|
||||||
}
|
}
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
blade-formatter
|
|
||||||
corepack
|
|
||||||
editorconfig-checker
|
|
||||||
github-release-notes
|
|
||||||
neovim
|
|
||||||
stylelint-lsp
|
|
||||||
|
|
||||||
@@ -29,13 +29,15 @@ type = "prompt"
|
|||||||
style = "mixed"
|
style = "mixed"
|
||||||
|
|
||||||
[blocks.segments.mapped_locations]
|
[blocks.segments.mapped_locations]
|
||||||
"~/Code/*" = ""
|
"~/Code/*" = ""
|
||||||
|
"~/Code/ivuorinen/" = ""
|
||||||
|
|
||||||
[[blocks.segments]]
|
[[blocks.segments]]
|
||||||
type = "git"
|
type = "git"
|
||||||
style = "plain"
|
style = "plain"
|
||||||
foreground = "lightGreen"
|
foreground = "lightGreen"
|
||||||
template = "{{ .UpstreamIcon }}{{ if or (.Staging.Changed) (.Working.Changed) }}({{if .Behind }}\u2193 {{ .Behind }} {{ end }}{{if .Staging.Changed }}\uF046 {{ .Staging.String }} {{ end }}{{ if and (.Staging.Changed) (.Working.Changed) }}| {{ end }}{{ if .Working.Changed }} {{ .Working.String }}{{ end }}){{ end }}"
|
# template = "{{ .UpstreamIcon }}{{ .HEAD }} {{ if or (.Staging.Changed) (.Working.Changed) }}({{if .Behind }}\u2193 {{ .Behind }} {{ end }}{{if .Staging.Changed }}\uF046 {{ .Staging.String }} {{ end }}{{ if and (.Staging.Changed) (.Working.Changed) }}| {{ end }}{{ if .Working.Changed }} {{ .Working.String }}{{ end }}){{ end }}"
|
||||||
|
template = "{{ .UpstreamIcon }}{{ .HEAD }}{{if .BranchStatus }} {{ .BranchStatus }}{{ end }}{{ if .Working.Changed }} {{ .Working.String }}{{ end }}{{ if and (.Working.Changed) (.Staging.Changed) }} |{{ end }}{{ if .Staging.Changed }} {{ .Staging.String }}{{ end }}{{ if gt .StashCount 0 }} {{ .StashCount }}{{ end }}"
|
||||||
|
|
||||||
[blocks.segments.properties]
|
[blocks.segments.properties]
|
||||||
fetch_status = true
|
fetch_status = true
|
||||||
|
|||||||
@@ -53,6 +53,7 @@
|
|||||||
mode: 0600
|
mode: 0600
|
||||||
path: ssh/*
|
path: ssh/*
|
||||||
- shell:
|
- shell:
|
||||||
|
- bash add-submodules.sh
|
||||||
- git submodule update --init --recursive --force
|
- git submodule update --init --recursive --force
|
||||||
- bash local/bin/dfm install all
|
- bash local/bin/dfm install all
|
||||||
- pipx:
|
- pipx:
|
||||||
|
|||||||
@@ -161,7 +161,7 @@ section_install()
|
|||||||
;;
|
;;
|
||||||
asdf)
|
asdf)
|
||||||
msg "Installing asdf..."
|
msg "Installing asdf..."
|
||||||
bash "$DOTFILES/scripts/install-asdf.sh install" \
|
bash "$DOTFILES/scripts/install-asdf.sh both" \
|
||||||
&& msg_yay "asdf installed!"
|
&& msg_yay "asdf installed!"
|
||||||
;;
|
;;
|
||||||
cargo)
|
cargo)
|
||||||
|
|||||||
99
local/bin/x-term-colors
Executable file
99
local/bin/x-term-colors
Executable file
@@ -0,0 +1,99 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
#
|
||||||
|
# This file echoes a bunch of 24-bit color codes
|
||||||
|
# to the terminal to demonstrate its functionality.
|
||||||
|
# The foreground escape sequence is ^[38;2;<r>;<g>;<b>m
|
||||||
|
# The background escape sequence is ^[48;2;<r>;<g>;<b>m
|
||||||
|
# <r> <g> <b> range from 0 to 255 inclusive.
|
||||||
|
# The escape sequence ^[0m returns output to default
|
||||||
|
|
||||||
|
setBackgroundColor()
|
||||||
|
{
|
||||||
|
echo -en "\x1b[48;2;$1;$2;$3""m"
|
||||||
|
}
|
||||||
|
|
||||||
|
resetOutput()
|
||||||
|
{
|
||||||
|
echo -en "\x1b[0m\n"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Gives a color $1/255 % along HSV
|
||||||
|
# Who knows what happens when $1 is outside 0-255
|
||||||
|
# Echoes "$red $green $blue" where
|
||||||
|
# $red $green and $blue are integers
|
||||||
|
# ranging between 0 and 255 inclusive
|
||||||
|
rainbowColor()
|
||||||
|
{
|
||||||
|
let h=$1/43
|
||||||
|
let f=$1-43*$h
|
||||||
|
let t=$f*255/43
|
||||||
|
let q=255-t
|
||||||
|
|
||||||
|
if [ $h -eq 0 ]
|
||||||
|
then
|
||||||
|
echo "255 $t 0"
|
||||||
|
elif [ $h -eq 1 ]
|
||||||
|
then
|
||||||
|
echo "$q 255 0"
|
||||||
|
elif [ $h -eq 2 ]
|
||||||
|
then
|
||||||
|
echo "0 255 $t"
|
||||||
|
elif [ $h -eq 3 ]
|
||||||
|
then
|
||||||
|
echo "0 $q 255"
|
||||||
|
elif [ $h -eq 4 ]
|
||||||
|
then
|
||||||
|
echo "$t 0 255"
|
||||||
|
elif [ $h -eq 5 ]
|
||||||
|
then
|
||||||
|
echo "255 0 $q"
|
||||||
|
else
|
||||||
|
# execution should never reach here
|
||||||
|
echo "0 0 0"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
for i in $(seq 0 127); do
|
||||||
|
setBackgroundColor "$i" 0 0
|
||||||
|
echo -en " "
|
||||||
|
done
|
||||||
|
resetOutput
|
||||||
|
for i in $(seq 255 128); do
|
||||||
|
setBackgroundColor "$i" 0 0
|
||||||
|
echo -en " "
|
||||||
|
done
|
||||||
|
resetOutput
|
||||||
|
|
||||||
|
for i in $(seq 0 127); do
|
||||||
|
setBackgroundColor 0 "$i" 0
|
||||||
|
echo -n " "
|
||||||
|
done
|
||||||
|
resetOutput
|
||||||
|
for i in $(seq 255 128); do
|
||||||
|
setBackgroundColor 0 "$i" 0
|
||||||
|
echo -n " "
|
||||||
|
done
|
||||||
|
resetOutput
|
||||||
|
|
||||||
|
for i in $(seq 0 127); do
|
||||||
|
setBackgroundColor 0 0 "$i"
|
||||||
|
echo -n " "
|
||||||
|
done
|
||||||
|
resetOutput
|
||||||
|
for i in $(seq 255 128); do
|
||||||
|
setBackgroundColor 0 0 "$i"
|
||||||
|
echo -n " "
|
||||||
|
done
|
||||||
|
resetOutput
|
||||||
|
|
||||||
|
for i in $(seq 0 127); do
|
||||||
|
setBackgroundColor $(rainbowColor "$i")
|
||||||
|
echo -n " "
|
||||||
|
done
|
||||||
|
resetOutput
|
||||||
|
for i in $(seq 255 128); do
|
||||||
|
setBackgroundColor $(rainbowColor "$i")
|
||||||
|
echo -n " "
|
||||||
|
done
|
||||||
|
resetOutput
|
||||||
|
|
||||||
@@ -2,7 +2,6 @@
|
|||||||
"name": "ivuorinen-dotfiles",
|
"name": "ivuorinen-dotfiles",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"description": "ivuorinen's dotfiles, this is for linting and formatters",
|
"description": "ivuorinen's dotfiles, this is for linting and formatters",
|
||||||
"main": "index.js",
|
|
||||||
"directories": {
|
"directories": {
|
||||||
"doc": "docs"
|
"doc": "docs"
|
||||||
},
|
},
|
||||||
@@ -28,8 +27,7 @@
|
|||||||
},
|
},
|
||||||
"homepage": "https://github.com/ivuorinen/dotfiles#readme",
|
"homepage": "https://github.com/ivuorinen/dotfiles#readme",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@ivuorinen/base-configs": "^2.0.0",
|
"@ivuorinen/base-configs": "^2.0.0"
|
||||||
"prettier-plugin-sh": "^0.14.0"
|
|
||||||
},
|
},
|
||||||
"packageManager": "yarn@1.22.22"
|
"packageManager": "yarn@1.22.22"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,13 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
#
|
#
|
||||||
# Install asdf
|
# Install asdf and plugins I use
|
||||||
|
#
|
||||||
|
# It also updates asdf and the plugins, and then reshim asdf.
|
||||||
|
#
|
||||||
|
# Usage: ./install-asdf.sh [both|install|add_plugins]
|
||||||
|
# Author: Ismo Vuorinen <https://github.com/ivuorinen>
|
||||||
|
# License: MIT
|
||||||
|
#
|
||||||
source "${DOTFILES}/config/shared.sh"
|
source "${DOTFILES}/config/shared.sh"
|
||||||
|
|
||||||
export ASDF_DIR="${XDG_BIN_HOME}/asdf"
|
export ASDF_DIR="${XDG_BIN_HOME}/asdf"
|
||||||
@@ -40,19 +47,16 @@ install_asdf_plugins()
|
|||||||
"hadolint:github.com/devlincashman/asdf-hadolint.git"
|
"hadolint:github.com/devlincashman/asdf-hadolint.git"
|
||||||
"kubectl:github.com/asdf-community/asdf-kubectl.git"
|
"kubectl:github.com/asdf-community/asdf-kubectl.git"
|
||||||
"lazygit:github.com/nklmilojevic/asdf-lazygit.git"
|
"lazygit:github.com/nklmilojevic/asdf-lazygit.git"
|
||||||
"markdownlint-cli2:github.com/paulo-ferraz-oliveira/asdf-markdownlint-cli2.git"
|
|
||||||
"nodejs:github.com/asdf-vm/asdf-nodejs.git"
|
"nodejs:github.com/asdf-vm/asdf-nodejs.git"
|
||||||
"pipx:github.com/yozachar/asdf-pipx.git"
|
"pipx:github.com/yozachar/asdf-pipx.git"
|
||||||
"pre-commit:github.com/jonathanmorley/asdf-pre-commit.git"
|
"pre-commit:github.com/jonathanmorley/asdf-pre-commit.git"
|
||||||
"python:github.com/asdf-community/asdf-python.git"
|
"python:github.com/asdf-community/asdf-python.git"
|
||||||
"ripgrep:gitlab.com/wt0f/asdf-ripgrep.git"
|
"ripgrep:gitlab.com/wt0f/asdf-ripgrep.git"
|
||||||
"rust:github.com/code-lever/asdf-rust.git"
|
"rust:github.com/code-lever/asdf-rust.git"
|
||||||
"semgrep:github.com/brentjanderson/asdf-semgrep.git"
|
|
||||||
"shellcheck:github.com/luizm/asdf-shellcheck.git"
|
"shellcheck:github.com/luizm/asdf-shellcheck.git"
|
||||||
"shfmt:github.com/luizm/asdf-shfmt.git"
|
"shfmt:github.com/luizm/asdf-shfmt.git"
|
||||||
"terragrunt:github.com/ohmer/asdf-terragrunt.git"
|
"terragrunt:github.com/ohmer/asdf-terragrunt.git"
|
||||||
"tf-summarize:github.com/adamcrews/asdf-tf-summarize.git"
|
"tf-summarize:github.com/adamcrews/asdf-tf-summarize.git"
|
||||||
"vault:github.com/asdf-community/asdf-hashicorp.git"
|
|
||||||
"yamllint:github.com/ericcornelissen/asdf-yamllint.git"
|
"yamllint:github.com/ericcornelissen/asdf-yamllint.git"
|
||||||
"yq:github.com/sudermanjr/asdf-yq.git"
|
"yq:github.com/sudermanjr/asdf-yq.git"
|
||||||
)
|
)
|
||||||
@@ -83,13 +87,18 @@ reshim()
|
|||||||
# create usage function
|
# create usage function
|
||||||
usage()
|
usage()
|
||||||
{
|
{
|
||||||
echo "Usage: $0 [install|add_plugins]"
|
echo "Usage: $0 [both|install|add_plugins]"
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
main()
|
main()
|
||||||
{
|
{
|
||||||
case $1 in
|
case $1 in
|
||||||
|
"both")
|
||||||
|
install_asdf_plugins
|
||||||
|
update_asdf
|
||||||
|
reshim
|
||||||
|
;;
|
||||||
"install")
|
"install")
|
||||||
update_asdf
|
update_asdf
|
||||||
reshim
|
reshim
|
||||||
|
|||||||
@@ -2,6 +2,10 @@
|
|||||||
# Install cargo/rust packages.
|
# Install cargo/rust packages.
|
||||||
#
|
#
|
||||||
# shellcheck source=shared.sh
|
# shellcheck source=shared.sh
|
||||||
|
|
||||||
|
echo "This file has been deprecated in favor of asdf. Please use asdf instead."
|
||||||
|
exit 0
|
||||||
|
|
||||||
eval "$HOME/.dotfiles/config/shared.sh"
|
eval "$HOME/.dotfiles/config/shared.sh"
|
||||||
|
|
||||||
msg "Starting to install rust/cargo packages"
|
msg "Starting to install rust/cargo packages"
|
||||||
|
|||||||
@@ -2,6 +2,10 @@
|
|||||||
# Install Go packages
|
# Install Go packages
|
||||||
#
|
#
|
||||||
# shellcheck source=shared.sh
|
# shellcheck source=shared.sh
|
||||||
|
|
||||||
|
echo "This file has been deprecated in favor of asdf. Please use asdf instead."
|
||||||
|
exit 0
|
||||||
|
|
||||||
eval "$DOTFILES/config/shared.sh"
|
eval "$DOTFILES/config/shared.sh"
|
||||||
|
|
||||||
# Enable verbosity with VERBOSE=1
|
# Enable verbosity with VERBOSE=1
|
||||||
|
|||||||
@@ -2,6 +2,10 @@
|
|||||||
# Install npm packages globally.
|
# Install npm packages globally.
|
||||||
#
|
#
|
||||||
# shellcheck source=shared.sh
|
# shellcheck source=shared.sh
|
||||||
|
|
||||||
|
echo "This file has been deprecated in favor of asdf. Please use asdf instead."
|
||||||
|
exit 0
|
||||||
|
|
||||||
eval "$DOTFILES/config/shared.sh"
|
eval "$DOTFILES/config/shared.sh"
|
||||||
|
|
||||||
# Enable verbosity with VERBOSE=1
|
# Enable verbosity with VERBOSE=1
|
||||||
|
|||||||
@@ -2,6 +2,10 @@
|
|||||||
# Install python/pip packages.
|
# Install python/pip packages.
|
||||||
#
|
#
|
||||||
# shellcheck source=shared.sh
|
# shellcheck source=shared.sh
|
||||||
|
|
||||||
|
echo "This file has been deprecated in favor of asdf. Please use asdf instead."
|
||||||
|
exit 0
|
||||||
|
|
||||||
source "${DOTFILES}/config/shared.sh"
|
source "${DOTFILES}/config/shared.sh"
|
||||||
|
|
||||||
# Enable verbosity with VERBOSE=1
|
# Enable verbosity with VERBOSE=1
|
||||||
|
|||||||
Reference in New Issue
Block a user