Compare commits

...

137 Commits

Author SHA1 Message Date
ivuorinen
6734d3c1ab chore(git): Update submodules (automated)
config/nvim v3.29.5
2023-06-30 03:09:11 +00:00
ivuorinen
b20d08aa69 chore(git): Update submodules (automated)
config/nvim v3.29.3
2023-06-29 03:11:44 +00:00
ivuorinen
e4da7534f8 chore(git): Update submodules (automated)
config/nvim v3.28.3
2023-06-27 03:15:32 +00:00
b39f7ec598 chore(brew): Update Brewfile 2023-06-26 12:13:39 +03:00
ivuorinen
0f8c1ef457 chore(git): Update submodules (automated)
config/nvim v3.27.1
2023-06-24 03:14:34 +00:00
ivuorinen
4b31ad9a7b chore(git): Update submodules (automated)
config/nvim v3.26.0
2023-06-23 03:16:40 +00:00
4d60d15831 feat(config): Added git recent alias 2023-06-22 14:50:06 +03:00
ivuorinen
90125c7278 chore(git): Update submodules (automated)
config/nvim v3.25.0
2023-06-22 03:04:44 +00:00
0035575f8b chore(brew): Update Brewfile 2023-06-21 23:04:43 +03:00
ivuorinen
865c0aa33b chore(git): Update submodules (automated)
config/nvim v3.24.1
2023-06-20 03:04:55 +00:00
renovate[bot]
5fe7bc3527 chore(deps): update python docker tag to v3.11 (#8)
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-06-18 22:05:47 +03:00
0d1b35ef09 chore(config): Update Python version to 3.10 2023-06-18 21:44:13 +03:00
ivuorinen
bee0340493 chore(git): Update submodules (automated)
config/nvim v3.23.1
2023-06-16 03:04:43 +00:00
fbdc9c741a chore(astronvim): Tweaked neo-tree configurations 2023-06-14 08:51:40 +03:00
0ac0d05db6 chore(config): Update iterm2 configuration 2023-06-14 01:13:24 +03:00
1c432da880 chore(brew): Update Brewfile 2023-06-13 08:30:49 +03:00
ivuorinen
7e0cc9ec43 chore(git): Update submodules (automated)
config/nvim v3.22.1
2023-06-13 03:04:47 +00:00
ivuorinen
8c4b6d2983 chore(git): Update submodules (automated)
config/nvim v3.22.0
2023-06-10 03:04:35 +00:00
ivuorinen
5b4cf1bb2f chore(git): Update submodules (automated)
config/nvim v3.21.0
2023-06-09 03:10:46 +00:00
c9edd4bf84 chore(config): Update iterm2 configuration 2023-06-08 14:32:57 +03:00
1023228ddc chore(zsh): Moved brew autocomplete config 2023-06-08 14:32:19 +03:00
8f8851d08f chore(astronvim): Updated configurations
- Comment line changes
- Open trouble automagically
- Do not hide gitignored files from tree
- Tweaked nyancat dashboard header
2023-06-08 14:31:16 +03:00
2b06642e4b chore(docs): Update README and add screenshots 2023-06-08 14:28:52 +03:00
ivuorinen
52cbebc0b3 chore(git): Update submodules (automated)
config/nvim v3.19.1
2023-06-07 03:09:02 +00:00
2b64164f2b chore(brew): Update Brewfile 2023-06-06 06:53:06 +03:00
7c8fb993a2 chore(zsh): Update zsh completion locations 2023-06-06 06:53:06 +03:00
ivuorinen
e745583f07 chore(git): Update submodules (automated)
config/nvim v3.19.0
2023-06-06 03:09:41 +00:00
5762d57eb1 chore(config): Update iterm2 configuration 2023-06-05 22:29:04 +03:00
ivuorinen
4b1d860cb5 chore(git): Update submodules (automated)
config/nvim v3.18.1
2023-06-04 03:15:29 +00:00
ivuorinen
288580c150 chore(git): Update submodules (automated)
config/nvim v3.18.0
2023-06-03 03:04:32 +00:00
ivuorinen
e535301139 chore(git): Update submodules (automated)
config/nvim v3.17.0
2023-06-02 03:05:03 +00:00
58ba14aa47 feat(docs): Added nvim keybindings cheatsheet 2023-05-31 13:08:39 +03:00
ivuorinen
a4a0d2e0f1 chore(git): Update submodules (automated)
config/nvim v3.16.2
2023-05-31 03:08:06 +00:00
c953f902ca chore(github): Updated new release cron schedule
- Updated cron schedule to match better my timezone.
- Added check for 'Create release' step
2023-05-30 11:50:00 +03:00
3d917454a0 chore(brew): Update Brewfile 2023-05-27 18:27:11 +03:00
5b34ecfb97 feat(tmux): Adds ChanderG/tmux-notify 2023-05-26 17:06:04 +03:00
1817cf6962 feat(tmux): Adds yardnsm/tmux-1password 2023-05-26 14:04:57 +03:00
bc914a1c5f feat(tmux): Adds b0o/tmux-autoreload, entr
Also fixes some minor configuration problems.
2023-05-26 13:45:44 +03:00
48b9df95ab fix(tmux): Fix tmux configs 2023-05-26 12:57:41 +03:00
2799e80b2d chore(brew): Update Brewfile 2023-05-26 12:40:12 +03:00
ivuorinen
5bbc241ec9 chore(git): Update submodules (automated)
config/nvim v3.16.0
2023-05-26 03:04:37 +00:00
5e00422a28 feat(zsh): Updated nvm-auto-use
Source: https://github.com/nvm-sh/nvm#zsh
2023-05-24 14:22:08 +03:00
ivuorinen
44eacf9261 chore(git): Update submodules (automated)
config/nvim v3.15.11
2023-05-24 03:04:45 +00:00
4f2c1f0b9b fix(github): Fix changelog config locations 2023-05-22 17:55:07 +03:00
0fdc9fd08a feat(github): Update changelog workflow and config 2023-05-22 17:52:43 +03:00
65aaa4bec2 chore(config): Update ssh/allowed_signers file 2023-05-22 16:13:45 +03:00
a8835daede chore(config): Update iterm2 configuration 2023-05-22 16:12:03 +03:00
39ddc2ae00 feat(dfm): Add dfm docs tmux
This command will update docs/tmux-keybindings.md file that contains
all configured tmux keybindings.
2023-05-22 16:11:31 +03:00
06c2686815 feat(github): Add changelog workflow config 2023-05-22 16:09:16 +03:00
b259e4b992 chore(codestyle): Code style fixes, configs 2023-05-22 15:59:58 +03:00
ivuorinen
47703cd182 chore(git): Update submodules (automated)
tmux/tpm v3.0.0
2023-05-22 03:04:40 +00:00
6d31371af4 chore(actions): Submodule update action tweaks 2023-05-22 00:40:20 +03:00
c2250ee80c chore(tmux): Update tpm 2023-05-21 14:04:03 +03:00
a1d075fc0d fix(shell): Fix LC_ALL locale 2023-05-21 13:44:39 +03:00
a3cc12aae1 feat(config): git user profile for github 2023-05-21 13:30:43 +03:00
808748a050 fix(shell): Fix tool paths from append to prepend 2023-05-21 13:30:05 +03:00
ivuorinen
e29507ee61 Update submodules (automated)
config/nvim v3.15.10
2023-05-20 15:14:36 +00:00
bd6408b024 fix(config): git user home profile config typo 2023-05-17 17:07:31 +03:00
45cf9ef2a5 Fix(github): Changelog generator fixes 2023-05-17 16:23:24 +03:00
5cc78e14e4 Fix(github): Changelog generator fixes 2023-05-17 16:15:41 +03:00
5683809e18 Feat(github): Debug changelog generation 2023-05-17 16:05:11 +03:00
723d40a704 Chore(nvim): Cleanup of nvim lsp settings
Dropped lsp configs

mason (ensure installed):
- ansiblels
- bashls
- clangd
- codeqlls
- cssls

null-ls:
- null_ls.builtins.formatting.prettierd
2023-05-17 09:28:45 +03:00
renovate[bot]
55ce79d9d1 chore(deps): update actions/github-script action to v6 (#7) 2023-05-16 07:51:55 +03:00
renovate[bot]
fdd3845cf5 chore(deps): update actions/github-script action to v5.2.0 (#6)
Signed-off-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-05-16 00:07:54 +03:00
3e911755d2 Feat(github): Daily version for archiving purposes 2023-05-15 20:22:46 +03:00
f3dff521f7 Feat(npm): Removed prettier from global install
prettier was being detected by nvim and run with default configuration
in projects that it shouldn't have run in. Because of that the package
should be installed only project by project basis.
2023-05-15 19:25:13 +03:00
cf1ccd6f39 Feat(cheat): personal/git-alias 2023-05-15 15:49:55 +03:00
2e963fa29e Feat(config): Deduplicate git config, add special 2023-05-15 15:49:10 +03:00
ivuorinen
f595d437c9 Update submodules (automated)
tmux/tpm v3.0.0
dotbot v1.19.1
2023-05-15 11:09:57 +00:00
e7d0b4167a fix(github): Drop GPG -S from submodule commit 2023-05-15 14:09:15 +03:00
f20fe04ed8 Feat(github): git submodule update workflow 2023-05-15 13:58:59 +03:00
2b78d648c2 Chore(git): Update gitmodules to follow tags 2023-05-15 13:40:34 +03:00
ae2deef5fa fix(github): Fix dependabot configuration 2023-05-15 13:29:38 +03:00
8fc60ade75 Feat(github): GitHub Actions Update workflow 2023-05-15 13:26:35 +03:00
34160d34dc Feat(config): Taskwarrior configuration 2023-05-15 13:24:45 +03:00
5fab8e1cab Feat(github): Submodule update workflow 2023-05-15 13:23:54 +03:00
1a612fef62 Chore(nvim): Cleanup of nvim plugins 2023-05-15 13:22:50 +03:00
ce5e9681fd Chore(packages): Removal of standardjs 2023-05-15 11:04:33 +03:00
cab855380f feat(nvim): Update astronvim to v3.15.6 2023-05-11 17:31:07 +03:00
e7578e4905 Chore(scripts): Simplification and documentation 2023-05-10 02:07:27 +03:00
3fce0ac4dc fix(scripts): Fix x-backup-folder error prone code 2023-05-10 00:30:33 +03:00
b89213ffb5 Chore(lint): markdownlint config changes, tweak 2023-05-08 20:44:45 +03:00
823e9cc381 Feat(tools): nb 2023-05-08 20:43:59 +03:00
8be55a7c76 Chore(lint): markdownlint config 2023-05-08 14:14:46 +03:00
f4fb53abaa Chore(lint): Change name for Codacy 2023-05-08 13:24:47 +03:00
66c31c3d3f Chore(tools): Added phpcs & fixed x-quota-usage 2023-05-08 13:01:28 +03:00
1a8c32bf4c Chore(iterm2): Config update 2023-05-08 12:18:33 +03:00
864fbc18da feat(dfm): Install cheat databases with dfm 2023-05-08 12:18:10 +03:00
b688ee7503 Chore(tools): Moved dotbot under tools 2023-05-08 12:16:45 +03:00
9dfb7a3c4a Chore: Added .gitkeep files to cheatsheet folders 2023-05-08 11:30:18 +03:00
192ca6d26c Chore(cheat): use fzf with cheat 2023-05-08 09:10:21 +03:00
b5dd8c3eab feat(tmux): New plugins and configurations 2023-05-07 23:50:57 +03:00
d2a84e6d20 feat(nvim): Update astronvim to v3.15.2 2023-05-07 23:00:56 +03:00
e29bd04c7d Chore(cheat): tldr pages tweaks 2023-05-07 22:58:28 +03:00
2b6fa42f17 Chore: Lots of little tweaks 2023-05-05 23:03:42 +03:00
8de487250d Feat: Pure Bash Bible and TLDR in cheat 2023-05-05 23:02:31 +03:00
e5fe49834d Fix: Changes to have command usage 2023-05-05 22:59:14 +03:00
edd56c80eb feat(nvim): Update astronvim and tweak null-ls 2023-05-03 16:22:32 +03:00
eaedd40e06 feat(tmux): Plugins and configurations 2023-05-03 16:22:02 +03:00
06a53759ac chore(astronvim): Plugins reshuffle 2023-05-03 09:17:01 +03:00
3c98117c05 Chore: Update astronvim, tweak gitmodules 2023-05-02 14:47:49 +03:00
c3aa6b77e5 Chore: Fixes, repo dotfiles 2023-04-30 14:56:30 +03:00
66739fa765 Fix: Make sure personal cheatsheet folder exists 2023-04-28 14:53:43 +03:00
ff01a27b3c Chore: Deleted install-without-plugins 2023-04-28 14:50:57 +03:00
383855f23a Feat: fzf, configs and installer 2023-04-27 22:58:34 +03:00
a5db6a465e Chore: Catppuccin config, alpha-nvim header 2023-04-27 22:53:22 +03:00
293b847f79 Fix: Formatting, chmod +x magick 2023-04-27 16:39:06 +03:00
df14c71c17 Feat: Install neofetch 2023-04-27 16:38:26 +03:00
29d46c5790 Feat: nvim neo-tree configuration 2023-04-27 15:29:27 +03:00
d6565761ab Chore: Codestyle changes, split lines that went over limit 2023-04-27 15:27:17 +03:00
0feb7a47ae Chore: Document go packages, add glow 2023-04-27 15:09:34 +03:00
161d0b8875 Chore: Package maintenance 2023-04-27 11:57:27 +03:00
d7f7240348 Fix: tmux colors 2023-04-27 11:56:25 +03:00
7de714161c Feat: Update iTerm2 config, add itermcolors 2023-04-27 11:56:11 +03:00
263fca5839 Feat: Configuration updates 2023-04-27 01:12:31 +03:00
02577547ce Feat: Removed js-debug, added tldr 2023-04-26 23:55:49 +03:00
7f11a7073e Fix: Removed dotbot-gh-extension 2023-04-26 23:54:48 +03:00
af38f7aa45 Chore: cheat color scheme is now catppuccin-mocha 2023-04-26 23:47:50 +03:00
74df61ed1d Feat: tmux config + plugin manager 2023-04-26 23:45:28 +03:00
6126827503 Feat: Moved astronvim user config from submodule 2023-04-26 23:44:19 +03:00
fb48a86b27 Chore: Move renovate config under .github 2023-04-24 23:10:39 +03:00
f84d70ea61 Chore: Update nvim user config 2023-04-24 22:27:01 +03:00
14f02a2b93 Config: Disable snyk ad 2023-04-24 22:17:49 +03:00
9f60efee33 Chore: Update nvim 2023-04-24 22:16:59 +03:00
a834a9138a CI: Shellcheck ignore 1091 2023-04-24 16:58:57 +03:00
3a9ca6edab Chore: Update Brewfile 2023-04-24 16:24:20 +03:00
d8292ca033 fmt + brewfile update 2023-04-22 14:57:27 +03:00
e929b85669 brew: fzf 2023-04-22 14:56:34 +03:00
775d2abf13 tools: cheat configs & dirs 2023-04-22 11:17:36 +03:00
740ad17207 Tool: cheat, yamllint configs 2023-04-21 01:45:43 +03:00
c9d0284c91 dfm: Install command improvements 2023-04-18 07:44:01 +03:00
ac8b7beb9b scripts: x-hr & x-welxome-banner 2023-04-17 23:16:33 +03:00
2fa6c69e4a Submodule updates 2023-04-17 09:05:33 +03:00
c1287c4ea8 dfm: menu rework, docs. codestyle fixes. 2023-04-14 10:10:32 +03:00
7b63afd4f5 dfm: Fix imagick installation 2023-04-14 00:48:37 +03:00
e5d6cb37fd shell: have, path_(append|prepend|remove)
- have: command -v shorthand
- path_append: appends dir to PATH
- path_prepend: prepends dir to PATH
- path_remove: removes dir from PATH
2023-04-14 00:42:08 +03:00
4492c386b6 dfm: rewrote the usage menu generation 2023-04-14 00:01:58 +03:00
107 changed files with 6582 additions and 614 deletions

3
.actrc Normal file
View File

@@ -0,0 +1,3 @@
--container-architecture linux/amd64
--env-file .env
--secret-file .env

19
.ecrc Normal file
View File

@@ -0,0 +1,19 @@
{
"Version": "2.7.0",
"Verbose": false,
"Debug": false,
"IgnoreDefaults": false,
"SpacesAftertabs": false,
"NoColor": false,
"Exclude": [],
"AllowedContentTypes": [],
"PassedFiles": [],
"Disable": {
"EndOfLine": false,
"Indentation": false,
"InsertFinalNewline": false,
"TrimTrailingWhitespace": false,
"IndentSize": false,
"MaxLineLength": false
}
}

View File

@@ -8,24 +8,22 @@ indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
[*.lua]
insert_final_newline = true
[*.php]
indent_size = 4
[*.yaml]
indent_size = 2
insert_final_newline = true
[.git{ignore,modules}]
indent_style = tab
indent_size = 1
[*.yml]
indent_size = 2
insert_final_newline = true
[*.plist]
indent_size = 1
indent_style = tab
[*.sh]
indent_size = 2
indent_style = space
insert_final_newline = true
[local/bin/*]
shell_variant = bash # --language-variant
binary_next_line = true
switch_case_indent = true # --case-indent
space_redirects = false
keep_padding = false
function_next_line = true # --func-next-line
switch_case_indent = true # --case-indent
space_redirects = true
keep_padding = true
function_next_line = true # --func-next-line

8
.github/dependabot.yml vendored Normal file
View File

@@ -0,0 +1,8 @@
version: 2
updates:
# Maintain dependencies for GitHub Actions
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"

Binary file not shown.

After

Width:  |  Height:  |  Size: 140 KiB

BIN
.github/screenshots/tmux-starship.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 62 KiB

35
.github/tag-changelog-config.js vendored Normal file
View File

@@ -0,0 +1,35 @@
module.exports = {
types: [
{ types: ['feat', 'feature', 'Feat'], label: '🎉 New Features' },
{ types: ['fix', 'bugfix', 'Fix'], label: '🐛 Bugfixes' },
{ types: ['improvements', 'enhancement'], label: '🔨 Improvements' },
{ types: ['perf'], label: '🏎️ Performance Improvements' },
{ types: ['build', 'ci'], label: '🏗️ Build System' },
{ types: ['refactor'], label: '🪚 Refactors' },
{ types: ['doc', 'docs'], label: '📚 Documentation Changes' },
{ types: ['test', 'tests'], label: '🔍 Tests' },
{ types: ['style', 'codestyle'], label: '💅 Code Style Changes' },
{ types: ['chore', 'Chore'], label: '🧹 Chores' },
{ types: ['other', 'Other'], label: 'Other Changes' },
],
excludeTypes: [],
renderTypeSection: function (label, commits) {
let text = `\n## ${ label }\n\n`
commits.forEach((commit) => {
const scope = commit.scope ? `**${ commit.scope }:** ` : ''
text += `- ${ scope }${ commit.subject }\n`
})
return text
},
renderChangelog: function (release, changes) {
const now = new Date()
const d = now.toISOString().substring(0, 10);
const header = `# ${ release } - ${ d }\n`;
return header + changes + '\n\n'
},
}

23
.github/workflows/changelog.yml vendored Normal file
View File

@@ -0,0 +1,23 @@
---
name: Debug Changelog # Workflow name displayed on GitHub
on:
workflow_dispatch: # Trigger manually
jobs:
debug-changelog:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Create changelog text
id: changelog
uses: loopwerk/tag-changelog@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
config_file: .github/tag-changelog-config.js
- name: "Echo results"
id: output-changelog
run: |
echo "${{ steps.changelog.outputs.changes }}"

41
.github/workflows/new-release.yml vendored Normal file
View File

@@ -0,0 +1,41 @@
---
name: Release Daily State # Workflow name displayed on GitHub
on:
workflow_dispatch: # Trigger manually
schedule:
- cron: "30 20 * * *" # UTC is 2-3 hours behind Europe/Helsinki, my timezone
permissions:
contents: write
jobs:
new-daily-release:
runs-on: ubuntu-latest
outputs:
created: ${{ steps.daily-version.outputs.created }}
version: ${{ steps.daily-version.outputs.version }}
steps:
- uses: actions/checkout@v3 # Checkout our working repository
- name: Create tag if necessary
uses: fregante/daily-version-action@v2
id: daily-version
- name: Create changelog text
if: steps.daily-version.outputs.created
id: changelog
uses: loopwerk/tag-changelog@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
config_file: .github/tag-changelog-config.js
- name: Create release
if: steps.daily-version.outputs.created
uses: actions/create-release@latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.daily-version.outputs.version }}
release_name: Release ${{ steps.daily-version.outputs.version }}
body: ${{ steps.changelog.outputs.changes }}

40
.github/workflows/update-submodules.yml vendored Normal file
View File

@@ -0,0 +1,40 @@
name: Update submodules
on:
schedule: [cron: 0 3 * * *]
workflow_dispatch:
permissions:
contents: write
issues: write
pull-requests: write
jobs:
update-submodules:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
submodules: true
fetch-depth: 0
token: ${{secrets.GITHUB_TOKEN}}
- name: Config Git User
run: |
git config --global user.name "${{ github.actor }}"
git config --global user.email "${{ github.actor }}@users.noreply.github.com"
- name: Update submodules
run: |
if git commit -am"chore(git): Update submodules (automated)
$(git submodule --quiet foreach \
'tag="$(git describe --tags --abbrev=0 origin/HEAD)"
if [ "$(git describe --tags)" != "$tag" ]; then
git checkout --quiet "$tag"
echo "$name" "$tag"
fi')"
then
git show --raw
git push
fi

6
.gitignore vendored
View File

@@ -1,6 +1,12 @@
Brewfile.lock.json
*.log
*-secret
*cache
.idea
.vscode
config/fzf
config/cheat/cheatsheets/pure-bash-bible/*
config/cheat/cheatsheets/tldr/*
!.gitkeep
.env

23
.gitmodules vendored
View File

@@ -1,15 +1,16 @@
# vim: set expandtab:
[submodule "dotbot"]
path = dotbot
path = tools/dotbot
url = https://github.com/anishathalye/dotbot.git
ignore = dirty
[submodule "dotbot-brew"]
path = dotbot-brew
path = tools/dotbot-brew
url = https://github.com/wren/dotbot-brew.git
ignore = dirty
[submodule "dotbot-include"]
path = dotbot-include
path = tools/dotbot-include
url = https://gitlab.com/gnfzdz/dotbot-include.git
ignore = dirty
@@ -17,12 +18,14 @@
path = config/nvim
url = https://github.com/AstroNvim/AstroNvim.git
ignore = dirty
branch = main
update = checkout
shallow = true
[submodule "config/astronvim/lua/user"]
path = config/astronvim/lua/user
url = https://github.com/ivuorinen/astronvim_config.git
update = rebase
branch = main
[submodule "cheat-community"]
path = config/cheat/cheatsheets/community
url = https://github.com/cheat/cheatsheets.git
ignore = dirty
[submodule "tmux/tpm"]
path = config/tmux/plugins/tpm
url = https://github.com/tmux-plugins/tpm.git
ignore = dirty

19
.markdownlint.json Normal file
View File

@@ -0,0 +1,19 @@
{
"extends": "markdownlint/style/prettier",
"code-block-style": {
"style": "fenced"
},
"code-fence-style": {
"style": "backtick"
},
"heading-style": {
"style": "atx"
},
"no-duplicate-heading": {
"siblings_only": true
},
"required-headings": false,
"ul-style": {
"style": "dash"
}
}

5
.markdownlintignore Normal file
View File

@@ -0,0 +1,5 @@
config/cheat/cheatsheets/community/
config/tmux/
config/nvim/
tools/

View File

@@ -1 +1 @@
3
3.11

7
.shellcheckrc Normal file
View File

@@ -0,0 +1,7 @@
# This is shellcheck configuration file.
# Set whether or not to follow arbitrary file
# paths in source statements (since 0.8.0).
external-sources=true
includeAllWorkspaceSymbols=true

7
.stylua.toml Normal file
View File

@@ -0,0 +1,7 @@
column_width = 120
line_endings = "Unix"
indent_type = "Spaces"
indent_width = 2
quote_style = "AutoPreferDouble"
call_parentheses = "None"
collapse_simple_statement = "Always"

2
.yamlignore Normal file
View File

@@ -0,0 +1,2 @@
# .yamlignore

170
Brewfile
View File

@@ -6,15 +6,16 @@ tap "gesquive/tap"
tap "github/gh"
tap "homebrew/autoupdate"
tap "homebrew/bundle"
tap "homebrew/cask"
tap "homebrew/cask-fonts"
tap "homebrew/core"
tap "homebrew/services"
tap "jesseduffield/lazygit"
tap "mongodb/brew"
tap "shivammathur/extensions"
tap "shivammathur/php"
tap "teamookla/speedtest"
tap "xwmx/taps"
# Run your GitHub Actions locally
brew "act"
# Interpreted, interactive, object-oriented programming language
brew "python@3.11"
# Automate deployment, configuration, and upgrading
@@ -25,14 +26,16 @@ brew "ansible-lint"
brew "zstd"
# Open Source Kubernetes Marketplace
brew "arkade"
# Spell checker with better logic than ispell
brew "aspell"
# Automatic configure script builder
brew "autoconf"
# GNU File, Shell, and Text utilities
brew "coreutils", link: false
# Extendable version manager with support for Ruby, Node.js, Erlang & more
brew "asdf"
# Spell checker with better logic than ispell
brew "aspell"
# Official Amazon AWS command-line interface
brew "awscli"
# Terminal bandwidth utilization tool
brew "bandwhich"
# Clone of cat(1) with syntax highlighting and Git integration
brew "bat"
# Yet another cross-platform graphical process/system monitor
@@ -43,10 +46,10 @@ brew "brew-php-switcher"
brew "glib"
# Manage compile and link flags for libraries
brew "pkg-config"
# Human-friendly and fast alternative to cut and (sometimes) awk
brew "choose-rust"
# Cross-platform make
brew "cmake"
# GNU File, Shell, and Text utilities
brew "coreutils"
# Get, unpack, build, and install modules from CPAN
brew "cpanminus"
# Open source suite of directory software
@@ -57,6 +60,8 @@ brew "curl"
brew "difftastic"
# Tool for exploring each layer in a docker image
brew "dive"
# Lightweight DNS forwarder and DHCP server
brew "dnsmasq"
# Command-line DNS client
brew "dog"
# Lightning-fast linter for .env files written in Rust
@@ -65,28 +70,40 @@ brew "dotenv-linter"
brew "editorconfig-checker"
# Useful examples at the command-line
brew "eg-examples"
# CLI for templating and/or deploying FaaS functions
brew "faas-cli"
# C/C++ and Java libraries for Unicode and globalization
brew "icu4c"
# OpenType text shaping engine
brew "harfbuzz"
# Development kit for the Java programming language
brew "openjdk"
# Run arbitrary commands when files change
brew "entr"
# Simple, fast and user-friendly alternative to find
brew "fd"
# Banner-like program prints strings as ASCII art
brew "figlet"
# Libraries to talk to Microsoft SQL Server and Sybase databases
brew "freetds"
# Monitor a directory for changes and run a shell command
brew "fswatch"
# Command-line fuzzy finder written in Go
brew "fzf"
# Graphics library to dynamically manipulate images
brew "gd"
# Disk usage analyzer with console interface written in Go
brew "gdu", link: false
brew "gdu"
# GitHub command-line tool
brew "gh"
# Distributed revision control system
brew "git"
# Small git utilities
brew "git-extras"
# AVH edition of git-flow
brew "git-flow-avh"
# See your latest local git branches, formatted real fancy
brew "git-recent"
# Open-source GitLab command-line tool
brew "glab"
# Render markdown on the CLI
brew "glow"
# GNU implementation of the famous stream editor
brew "gnu-sed"
# Validating, recursive, caching DNS resolver
@@ -99,10 +116,6 @@ brew "gnupg"
brew "go"
# Image manipulation
brew "netpbm"
# C/C++ and Java libraries for Unicode and globalization
brew "icu4c"
# OpenType text shaping engine
brew "harfbuzz"
# Framework for layout and rendering of i18n text
brew "pango"
# Library to render SVG files using Cairo
@@ -119,6 +132,10 @@ brew "hadolint"
brew "htop"
# Website copier/offline browser
brew "httrack"
# Configurable static site generator
brew "hugo"
# ISO/IEC 23008-12:2017 HEIF file format decoder and encoder
brew "libheif"
# Tools and libraries to manipulate images in many formats
brew "imagemagick"
# Lightweight and flexible command-line JSON processor
@@ -129,32 +146,34 @@ brew "lazydocker"
brew "libpq"
# Linguistic software and Finnish dictionary
brew "libvoikko"
# Rainbows and unicorns in your console!
brew "lolcat"
# Package manager for the Lua programming language
brew "luarocks"
# Swiss Army Knife for macOS
brew "m-cli"
# Mac App Store command-line interface
brew "mas"
# Terminal-based visual file manager
brew "midnight-commander"
# Ambitious Vim-fork focused on extensibility and agility
brew "neovim"
# No Nonsense Neovim Client in Rust
brew "neovide"
# HTTP(S) server and reverse proxy, and IMAP/POP3 proxy server
brew "nginx"
# Port scanning utility for large networks
brew "nmap"
# Manage multiple Node.js versions
brew "nvm"
# Development kit for the Java programming language
brew "openjdk"
# Generate clients, server & docs from an OpenAPI spec (v2, v3)
brew "openapi-generator"
# Development kit for the Java programming language
brew "openjdk"
# Swiss-army knife of markup format conversion
brew "pandoc"
# Highly capable, feature-rich programming language
brew "perl"
# General-purpose scripting language
brew "php@8.1"
# Simple Python style checker in one Python file
brew "pycodestyle"
# Python version management
brew "pyenv"
# Migrate pip packages from one Python version to another
@@ -171,6 +190,8 @@ brew "rcm"
brew "ripgrep"
# Powerful, clean, object-oriented scripting language
brew "ruby"
# Safe, concurrent, practical language
brew "rust"
# Static analysis and lint tool, for (ba)sh scripts
brew "shellcheck"
# Autoformat shell script source code
@@ -180,9 +201,7 @@ brew "starship"
# Version control system designed to be a better CVS
brew "subversion"
# Send macOS User Notifications from the command-line
brew "terminal-notifier", link: false
# Tool to build, change, and version infrastructure
brew "terraform", link: false
brew "terminal-notifier"
# Thin wrapper for Terraform e.g. for locking state
brew "terragrunt"
# Tool which checks for the support of TLS/SSL ciphers and flaws
@@ -213,6 +232,8 @@ brew "watch"
brew "wget"
# Personal information dashboard for your terminal
brew "wtfutil"
# Check your $HOME for unwanted files and directories
brew "xdg-ninja"
# JavaScript package manager
brew "yarn"
# A vulnerability scanner for container images and filesystems
@@ -225,6 +246,8 @@ brew "gesquive/tap/git-user"
brew "jesseduffield/lazygit/lazygit"
# High-performance, schema-free, document-oriented database
brew "mongodb/brew/mongodb-community"
# Imagick PHP extension
brew "shivammathur/extensions/imagick@8.2"
# Xdebug PHP extension
brew "shivammathur/extensions/xdebug@7.4"
# Xdebug PHP extension
@@ -241,8 +264,14 @@ brew "shivammathur/php/php@8.0"
brew "teamookla/speedtest/speedtest"
# Command-line helper for the 1Password password manager
cask "1password-cli"
# Turn audio CDs and files into audiobooks
cask "audiobook-builder"
# Text editor
cask "coda"
# Universal database tool and SQL client
cask "dbeaver-community"
# Database version management tool
cask "dbngin"
# App to build and share containerized applications and microservices
cask "docker"
# Reimagine your terminal
@@ -273,10 +302,16 @@ cask "insomnia"
cask "jetbrains-toolbox"
# Kubernetes IDE
cask "lens"
# Keep all tasks from your todo apps on your menu bar
cask "monofocus"
# Neovim Client
cask "neovide"
# Reverse proxy, secure introspectable tunnels to localhost
cask "ngrok"
# Knowledge base that works on top of a local folder of plain text Markdown files
cask "obsidian"
# Scheduling application focusing on organization
cask "omnifocus"
# Collaboration platform for API development
cask "postman"
# Display image info and preview unsupported formats in QuickLook
@@ -291,8 +326,14 @@ cask "quicklook-json"
cask "quicklookase"
# Automatically hides or quits apps after periods of inactivity
cask "quitter"
# Control your tools with a few keystrokes
cask "raycast"
# Move and resize windows using keyboard shortcuts or snap areas
cask "rectangle"
# GUI for rsync
cask "rsyncosx"
# GUI for rsync
cask "rsyncui"
# MySQL/MariaDB database management
cask "sequel-ace"
# Collection of apps available by subscription
@@ -313,9 +354,78 @@ cask "vlc"
cask "voikkospellservice"
# Rust-based terminal
cask "warp"
# View output from scripts in the menu bar
cask "xbar"
mas "1Password for Safari", id: 1569813296
mas "Flow", id: 1423210932
mas "pullBar", id: 1601913905
mas "Actions", id: 1586435171
mas "Audiobook Builder", id: 1437681957
mas "Ivory", id: 6444602274
mas "Keynote", id: 409183694
mas "Numbers", id: 409203825
mas "Pages", id: 409201541
mas "Tailscale", id: 1475387142
mas "Xcode", id: 497799835
vscode "akamud.vscode-theme-onelight"
vscode "amiralizadeh9480.laravel-extra-intellisense"
vscode "andrewleedham.vscode-css-modules"
vscode "andrewmcodes.tailwindcss-extension-pack"
vscode "austenc.tailwind-docs"
vscode "bmewburn.vscode-intelephense-client"
vscode "Box-Of-Hats.bemhelper"
vscode "bradlc.vscode-tailwindcss"
vscode "christian-kohler.npm-intellisense"
vscode "DavidAnson.vscode-markdownlint"
vscode "dbaeumer.vscode-eslint"
vscode "DotJoshJohnson.xml"
vscode "eamodio.gitlens"
vscode "EditorConfig.EditorConfig"
vscode "esbenp.prettier-vscode"
vscode "formulahendry.auto-close-tag"
vscode "formulahendry.code-runner"
vscode "gencer.html-slim-scss-css-class-completion"
vscode "github.vscode-github-actions"
vscode "GitHub.vscode-pull-request-github"
vscode "GraphQL.vscode-graphql"
vscode "GraphQL.vscode-graphql-execution"
vscode "GraphQL.vscode-graphql-syntax"
vscode "heybourn.headwind"
vscode "JohnnyMorganz.stylua"
vscode "jumpinjackie.vscode-map-preview"
vscode "k--kato.intellij-idea-keybindings"
vscode "liamhammett.inline-parameters"
vscode "macieklad.tailwind-sass-syntax"
vscode "MehediDracula.php-namespace-resolver"
vscode "mikestead.dotenv"
vscode "MrChetan.phpstorm-parameter-hints-in-vscode"
vscode "mrorz.language-gettext"
vscode "ms-azuretools.vscode-docker"
vscode "ms-python.python"
vscode "ms-python.vscode-pylance"
vscode "ms-toolsai.jupyter"
vscode "ms-toolsai.jupyter-renderers"
vscode "ms-toolsai.vscode-jupyter-cell-tags"
vscode "ms-toolsai.vscode-jupyter-slideshow"
vscode "ms-vscode-remote.remote-containers"
vscode "ms-vscode-remote.remote-wsl"
vscode "ms-vscode.cpptools"
vscode "msjsdiag.vscode-react-native"
vscode "mtxr.sqltools"
vscode "neilbrayfield.php-docblocker"
vscode "nemesarial.dust"
vscode "nhoizey.gremlins"
vscode "octref.vetur"
vscode "oderwat.indent-rainbow"
vscode "pflannery.vscode-versionlens"
vscode "phiter.phpstorm-snippets"
vscode "SonarSource.sonarlint-vscode"
vscode "stylelint.vscode-stylelint"
vscode "syler.sass-indented"
vscode "timonwong.shellcheck"
vscode "tootone.org-mode"
vscode "valeryanm.vscode-phpsab"
vscode "Vue.volar"
vscode "WakaTime.vscode-wakatime"
vscode "wix.vscode-import-cost"
vscode "xdebug.php-debug"
vscode "xdebug.php-pack"
vscode "yinfei.luahelper"
vscode "yoavbls.pretty-ts-errors"
vscode "ZainChen.json"

View File

@@ -17,12 +17,26 @@ fork or download the repo as a zip and go from there with your own configs.
3. ???
4. Profit
### Updates
`cd $HOME/.dotfiles && git pull && ./install`
## The looks
## tmux with starship, the default view
![screenshot of tmux with starship](./.github/screenshots/tmux-starship.png)
## tmux + nvim (astronvim) editing this repository
![screenshot of tmux showing nvim](.github/screenshots/tmux-nvim-astronvim.png)
## Interesting files and locations
### Interesting folders
| Path | Description |
| ------------------- | -------------------------------------------- |
|---------------------|----------------------------------------------|
| `.github` | GitHub Repository configuration files. |
| `hosts/{hostname}/` | Configs that should apply to that host only. |
| `local/bin` | Helper scripts that I've collected or wrote. |
@@ -31,7 +45,7 @@ fork or download the repo as a zip and go from there with your own configs.
### dotfile folders
| Repo | Destination | Description |
| --------- | ----------- | ------------------------------------------- |
|-----------|-------------|---------------------------------------------|
| `base/` | `.*` | `$HOME` level files. |
| `config/` | `.config/` | Configurations for applications. |
| `local/` | `.local/` | XDG Base folder: `bin`, `share` and `state` |
@@ -47,32 +61,30 @@ The folder structure follows [XDG Base Directory Specification][xdg] where possi
### XDG Variables
| Var | Default |
| ------------------ | -------------------- |
| Env | Default |
|--------------------|----------------------|
| `$XDG_BIN_HOME` | `$HOME/.local/bin` |
| `$XDG_CONFIG_HOME` | `$HOME/.config` |
| `$XDG_DATA_HOME` | `$HOME/.local/share` |
| `$XDG_STATE_HOME` | `$HOME/.local/state` |
| `$XDG_CONFIG_HOME` | `$HOME/.config` |
| `$XDG_BIN_HOME` | `$HOME/.local/bin` |
- `$XDG_BIN_HOME` is a custom `env` for `.local/bin` folder.
- `$XDG_BIN_HOME` defines directory that contains local binaries.
- `$XDG_DATA_HOME` defines the base directory relative to which user-specific data
files should be stored. If `$XDG_DATA_HOME` is either not set or empty,
a default equal to `$HOME/.local/share` should be used.
- `$XDG_CONFIG_HOME` defines the base directory relative to which user-specific configuration
files should be stored. If `$XDG_CONFIG_HOME` is either not set or empty,
a default equal to `$HOME/.config` should be used.
files should be stored.
- If `$XDG_DATA_HOME` is either not set or empty, a default equal to
`$HOME/.local/share` should be used.
- `$XDG_CONFIG_HOME` defines the base directory relative to which user-specific
configuration files should be stored.
- If `$XDG_CONFIG_HOME` is either not set or empty, a default equal to `$HOME/.config` should be used.
- `$XDG_STATE_HOME` defines the base directory relative
to which user-specific state files should be stored.
If `$XDG_STATE_HOME` is either not set or empty, a default
equal to `$HOME/.local/state` should be used.
- The `$XDG_STATE_HOME` contains state data that should persist
between (application) restarts,
but that is not important or portable enough to the user that
it should be stored in `$XDG_DATA_HOME`.
It may contain:
- actions history (logs, history, recently used files, …)
- current state of the application that can be reused
on a restart (view, layout, open files, undo history, …)
- If `$XDG_STATE_HOME` is either not set or empty, a default equal to `$HOME/.local/state` should be used.
- The `$XDG_STATE_HOME` contains state data that should persist between (application) restarts,
but that is not important or portable enough to the user that it should be stored in `$XDG_DATA_HOME`.
- It may contain:
- actions history (logs, history, recently used files, …)
- current state of the application that can be reused
on a restart (view, layout, open files, undo history, …)
- User-specific executable files may be stored in `$HOME/.local/bin`.
Distributions should ensure this directory shows up in the UNIX `$PATH`
environment variable, at an appropriate place.
@@ -81,14 +93,3 @@ The folder structure follows [XDG Base Directory Specification][xdg] where possi
The directories in `$XDG_DATA_DIRS` should be seperated with a colon ':'.
[xdg]: https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
## Interesting links
### Interesting dotfiles repos
- [dotfiles.github.io/inspiration/](https://dotfiles.github.io/inspiration)
- [frdmn/dotfiles](https://github.com/github.com/frdmn/dotfiles) - Ansible-based
dotfile setup for macOS
- [mvdan/dotfiles](https://github.com/mvdan/dotfiles) - Here be dragons
- [vsouza/dotfiles](https://github.com/vsouza/dotfiles) - 🏡 My dotfiles
- [freekmurze/dotfiles](https://github.com/freekmurze/dotfiles) - My personal dotfiles

7
add-submodules.sh Normal file → Executable file
View File

@@ -1,4 +1,7 @@
#!/usr/bin/env bash
git submodule add --name dotbot-brew -f https://github.com/wren/dotbot-brew.git dotbot-brew
git submodule add --name dotbot-include -f https://gitlab.com/gnfzdz/dotbot-include.git dotbot-include
git submodule add --name dotbot -f https://github.com/anishathalye/dotbot.git tools/dotbot
git submodule add --name dotbot-brew -f https://github.com/wren/dotbot-brew.git tools/dotbot-brew
git submodule add --name dotbot-include -f https://gitlab.com/gnfzdz/dotbot-include.git tools/dotbot-include
git submodule add --name cheat-community -f https://github.com/cheat/cheatsheets.git config/cheat/cheatsheets/community
git submodule add --name tmux/tpm -f https://github.com/tmux-plugins/tpm.git config/tmux/plugins/tpm

View File

@@ -19,3 +19,5 @@ x-load-configs
# Import ssh keys in keychain
ssh-add -A 2>/dev/null;
[ -f "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.bash ] && source "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.bash

View File

@@ -4,4 +4,9 @@ email = ismo.vuorinen@vincit.fi
[home]
name = Ismo Vuorinen
email = ismo@vuorinen.net
email = ismo@ivuorinen.net
[github]
name = ivuorinen
email = ivuorinen@users.noreply.github.com

18
base/nbrc Normal file
View File

@@ -0,0 +1,18 @@
#!/usr/bin/env bash
###############################################################################
# .nbrc
#
# Configuration file for `nb`, a command line note-taking, bookmarking,
# and knowledge base application with encryption, search, Git-backed syncing,
# and more in a single portable script.
#
# Edit this file manually or manage settings using the `nb settings`
# subcommand. Configuration options are set as environment variables, eg:
# export NB_ENCRYPTION_TOOL=gpg
#
# https://github.com/xwmx/nb
###############################################################################
export NB_DIR="${NB_DIR:-$HOME/.local/state/nb}" # Set by `nb` • Mon May 8 15:25:12 EEST 2023
export NB_COLOR_THEME="${NB_COLOR_THEME:-unicorn}" # Set by `nb` • Mon May 8 15:41:22 EEST 2023

View File

@@ -3,9 +3,16 @@
autoload -U colors zsh/terminfo
colors
setopt correct
# Add completion scripts to zsh path
FPATH="~/.config/zsh/completion:$FPATH"
autoload -Uz compinit && compinit -i
# Defaults
export DOTFILES="$HOME/.dotfiles"
# shellcheck source=shared.sh
source "$DOTFILES/scripts/shared.sh"
# Run x-load-configs in your terminal to reload the files.
function x-load-configs()
@@ -28,14 +35,17 @@ ANTIGEN_ZSH_PATH="$XDG_BIN_HOME/antigen.zsh"
[[ -f "$ANTIGEN_ZSH_PATH" ]] && source "$ANTIGEN_ZSH_PATH"
# antigen is present
if command -v antigen &> /dev/null; then
have antigen && {
antigen use oh-my-zsh
# config/functions
x-default-antigen-bundles
antigen apply
fi
}
eval "$(starship init zsh)"
# starship is present
have starship && eval "$(starship init zsh)"
[ -f "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.zsh ] \
&& source "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.zsh

View File

@@ -1,9 +1,11 @@
#!/usr/bin/env bash
# shellcheck source="../scripts/shared.sh"
source "$DOTFILES/scripts/shared.sh"
# Get installed php versions from brew and setup aliases
function x-set-php-aliases
{
if command -v brew &> /dev/null; then
have brew && {
local php_versions=()
while IFS="" read -r line; do php_versions+=("$line"); done < <(brew list | grep '^php')
@@ -31,7 +33,7 @@ function x-set-php-aliases
# shellcheck disable=SC2139,SC2140
alias "${php_alias}c"="$php_exec $php_error_reporting $(which composer)"
done
fi
}
}
if [[ $(uname) == 'Darwin' ]]; then
@@ -74,10 +76,8 @@ alias code_scanner='docker run
alias zedit='$EDITOR ~/.dotfiles'
if hash irssi 2> /dev/null; then
# shellcheck disable=2139
alias irssi="irssi --config='$IRSSI_CONFIG_FILE' --home='$IRSSI_CONFIG_HOME'"
fi
have irssi \
&& alias irssi="irssi --config='$IRSSI_CONFIG_FILE' --home='$IRSSI_CONFIG_HOME'"
if [[ -f "$HOME/.aliases.local" ]]; then
# shellcheck disable=SC1091

View File

@@ -0,0 +1,674 @@
GNU GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The GNU General Public License is a free, copyleft license for
software and other kinds of works.
The licenses for most software and other practical works are designed
to take away your freedom to share and change the works. By contrast,
the GNU General Public License is intended to guarantee your freedom to
share and change all versions of a program--to make sure it remains free
software for all its users. We, the Free Software Foundation, use the
GNU General Public License for most of our software; it applies also to
any other work released this way by its authors. You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
them if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new
free programs, and that you know you can do these things.
To protect your rights, we need to prevent others from denying you
these rights or asking you to surrender the rights. Therefore, you have
certain responsibilities if you distribute copies of the software, or if
you modify it: responsibilities to respect the freedom of others.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must pass on to the recipients the same
freedoms that you received. You must make sure that they, too, receive
or can get the source code. And you must show them these terms so they
know their rights.
Developers that use the GNU GPL protect your rights with two steps:
(1) assert copyright on the software, and (2) offer you this License
giving you legal permission to copy, distribute and/or modify it.
For the developers' and authors' protection, the GPL clearly explains
that there is no warranty for this free software. For both users' and
authors' sake, the GPL requires that modified versions be marked as
changed, so that their problems will not be attributed erroneously to
authors of previous versions.
Some devices are designed to deny users access to install or run
modified versions of the software inside them, although the manufacturer
can do so. This is fundamentally incompatible with the aim of
protecting users' freedom to change the software. The systematic
pattern of such abuse occurs in the area of products for individuals to
use, which is precisely where it is most unacceptable. Therefore, we
have designed this version of the GPL to prohibit the practice for those
products. If such problems arise substantially in other domains, we
stand ready to extend this provision to those domains in future versions
of the GPL, as needed to protect the freedom of users.
Finally, every program is threatened constantly by software patents.
States should not allow patents to restrict development and use of
software on general-purpose computers, but in those that do, we wish to
avoid the special danger that patents applied to a free program could
make it effectively proprietary. To prevent this, the GPL assures that
patents cannot be used to render the program non-free.
The precise terms and conditions for copying, distribution and
modification follow.
TERMS AND CONDITIONS
0. Definitions.
"This License" refers to version 3 of the GNU General Public License.
"Copyright" also means copyright-like laws that apply to other kinds of
works, such as semiconductor masks.
"The Program" refers to any copyrightable work licensed under this
License. Each licensee is addressed as "you". "Licensees" and
"recipients" may be individuals or organizations.
To "modify" a work means to copy from or adapt all or part of the work
in a fashion requiring copyright permission, other than the making of an
exact copy. The resulting work is called a "modified version" of the
earlier work or a work "based on" the earlier work.
A "covered work" means either the unmodified Program or a work based
on the Program.
To "propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification), making available to the
public, and in some countries other activities as well.
To "convey" a work means any kind of propagation that enables other
parties to make or receive copies. Mere interaction with a user through
a computer network, with no transfer of a copy, is not conveying.
An interactive user interface displays "Appropriate Legal Notices"
to the extent that it includes a convenient and prominently visible
feature that (1) displays an appropriate copyright notice, and (2)
tells the user that there is no warranty for the work (except to the
extent that warranties are provided), that licensees may convey the
work under this License, and how to view a copy of this License. If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.
1. Source Code.
The "source code" for a work means the preferred form of the work
for making modifications to it. "Object code" means any non-source
form of a work.
A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that
is widely used among developers working in that language.
The "System Libraries" of an executable work include anything, other
than the work as a whole, that (a) is included in the normal form of
packaging a Major Component, but which is not part of that Major
Component, and (b) serves only to enable use of the work with that
Major Component, or to implement a Standard Interface for which an
implementation is available to the public in source code form. A
"Major Component", in this context, means a major essential component
(kernel, window system, and so on) of the specific operating system
(if any) on which the executable work runs, or a compiler used to
produce the work, or an object code interpreter used to run it.
The "Corresponding Source" for a work in object code form means all
the source code needed to generate, install, and (for an executable
work) run the object code and to modify the work, including scripts to
control those activities. However, it does not include the work's
System Libraries, or general-purpose tools or generally available free
programs which are used unmodified in performing those activities but
which are not part of the work. For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.
The Corresponding Source need not include anything that users
can regenerate automatically from other parts of the Corresponding
Source.
The Corresponding Source for a work in source code form is that
same work.
2. Basic Permissions.
All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
conditions are met. This License explicitly affirms your unlimited
permission to run the unmodified Program. The output from running a
covered work is covered by this License only if the output, given its
content, constitutes a covered work. This License acknowledges your
rights of fair use or other equivalent, as provided by copyright law.
You may make, run and propagate covered works that you do not
convey, without conditions so long as your license otherwise remains
in force. You may convey covered works to others for the sole purpose
of having them make modifications exclusively for you, or provide you
with facilities for running those works, provided that you comply with
the terms of this License in conveying all material for which you do
not control copyright. Those thus making or running the covered works
for you must do so exclusively on your behalf, under your direction
and control, on terms that prohibit them from making any copies of
your copyrighted material outside their relationship with you.
Conveying under any other circumstances is permitted solely under
the conditions stated below. Sublicensing is not allowed; section 10
makes it unnecessary.
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.
When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such circumvention
is effected by exercising rights under this License with respect to
the covered work, and you disclaim any intention to limit operation or
modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.
4. Conveying Verbatim Copies.
You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.
You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.
5. Conveying Modified Source Versions.
You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:
a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.
b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This requirement modifies the requirement in section 4 to
"keep intact all notices".
c) You must license the entire work, as a whole, under this
License to anyone who comes into possession of a copy. This
License will therefore apply, along with any applicable section 7
additional terms, to the whole of the work, and all its parts,
regardless of how they are packaged. This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.
d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your
work need not make them do so.
A compilation of a covered work with other separate and independent
works, which are not by their nature extensions of the covered work,
and which are not combined with it such as to form a larger program,
in or on a volume of a storage or distribution medium, is called an
"aggregate" if the compilation and its resulting copyright are not
used to limit the access or legal rights of the compilation's users
beyond what the individual works permit. Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.
6. Conveying Non-Source Forms.
You may convey a covered work in object code form under the terms
of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:
a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium
customarily used for software interchange.
b) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by a
written offer, valid for at least three years and valid for as
long as you offer spare parts or customer support for that product
model, to give anyone who possesses the object code either (1) a
copy of the Corresponding Source for all the software in the
product that is covered by this License, on a durable physical
medium customarily used for software interchange, for a price no
more than your reasonable cost of physically performing this
conveying of source, or (2) access to copy the
Corresponding Source from a network server at no charge.
c) Convey individual copies of the object code with a copy of the
written offer to provide the Corresponding Source. This
alternative is allowed only occasionally and noncommercially, and
only if you received the object code with such an offer, in accord
with subsection 6b.
d) Convey the object code by offering access from a designated
place (gratis or for a charge), and offer equivalent access to the
Corresponding Source in the same way through the same place at no
further charge. You need not require recipients to copy the
Corresponding Source along with the object code. If the place to
copy the object code is a network server, the Corresponding Source
may be on a different server (operated by you or a third party)
that supports equivalent copying facilities, provided you maintain
clear directions next to the object code saying where to find the
Corresponding Source. Regardless of what server hosts the
Corresponding Source, you remain obligated to ensure that it is
available for as long as needed to satisfy these requirements.
e) Convey the object code using peer-to-peer transmission, provided
you inform other peers where the object code and Corresponding
Source of the work are being offered to the general public at no
charge under subsection 6d.
A separable portion of the object code, whose source code is excluded
from the Corresponding Source as a System Library, need not be
included in conveying the object code work.
A "User Product" is either (1) a "consumer product", which means any
tangible personal property which is normally used for personal, family,
or household purposes, or (2) anything designed or sold for incorporation
into a dwelling. In determining whether a product is a consumer product,
doubtful cases shall be resolved in favor of coverage. For a particular
product received by a particular user, "normally used" refers to a
typical or common use of that class of product, regardless of the status
of the particular user or of the way in which the particular user
actually uses, or expects or is expected to use, the product. A product
is a consumer product regardless of whether the product has substantial
commercial, industrial or non-consumer uses, unless such uses represent
the only significant mode of use of the product.
"Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information required to install
and execute modified versions of a covered work in that User Product from
a modified version of its Corresponding Source. The information must
suffice to ensure that the continued functioning of the modified object
code is in no case prevented or interfered with solely because
modification has been made.
If you convey an object code work under this section in, or with, or
specifically for use in, a User Product, and the conveying occurs as
part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information. But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).
The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed. Access to a
network may be denied when the modification itself materially and
adversely affects the operation of the network or violates the rules and
protocols for communication across the network.
Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.
7. Additional Terms.
"Additional permissions" are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law. If additional permissions
apply only to part of the Program, that part may be used separately
under those permissions, but the entire Program remains governed by
this License without regard to the additional permissions.
When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it. (Additional permissions may be written to require their own
removal in certain cases when you modify the work.) You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.
Notwithstanding any other provision of this License, for material you
add to a covered work, you may (if authorized by the copyright holders of
that material) supplement the terms of this License with terms:
a) Disclaiming warranty or limiting liability differently from the
terms of sections 15 and 16 of this License; or
b) Requiring preservation of specified reasonable legal notices or
author attributions in that material or in the Appropriate Legal
Notices displayed by works containing it; or
c) Prohibiting misrepresentation of the origin of that material, or
requiring that modified versions of such material be marked in
reasonable ways as different from the original version; or
d) Limiting the use for publicity purposes of names of licensors or
authors of the material; or
e) Declining to grant rights under trademark law for use of some
trade names, trademarks, or service marks; or
f) Requiring indemnification of licensors and authors of that
material by anyone who conveys the material (or modified versions of
it) with contractual assumptions of liability to the recipient, for
any liability that these contractual assumptions directly impose on
those licensors and authors.
All other non-permissive additional terms are considered "further
restrictions" within the meaning of section 10. If the Program as you
received it, or any part of it, contains a notice stating that it is
governed by this License along with a term that is a further
restriction, you may remove that term. If a license document contains
a further restriction but permits relicensing or conveying under this
License, you may add to a covered work material governed by the terms
of that license document, provided that the further restriction does
not survive such relicensing or conveying.
If you add terms to a covered work in accord with this section, you
must place, in the relevant source files, a statement of the
additional terms that apply to those files, or a notice indicating
where to find the applicable terms.
Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions;
the above requirements apply either way.
8. Termination.
You may not propagate or modify a covered work except as expressly
provided under this License. Any attempt otherwise to propagate or
modify it is void, and will automatically terminate your rights under
this License (including any patent licenses granted under the third
paragraph of section 11).
However, if you cease all violation of this License, then your
license from a particular copyright holder is reinstated (a)
provisionally, unless and until the copyright holder explicitly and
finally terminates your license, and (b) permanently, if the copyright
holder fails to notify you of the violation by some reasonable means
prior to 60 days after the cessation.
Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.
Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License. If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.
9. Acceptance Not Required for Having Copies.
You are not required to accept this License in order to receive or
run a copy of the Program. Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not require acceptance. However,
nothing other than this License grants you permission to propagate or
modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.
10. Automatic Licensing of Downstream Recipients.
Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
propagate that work, subject to this License. You are not responsible
for enforcing compliance by third parties with this License.
An "entity transaction" is a transaction transferring control of an
organization, or substantially all assets of one, or subdividing an
organization, or merging organizations. If propagation of a covered
work results from an entity transaction, each party to that
transaction who receives a copy of the work also receives whatever
licenses to the work the party's predecessor in interest had or could
give under the previous paragraph, plus a right to possession of the
Corresponding Source of the work from the predecessor in interest, if
the predecessor has it or can get it with reasonable efforts.
You may not impose any further restrictions on the exercise of the
rights granted or affirmed under this License. For example, you may
not impose a license fee, royalty, or other charge for exercise of
rights granted under this License, and you may not initiate litigation
(including a cross-claim or counterclaim in a lawsuit) alleging that
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.
11. Patents.
A "contributor" is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based. The
work thus licensed is called the contributor's "contributor version".
A contributor's "essential patent claims" are all patent claims
owned or controlled by the contributor, whether already acquired or
hereafter acquired, that would be infringed by some manner, permitted
by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version. For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the requirements of
this License.
Each contributor grants you a non-exclusive, worldwide, royalty-free
patent license under the contributor's essential patent claims, to
make, use, sell, offer for sale, import and otherwise run, modify and
propagate the contents of its contributor version.
In the following three paragraphs, a "patent license" is any express
agreement or commitment, however denominated, not to enforce a patent
(such as an express permission to practice a patent or covenant not to
sue for patent infringement). To "grant" such a patent license to a
party means to make such an agreement or commitment not to enforce a
patent against the party.
If you convey a covered work, knowingly relying on a patent license,
and the Corresponding Source of the work is not available for anyone
to copy, free of charge and under the terms of this License, through a
publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the requirements of this License, to extend the patent
license to downstream recipients. "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
in a country, would infringe one or more identifiable patents in that
country that you have reason to believe are valid.
If, pursuant to or in connection with a single transaction or
arrangement, you convey, or propagate by procuring conveyance of, a
covered work, and grant a patent license to some of the parties
receiving the covered work authorizing them to use, propagate, modify
or convey a specific copy of the covered work, then the patent license
you grant is automatically extended to all recipients of the covered
work and works based on it.
A patent license is "discriminatory" if it does not include within
the scope of its coverage, prohibits the exercise of, or is
conditioned on the non-exercise of one or more of the rights that are
specifically granted under this License. You may not convey a covered
work if you are a party to an arrangement with a third party that is
in the business of distributing software, under which you make payment
to the third party based on the extent of your activity of conveying
the work, and under which the third party grants, to any of the
parties who would receive the covered work from you, a discriminatory
patent license (a) in connection with copies of the covered work
conveyed by you (or copies made from those copies), or (b) primarily
for and in connection with specific products or compilations that
contain the covered work, unless you entered into that arrangement,
or that patent license was granted, prior to 28 March 2007.
Nothing in this License shall be construed as excluding or limiting
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.
12. No Surrender of Others' Freedom.
If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot convey a
covered work so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you may
not convey it at all. For example, if you agree to terms that obligate you
to collect a royalty for further conveying from those to whom you convey
the Program, the only way you could satisfy both those terms and this
License would be to refrain entirely from conveying the Program.
13. Use with the GNU Affero General Public License.
Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
under version 3 of the GNU Affero General Public License into a single
combined work, and to convey the resulting work. The terms of this
License will continue to apply to the part which is the covered work,
but the special requirements of the GNU Affero General Public License,
section 13, concerning interaction through a network will apply to the
combination as such.
14. Revised Versions of this License.
The Free Software Foundation may publish revised and/or new versions of
the GNU General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the
Program specifies that a certain numbered version of the GNU General
Public License "or any later version" applies to it, you have the
option of following the terms and conditions either of that numbered
version or of any later version published by the Free Software
Foundation. If the Program does not specify a version number of the
GNU General Public License, you may choose any version ever published
by the Free Software Foundation.
If the Program specifies that a proxy can decide which future
versions of the GNU General Public License can be used, that proxy's
public statement of acceptance of a version permanently authorizes you
to choose that version for the Program.
Later license versions may give you additional or different
permissions. However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.
15. Disclaimer of Warranty.
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. Limitation of Liability.
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
SUCH DAMAGES.
17. Interpretation of Sections 15 and 16.
If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
Also add information on how to contact you by electronic and paper mail.
If the program does terminal interaction, make it output a short
notice like this when it starts in an interactive mode:
<program> Copyright (C) <year> <name of author>
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, your program's commands
might be different; for a GUI interface, you would use an "about box".
You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
<https://www.gnu.org/licenses/>.
The GNU General Public License does not permit incorporating your program
into proprietary programs. If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License. But first, please read
<https://www.gnu.org/licenses/why-not-lgpl.html>.

View File

@@ -0,0 +1,3 @@
return { -- a table of overrides/changes to the duskfox theme
Normal = { bg = "#000000" },
}

View File

@@ -0,0 +1,3 @@
return { -- this table overrides highlights in all themes
-- Normal = { bg = "#000000" },
}

View File

@@ -0,0 +1,94 @@
return {
-- Configure AstroNvim updates
updater = {
remote = "origin", -- remote to use
channel = "stable", -- "stable" or "nightly"
version = "latest", -- "latest", tag name, or regex search like "v1.*" to only do updates before v2 (STABLE ONLY)
branch = "nightly", -- branch name (NIGHTLY ONLY)
commit = nil, -- commit hash (NIGHTLY ONLY)
pin_plugins = nil, -- nil, true, false (nil will pin plugins on stable only)
skip_prompts = false, -- skip prompts about breaking changes
show_changelog = true, -- show the changelog after performing an update
auto_quit = true, -- automatically quit the current session after a successful update
remotes = { -- easily add new remotes to track
-- ["remote_name"] = "https://remote_url.come/repo.git", -- full remote url
-- ["remote2"] = "github_user/repo", -- GitHub user/repo shortcut,
-- ["remote3"] = "github_user", -- GitHub user assume AstroNvim fork
},
},
-- Set colorscheme to use
colorscheme = "catppuccin", -- or astrondark
-- Diagnostics configuration (for vim.diagnostics.config({...}))
-- when diagnostics are on
diagnostics = {
virtual_text = false,
underline = true,
},
lsp = {
-- customize lsp formatting options
formatting = {
-- control auto formatting on save
format_on_save = {
-- enable or disable format on save globally
enabled = true,
-- enable format on save for specified filetypes only
allow_filetypes = {
-- "go",
},
-- disable format on save for specified filetypes
ignore_filetypes = {
-- "python",
},
},
-- disable formatting capabilities for the listed language servers
disabled = {
-- "sumneko_lua",
},
-- default format timeout
timeout_ms = 1000,
-- -- fully override the default formatting function
-- filter = function(client) -- fully override the default formatting function
-- return true
-- end
},
-- enable servers that you already have installed without mason
servers = {
-- "pyright"
},
},
-- Configure require("lazy").setup() options
lazy = {
defaults = { lazy = true },
performance = {
rtp = {
-- customize default disabled vim plugins
disabled_plugins = {
"tohtml",
"gzip",
"matchit",
"zipPlugin",
"netrwPlugin",
"tarPlugin",
"matchparen",
},
},
},
},
-- This function is run last and is a good place to configuring
-- augroups/autocommands and custom filetypes also this just pure lua so
-- anything that doesn't fit in the normal config locations above can go here
polish = function()
-- Set up custom filetypes
-- vim.filetype.add {
-- extension = {
-- foo = "fooscript",
-- },
-- filename = {
-- ["Foofile"] = "fooscript",
-- },
-- pattern = {
-- ["~/%.config/foo/.*"] = "fooscript",
-- },
-- }
end,
}

View File

@@ -0,0 +1,30 @@
-- Mapping data with "desc" stored directly by vim.keymap.set().
--
-- Please use this mappings table to set keyboard mapping since this is the
-- lower level configuration and more robust one. (which-key will
-- automatically pick-up stored data by this setting.)
return {
-- first key is the mode
n = {
-- second key is the lefthand side of the map
-- mappings seen under group name "Buffer"
["<leader>bn"] = { "<cmd>tabnew<cr>", desc = "New tab" },
["<leader>bD"] = {
function()
require("astronvim.utils.status").heirline.buffer_picker(
function(bufnr) require("astronvim.utils.buffer").close(bufnr) end
)
end,
desc = "Pick to close",
},
-- tables with the `name` key will be registered with which-key if it's installed
-- this is useful for naming menus
["<leader>b"] = { name = "Buffers" },
-- quick save
-- ["<C-s>"] = { ":w!<cr>", desc = "Save File" }, -- change description but the same command
},
t = {
-- setting a mapping to false will disable it
-- ["<esc>"] = false,
},
}

View File

@@ -0,0 +1,38 @@
-- set vim options here (vim.<first_key>.<second_key> = value)
return {
opt = {
-- set to true or false etc.
relativenumber = true, -- sets vim.opt.relativenumber
number = true, -- sets vim.opt.number
spell = false, -- sets vim.opt.spell
signcolumn = "auto", -- sets vim.opt.signcolumn to auto
wrap = true, -- sets vim.opt.wrap
},
g = {
-- sets vim.g.mapleader
mapleader = " ",
-- enable or disable auto formatting at start (lsp.formatting.format_on_save must be enabled)
autoformat_enabled = true,
-- enable completion at start
cmp_enabled = true,
-- enable autopairs at start
autopairs_enabled = true,
-- set the visibility of diagnostics in the UI
-- (0=off, 1=only show in status line, 2=virtual text off, 3=all on)
diagnostics_mode = 3,
-- disable icons in the UI (disable if no nerd font is available,
-- requires :PackerSync after changing)
icons_enabled = true,
-- disable notifications when toggling UI elements
ui_notifications_enabled = true,
},
}
-- If you need more control, you can use the function()...end notation
-- return function(local_vim)
-- local_vim.opt.relativenumber = true
-- local_vim.g.mapleader = " "
-- local_vim.opt.whichwrap = vim.opt.whichwrap - { 'b', 's' } -- removing option from list
-- local_vim.opt.shortmess = vim.opt.shortmess + { I = true } -- add to option list
--
-- return local_vim
-- end

View File

@@ -0,0 +1,51 @@
return {
-- Add the community repository of plugin specifications
"AstroNvim/astrocommunity",
-- example of imporing a plugin, comment out to use it or add your own.
-- available plugins can be found at
-- https://github.com/AstroNvim/astrocommunity
{
import = "astrocommunity.colorscheme.catppuccin",
opts = {
flavour = "mocha",
transparent_background = true,
dim_inactive = {
enabled = true,
shade = "dark",
percentage = 0.15,
},
}
},
-- { import = "astrocommunity.completion.copilot-lua-cmp" },
{ import = "astrocommunity.bars-and-lines.smartcolumn-nvim" },
{
"m4xshen/smartcolumn.nvim",
opts = {
colorcolumn = { "80", "100", "120" },
disabled_filetypes = { "help", "text", "markdown", "json" },
},
},
{ import = "astrocommunity.diagnostics.trouble-nvim" },
{
"folke/trouble.nvim",
opts = {
auto_open = true,
position = "right"
}
},
{ import = "astrocommunity.editing-support.refactoring-nvim" },
{ import = "astrocommunity.editing-support.neogen" },
{ import = "astrocommunity.editing-support.nvim-regexplainer" },
{ import = "astrocommunity.editing-support.todo-comments-nvim" },
{ import = "astrocommunity.indent.mini-indentscope" },
{ import = "astrocommunity.markdown-and-latex.glow-nvim" },
{ import = "astrocommunity.motion.harpoon" },
{ import = "astrocommunity.pack.php" },
{ import = "astrocommunity.project.neoconf-nvim" },
{ import = "astrocommunity.project.nvim-spectre" },
{ import = "astrocommunity.project.project-nvim" },
{ import = "astrocommunity.test.neotest" },
{ import = "astrocommunity.utility.neodim" },
{ import = "astrocommunity.utility.transparent-nvim" },
}

View File

@@ -0,0 +1,112 @@
return {
-- customize alpha options
{
"goolord/alpha-nvim",
opts = function(_, opts)
-- customize the dashboard header
opts.section.header.val = {
" ▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄ ",
" ▄▀░░░░░░░░░░░░▄░░░░░░░▀▄ ",
" █░░▄░░░░▄░░░░░░░░░░░░░░█ ",
" █░░░░░░░░░░░░▄█▄▄░░▄░░░█ ▄▄▄ ",
"▄▄▄▄▄ █░░░░░░▀░░░░▀█░░▀▄░░░░░█▀▀░██ ",
"██▄▀██▄█░░░▄░░░░░░░██░░░░▀▀▀▀▀░░░░██ ",
" ▀██▄▀██░░░░░░░░▀░██▀░░░░░░░░░░░░░▀██",
" ▀████░▀░░░░▄░░░██░░░▄█░░░░▄░▄█░░██",
" ▀█░░░░▄░░░░░██░░░░▄░░░▄░░▄░░░██",
" ▄█▄░░░░░░░░░░░▀▄░░▀▀▀▀▀▀▀▀░░▄▀ ",
" █▀▀█████████▀▀▀▀████████████▀ ",
" ████▀ ███▀ ▀███ ▀██▀ ",
}
return opts
end,
},
-- You can disable default plugins as follows:
-- { "max397574/better-escape.nvim", enabled = false },
--
-- You can also easily customize additional setup of plugins
-- that is outside of the plugin's setup call
{
"L3MON4D3/LuaSnip",
config = function(plugin, opts)
-- include the default astronvim config that calls the setup call
require "plugins.configs.luasnip" (plugin, opts)
-- add more custom luasnip configuration such
-- as filetype extend or custom snippets
local luasnip = require "luasnip"
luasnip.filetype_extend("javascript", { "javascriptreact" })
end,
},
{
"nvim-neo-tree/neo-tree.nvim",
opts = function(_, opts)
require "plugins.neo-tree"
opts.filesystem.filtered_items = {
visible = false,
show_hidden_count = true,
hide_dotfiles = false,
hide_gitignored = false,
hide_by_name = {
'.idea',
'.DS_Store'
},
never_show = {
'.git',
'.idea',
'.mypy_cache',
'.DS_Store',
'thumbs.db'
},
}
return opts
end,
},
-- {
-- "windwp/nvim-autopairs",
-- config = function(plugin, opts)
-- -- include the default astronvim config that calls the setup call
-- require "plugins.configs.nvim-autopairs"(plugin, opts)
-- -- add more custom autopairs configuration such as custom rules
-- local npairs = require "nvim-autopairs"
-- local Rule = require "nvim-autopairs.rule"
-- local cond = require "nvim-autopairs.conds"
-- npairs.add_rules(
-- {
-- Rule("$", "$", { "tex", "latex" })
-- -- don't add a pair if the next character is %
-- :with_pair(cond.not_after_regex "%%")
-- -- don't add a pair if the previous character is xxx
-- :with_pair(
-- cond.not_before_regex("xxx", 3)
-- )
-- -- don't move right when repeat character
-- :with_move(cond.none())
-- -- don't delete if the next character is xx
-- :with_del(cond.not_after_regex "xx")
-- -- disable adding a newline when you press <cr>
-- :with_cr(cond.none()),
-- },
-- -- disable for .vim files, but it work for another filetypes
-- Rule("a", "a", "-vim")
-- )
-- end,
-- },
-- By adding to the which-key config and using our helper
-- function you can add more which-key registered bindings
{
"folke/which-key.nvim",
config = function(plugin, opts)
-- include the default astronvim config that calls the setup call
require "plugins.configs.which-key" (plugin, opts)
-- Add bindings which show up as group name
local wk = require "which-key"
wk.register(
{
b = { name = "Buffer" },
},
{ mode = "n", prefix = "<leader>" }
)
end,
},
}

View File

@@ -0,0 +1,32 @@
-- customize mason plugins
return {
-- use mason-lspconfig to configure LSP installations
{
"williamboman/mason-lspconfig.nvim",
-- overrides `require("mason-lspconfig").setup(...)`
opts = {
ensure_installed = {
"diagnosticls",
},
},
},
-- use mason-null-ls to configure Formatters/Linter
-- installation for null-ls sources
{
"jay-babu/mason-null-ls.nvim",
-- overrides `require("mason-null-ls").setup(...)`
opts = {
automatic_setup = true,
automatic_installation = true,
},
},
{
"jay-babu/mason-nvim-dap.nvim",
-- overrides `require("mason-nvim-dap").setup(...)`
opts = {
automatic_installation = true,
automatic_setup = true,
ensure_installed = { "python", "php", "js", "bash" },
},
},
}

View File

@@ -0,0 +1,52 @@
return {
"jose-elias-alvarez/null-ls.nvim",
opts = function(_, config)
-- config variable is the default configuration table for the setup function call
local null_ls = require "null-ls"
-- Check supported formatters and linters
-- https://github.com/jose-elias-alvarez/null-ls.nvim/tree/main/lua/null-ls/builtins/formatting
-- https://github.com/jose-elias-alvarez/null-ls.nvim/tree/main/lua/null-ls/builtins/diagnostics
config.sources = {
-- Set a formatter
null_ls.builtins.code_actions.eslint,
null_ls.builtins.code_actions.refactoring,
null_ls.builtins.code_actions.shellcheck,
null_ls.builtins.diagnostics.actionlint,
null_ls.builtins.diagnostics.alex,
null_ls.builtins.diagnostics.ansiblelint,
null_ls.builtins.diagnostics.dotenv_linter,
null_ls.builtins.diagnostics.editorconfig_checker,
null_ls.builtins.diagnostics.eslint,
null_ls.builtins.diagnostics.jsonlint,
null_ls.builtins.diagnostics.luacheck,
null_ls.builtins.diagnostics.php,
null_ls.builtins.diagnostics.phpcs,
null_ls.builtins.diagnostics.phpstan,
null_ls.builtins.diagnostics.psalm,
null_ls.builtins.diagnostics.semgrep,
null_ls.builtins.diagnostics.shellcheck,
null_ls.builtins.diagnostics.stylelint,
null_ls.builtins.diagnostics.tfsec,
null_ls.builtins.diagnostics.trail_space,
null_ls.builtins.diagnostics.tsc,
null_ls.builtins.diagnostics.vacuum,
null_ls.builtins.diagnostics.vint,
null_ls.builtins.diagnostics.vulture,
null_ls.builtins.diagnostics.yamllint,
null_ls.builtins.diagnostics.zsh,
null_ls.builtins.formatting.blade_formatter,
null_ls.builtins.formatting.clang_format,
null_ls.builtins.formatting.eslint,
null_ls.builtins.formatting.fixjson,
null_ls.builtins.formatting.isort,
null_ls.builtins.formatting.jq,
null_ls.builtins.formatting.phpcsfixer,
null_ls.builtins.formatting.shfmt.with {
args = { "-i", "1", "-bn", "-ci", "-sr", "-kb", "-fn" },
},
null_ls.builtins.formatting.stylelint,
}
return config -- return final config table
end,
}

View File

@@ -0,0 +1,33 @@
return {
"nvim-treesitter/nvim-treesitter",
opts = {
ensure_installed = {
"bash",
"c",
"cmake",
"comment",
"diff",
"dockerfile",
"gitignore",
"graphql",
"html",
"javascript",
"json",
"json5",
"latex",
"lua",
"markdown",
"php",
"phpdoc",
"python",
"scss",
"terraform",
"todotxt",
"toml",
"typescript",
"vim",
"vue",
"yaml",
},
},
}

View File

@@ -0,0 +1,15 @@
return {
-- You can also add new plugins here as well:
-- Add plugins, the lazy syntax
"andweeb/presence.nvim",
{
"ray-x/lsp_signature.nvim",
event = "BufRead",
config = function() require("lsp_signature").setup() end,
},
{
"wakatime/vim-wakatime",
lazy = false,
enabled = true,
},
}

View File

@@ -0,0 +1,43 @@
---
tags: [ vcs, alias ]
---
# git branchbydate
List repository branches by date when last updated and extra information.
# git branchcolor
List repository branches sorted by when they were last updated.
# git llog
Show log with fuller information.
# git logs
Git logs with detailed information and git tree.
# git nah
Reset all changes.
# git reset-origin
Reset to origin.
# git reset-upstream
Hard reset to upstream master.
# git rl
Colored reflog.
# git tagdate
List tags in date order and with graph.
# git undo-commit
Undoes last commit.

View File

91
config/cheat/conf.yml Normal file
View File

@@ -0,0 +1,91 @@
---
# The editor to use with 'cheat -e <sheet>'. Defaults to $EDITOR or $VISUAL.
# editor: $EDITOR
# Should 'cheat' always colorize output?
colorize: true
# Which 'chroma' colorscheme should be applied to the output?
# Options are available here:
# https://github.com/alecthomas/chroma/tree/master/styles
style: "catppuccin"
# Which 'chroma' "formatter" should be applied?
# One of: "terminal", "terminal256", "terminal16m"
formatter: terminal256
# Through which pager should output be piped?
# 'less -FRX' is recommended on Unix systems
# 'more' is recommended on Windows
pager: less -FRX
# Cheatpaths are paths at which cheatsheets are available on your local
# filesystem.
#
# It is useful to sort cheatsheets into different cheatpaths for organizational
# purposes. For example, you might want one cheatpath for community
# cheatsheets, one for personal cheatsheets, one for cheatsheets pertaining to
# your day job, one for code snippets, etc.
#
# Cheatpaths are scoped, such that more "local" cheatpaths take priority over
# more "global" cheatpaths. (The most global cheatpath is listed first in this
# file; the most local is listed last.) For example, if there is a 'tar'
# cheatsheet on both global and local paths, you'll be presented with the local
# one by default. ('cheat -p' can be used to view cheatsheets from alternative
# cheatpaths.)
#
# Cheatpaths can also be tagged as "read only". This instructs cheat not to
# automatically create cheatsheets on a read-only cheatpath. Instead, when you
# would like to edit a read-only cheatsheet using 'cheat -e', cheat will
# perform a copy-on-write of that cheatsheet from a read-only cheatpath to a
# writeable cheatpath.
#
# This is very useful when you would like to maintain, for example, a
# "pristine" repository of community cheatsheets on one cheatpath, and an
# editable personal reponsity of cheatsheets on another cheatpath.
#
# Cheatpaths can be also configured to automatically apply tags to cheatsheets
# on certain paths, which can be useful for querying purposes.
# Example: 'cheat -t work jenkins'.
#
# Community cheatsheets must be installed separately, though you may have
# downloaded them automatically when installing 'cheat'. If not, you may
# download them here:
#
# https://github.com/cheat/cheatsheets
cheatpaths:
# Cheatpath properties mean the following:
# 'name': the name of the cheatpath
# (view with 'cheat -d', filter with 'cheat -p')
# 'path': the filesystem path of the cheatsheet directory
# (view with 'cheat -d')
# 'tags': tags that should be automatically applied to sheets on this path
# 'readonly': shall user-created ('cheat -e') cheatsheets be saved here?
- name: community
path: ~/.config/cheat/cheatsheets/community
tags: [ community ]
readonly: true
# If you have personalized cheatsheets, list them last. They will take
# precedence over the more global cheatsheets.
- name: personal
path: ~/.dotfiles/config/cheat/cheatsheets/personal
tags: [ personal ]
readonly: false
- name: pure-bash-bible
path: ~/.dotfiles/config/cheat/cheatsheets/pure-bash-bible
tags: [ pure-bash-bible ]
readonly: true
- name: tldr
path: ~/.dotfiles/config/cheat/cheatsheets/tldr
tags: [ tldr ]
readonly: true
# While it requires no configuration here, it's also worth noting that
# cheat will automatically append directories named '.cheat' within the
# current working directory to the 'cheatpath'. This can be very useful if
# you'd like to closely associate cheatsheets with, for example, a directory
# containing source code.
#
# Such "directory-scoped" cheatsheets will be treated as the most "local"
# cheatsheets, and will override less "local" cheatsheets. Similarly,
# directory-scoped cheatsheets will always be editable ('readonly: false').

View File

@@ -3,7 +3,8 @@
# vim: filetype=zsh
export DOTFILES="$HOME/.dotfiles"
export PATH="$DOTFILES/local/bin:$PATH"
source "$DOTFILES/scripts/shared.sh"
path_append "$DOTFILES/local/bin"
# Explicitly set XDG folders
# https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
@@ -23,21 +24,20 @@ export HOMEBREW_SBIN="$HOMEBREW/sbin"
export HOMEBREW_PKG="$HOMEBREW/opt"
export HOMEBREW_NO_ENV_HINTS=1
export PATH="$XDG_BIN_HOME:$HOMEBREW_BIN:$HOMEBREW_SBIN:/usr/local/sbin:$PATH"
path_append "/usr/local/bin"
path_prepend "$HOMEBREW_SBIN"
path_prepend "$HOMEBREW_BIN"
path_prepend "$XDG_BIN_HOME"
# brew, https://brew.sh
if command -v brew &> /dev/null; then
BREW_PYTHON=$(brew --prefix python)/bin
GNUBIN_DIR=$(brew --prefix coreutils)/libexec/gnubin
BREW_RUBY=$(brew --prefix ruby)/bin
BREW_GEMS=$(gem environment gemdir)/bin
export PATH="$BREW_PYTHON:$GNUBIN_DIR:$BREW_GEMS:$BREW_RUBY:$PATH"
fi
have brew && {
path_append "$(brew --prefix python)/bin"
path_append "$(brew --prefix coreutils)/libexec/gnubin"
path_append "$(brew --prefix ruby)/bin"
path_append "$(gem environment gemdir)/bin"
}
source "$DOTFILES/config/exports-shell"
source "$DOTFILES/config/exports-apps"
if command -v nvim &> /dev/null; then
export EDITOR="nvim"
fi
have nvim && export EDITOR="nvim"

View File

@@ -1,7 +1,9 @@
#!/usr/bin/env bash
# shellcheck shell=bash
# shellcheck enable=external-sources
# shellcheck disable=1091
# vim: filetype=zsh
source "$DOTFILES/scripts/shared.sh"
# Antigen configuration
# https://github.com/zsh-users/antigen/wiki/Configuration
@@ -11,61 +13,78 @@ export ANTIGEN_PLUGIN_RECEIPT_F=".local/share/antigen/antigen_plugin_lastupdate"
# Ansible configuration
# https://docs.ansible.com/ansible/latest/reference_appendices/config.html
if hash ansible 2> /dev/null; then
have ansible && {
export ANSIBLE_HOME="$XDG_CONFIG_HOME/ansible"
export ANSIBLE_CONFIG="$XDG_CONFIG_HOME/ansible.cfg"
export ANSIBLE_GALAXY_CACHE_DIR="$XDG_CACHE_HOME/ansible/galaxy_cache"
x-dc "$ANSIBLE_HOME"
x-dc "$ANSIBLE_GALAXY_CACHE_DIR"
fi
}
# brew configuration
have brew && {
FPATH="$(brew --prefix)/share/zsh/site-functions:${FPATH}"
autoload -Uz compinit
compinit
}
# composer, https://getcomposer.org/
if command -v composer &> /dev/null; then
have composer && {
export COMPOSER_HOME="$XDG_STATE_HOME/composer"
export COMPOSER_BIN="$COMPOSER_HOME/vendor/bin"
export PATH="$COMPOSER_BIN:$PATH"
fi
}
# docker, https://docs.docker.com/engine/reference/commandline/cli/
if command -v docker &> /dev/null; then
have docker && {
export DOCKER_CONFIG="$XDG_CONFIG_HOME/docker"
x-dc "$DOCKER_CONFIG"
fi
# Docker: Disable snyk ad
export DOCKER_SCAN_SUGGEST=false
}
# ffmpeg
if hash ffmpeg 2> /dev/null; then
have ffmpeg && {
export FFMPEG_DATADIR="$XDG_CONFIG_HOME/ffmpeg"
x-dc "$FFMPEG_DATADIR"
fi
}
# gcloud
if hash gcloud 2> /dev/null; then
have gcloud && {
GCLOUD_LOC=$(gcloud info --format="value(installation.sdk_root)" --quiet)
[[ -f "$GCLOUD_LOC/path.zsh.inc" ]] && builtin source "$GCLOUD_LOC/path.zsh.inc"
[[ -f "$GCLOUD_LOC/completion.zsh.inc" ]] && builtin source "$GCLOUD_LOC/completion.zsh.inc"
fi
}
# gem, rubygems
if command -v gem &> /dev/null; then
have gem && {
export GEM_HOME="$XDG_STATE_HOME/gem"
export GEM_PATH="$XDG_STATE_HOME/gem"
export PATH="$GEM_HOME/bin:$PATH"
fi
path_append "$GEM_PATH/bin"
}
# If we have go packages, include them to the PATH
if command -v go &> /dev/null; then
have go && {
export GOPATH="$XDG_DATA_HOME/go"
export GOBIN="$XDG_BIN_HOME"
x-dc "$GOPATH"
fi
}
# irssi
if hash irssi 2> /dev/null; then
have irssi && {
# These variables are used in ./alias with --config and --home
export IRSSI_CONFIG_HOME="$XDG_CONFIG_HOME/irssi"
export IRSSI_CONFIG_FILE="$IRSSI_CONFIG_HOME/config"
x-dc "$IRSSI_CONFIG_HOME"
fi
}
# nb, https://xwmx.github.io/nb/
have nb && {
export NB_DIR="$XDG_STATE_HOME/nb"
x-dc "$NB_DIR"
}
# nvm, the node version manager
export NVM_LAZY_LOAD=true
@@ -75,22 +94,28 @@ export NVM_DIR="$XDG_CONFIG_HOME/nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
# Add npm packages to path
have node && {
NVM_NODE_BIN_DIR="$(dirname "$(which node)")"
path_append "$NVM_NODE_BIN_DIR"
}
# op (1Password cli) is present
if hash op 2> /dev/null; then
have op && {
export OP_CACHE="$XDG_STATE_HOME/1password"
x-dc "$OP_CACHE"
eval "$(op completion zsh)"
compdef _op op
fi
}
# pyenv, python environments
if command -v pyenv &> /dev/null; then
have pyenv && {
export PYENV_ROOT="$XDG_STATE_HOME/pyenv"
x-dc "$PYENV_ROOT"
export PATH="$PYENV_ROOT/bin:$PATH"
path_append "$PYENV_ROOT/bin"
eval "$(pyenv init -)"
fi
}
# wakatime, https://github.com/wakatime/wakatime-cli
export WAKATIME_HOME="$XDG_STATE_HOME/wakatime"
@@ -104,4 +129,6 @@ export _Z_DATA="$XDG_STATE_HOME/z"
export ANDROID_HOME="$XDG_DATA_HOME/android"
export GNUPGHOME="$XDG_DATA_HOME/gnupg"
export SCREENRC="$XDG_CONFIG_HOME/misc/screenrc"
export TMUX_CONF="$XDG_CONFIG_HOME/tmux/tmux.conf"
export BAT_THEME="ansi"
export CHEAT_USE_FZF=true

View File

@@ -1,8 +1,10 @@
#!/usr/bin/env bash
# shellcheck shell=bash
# shellcheck disable=1091,2046
# vim: filetype=zsh
source "$DOTFILES/scripts/shared.sh"
export LC_ALL=fi_FI.utf8
export LC_ALL=fi_FI.UTF-8
# Bash completion file location
export BASH_COMPLETION_USER_FILE="${XDG_CONFIG_HOME}/bash-completion/bash_completion"
@@ -39,10 +41,7 @@ hash shopt 2> /dev/null && shopt -s checkwinsize
&& source "$XDG_BIN_HOME/iterm2_shell_integration.zsh"
# Set dircolors based on the file, if it exists
if command -v dircolors &> /dev/null; then
# shellcheck disable=SC2046
eval $(dircolors "$XDG_CONFIG_HOME/dircolors")
fi
have dircolors && eval $(dircolors "$XDG_CONFIG_HOME/dircolors")
# If we are using zsh, color our dir lists and such
if [ "$SHELL" = "$(which zsh)" ]; then
@@ -51,5 +50,14 @@ if [ "$SHELL" = "$(which zsh)" ]; then
export HISTFILE="$XDG_STATE_HOME/zsh/history"
zstyle ':completion:*' cache-path "$XDG_CACHE_HOME/zsh/zcompcache"
zstyle ':completion:*' list-colors "$LS_COLORS"
# fzf
[ -f "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.zsh ] \
&& source "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.zsh
fi
# If we are using bash
if [ "$SHELL" = "$(which bash)" ]; then
[ -f "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.bash ] \
&& source "${XDG_CONFIG_HOME:-$HOME/.config}"/fzf/fzf.bash
fi

View File

@@ -2,9 +2,11 @@
#
# shell functions
#
# shellcheck source="../scripts/shared.sh"
source "$DOTFILES/scripts/shared.sh"
# Weather in Tampere, or other city
function weather
weather()
{
# https://github.com/chubin/wttr.in#usage
local city="${1:-Tampere}"
@@ -12,25 +14,25 @@ function weather
}
# Docker
function ssh-docker
ssh-docker()
{
docker exec -it "$@" bash
}
# Create a new directory and enter it
function mkd
mkd()
{
mkdir -p "$@" && cd "$@" || exit
}
# All the dig info
function digga
digga()
{
dig +nocmd "$1" any +multiline +noall +answer
}
# Rector project to php version 8.0 by default.
function rector
rector()
{
local php="${1:-80}"
docker run -v "$(pwd)":/project rector/rector:latest process \
@@ -40,7 +42,7 @@ function rector
}
# Commit everything
function commit
commit()
{
commitMessage="$*"
@@ -52,7 +54,7 @@ function commit
eval "git commit -a -m '${commitMessage}'"
}
function scheduler
scheduler()
{
while :; do
php artisan schedule:run
@@ -61,56 +63,45 @@ function scheduler
done
}
function silent
silent()
{
"$@" >&/dev/null
}
# Remove directory from the PATH variable
# usage: path_remove ~/.local/bin
function path_remove
ask()
{
PATH=$(echo -n "$PATH" | awk -v RS=: -v ORS=: "\$0 != \"$1\"" | sed 's/:$//')
}
# Append directory to the PATH
# usage: path_append ~/.local/bin
function path_append
{
path_remove "$1"
PATH="${PATH:+"$PATH:"}$1"
}
# Prepend directory to the PATH
# usage: path_prepend ~/.local/bin
function path_prepend
{
path_remove "$1"
PATH="$1${PATH:+":$PATH"}"
while true; do
read -p "$1 ([y]/n) " -r
REPLY=${REPLY:-"y"}
if [[ $REPLY =~ ^[Yy]$ ]]; then
return 1
elif [[ $REPLY =~ ^[Nn]$ ]]; then
return 0
fi
done
}
# Defines default antigen bundles
function x-default-antigen-bundles
x-default-antigen-bundles()
{
# these should be always available
antigen bundle colored-man-pages
antigen bundle command-not-found
antigen bundle ssh-agent
antigen bundle MichaelAquilina/zsh-you-should-use
antigen bundle Sparragus/zsh-auto-nvm-use
antigen bundle jreese/zsh-titles
antigen bundle unixorn/autoupdate-antigen.zshplugin
antigen bundle zsh-users/zsh-completions
antigen bundle zsh-users/zsh-syntax-highlighting
# these should be available if there's need
hash git 2> /dev/null && antigen bundle git
hash brew 2> /dev/null && antigen bundle brew
hash docker 2> /dev/null && antigen bundle docker
hash docker-compose 2> /dev/null && antigen bundle sroze/docker-compose-zsh-plugin
hash jq 2> /dev/null && antigen bundle reegnz/jq-zsh-plugin
hash nvm 2> /dev/null && antigen bundle nvm
hash php 2> /dev/null && antigen bundle php
hash python 2> /dev/null && antigen bundle MichaelAquilina/zsh-autoswitch-virtualenv
hash rvm 2> /dev/null && antigen bundle unixorn/rvm-plugin
have brew && antigen bundle brew
have docker && antigen bundle docker
have docker-compose && antigen bundle sroze/docker-compose-zsh-plugin
have jq && antigen bundle reegnz/jq-zsh-plugin
have nvm && antigen bundle nvm
have nvm && antigen bundle $DOTFILES/config/zsh/plugins/nvm-auto-use
have php && antigen bundle php
have python && antigen bundle MichaelAquilina/zsh-autoswitch-virtualenv
have rvm && antigen bundle unixorn/rvm-plugin
}

13
config/fzf/fzf.bash Normal file
View File

@@ -0,0 +1,13 @@
# Setup fzf
# ---------
if [[ ! "$PATH" == */Users/ivuorinen/.config/fzf/bin* ]]; then
PATH="${PATH:+${PATH}:}/Users/ivuorinen/.config/fzf/bin"
fi
# Auto-completion
# ---------------
[[ $- == *i* ]] && source "/Users/ivuorinen/.config/fzf/shell/completion.bash" 2> /dev/null
# Key bindings
# ------------
source "/Users/ivuorinen/.config/fzf/shell/key-bindings.bash"

13
config/fzf/fzf.zsh Normal file
View File

@@ -0,0 +1,13 @@
# Setup fzf
# ---------
if [[ ! "$PATH" == */Users/ivuorinen/.config/fzf/bin* ]]; then
PATH="${PATH:+${PATH}:}/Users/ivuorinen/.config/fzf/bin"
fi
# Auto-completion
# ---------------
[[ $- == *i* ]] && source "/Users/ivuorinen/.config/fzf/shell/completion.zsh" 2> /dev/null
# Key bindings
# ------------
source "/Users/ivuorinen/.config/fzf/shell/key-bindings.zsh"

View File

@@ -1,59 +1,7 @@
[include]
path = ~/.dotfiles/config/git/shared
[user]
name = Ismo Vuorinen
email = ismo@ivuorinen.net
[credential]
helper = store --file ~/.cache/git/git-credentials
helper = cache --timeout 30000
[core]
excludesfile = ~/.config/git/gitignore
[alias]
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
nah = !git reset --hard && git clean -df
undo-commit = reset HEAD~ --soft
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
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\"
branchbydate = for-each-ref --count=30 --sort=-committerdate refs/heads/ --format='%(refname:short)'
branchcolor = "!for ref in $(git for-each-ref --sort=-committerdate --format=\"%(refname)\" refs/heads/ refs/remotes ); do git log -n1 $ref --pretty=format:\"%Cgreen%cr%Creset %C(yellow)%d%Creset %C(bold blue)<%an>%Creset%n\" | cat ; done | awk '! a[$0]++'"
[diff]
tool = difftastic
[difftool]
prompt = false
[difftool "difftastic"]
cmd = difft "$LOCAL" "$REMOTE"
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true
[init]
defaultBranch = main
[pull]
rebase = true
[color]
ui = true
diff = auto
branch = auto
status = auto
[color "status"]
added = green bold
changed = yellow
deleted = red bold strike
untracked = cyan
branch = yellow black bold ul
[submodule]
recurse = true

64
config/git/shared Normal file
View File

@@ -0,0 +1,64 @@
[credential]
helper = store --file ~/.cache/git/git-credentials
helper = cache --timeout 30000
[core]
excludesfile = ~/.config/git/gitignore
[init]
defaultBranch = main
[pull]
rebase = true
[gpg]
format = ssh
[alias]
branchbydate = for-each-ref --count=30 --sort=-committerdate refs/heads/ --format='%(refname:short)'
branchcolor = "!for ref in $(git for-each-ref --sort=-committerdate --format=\"%(refname)\" refs/heads/ refs/remotes ); do git log -n1 $ref --pretty=format:\"%Cgreen%cr%Creset %C(yellow)%d%Creset %C(bold blue)<%an>%Creset%n\" | cat ; done | awk '! a[$0]++'"
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
nah = !git reset --hard && git clean -df
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
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)'
tagdate = log --date-order --graph --tags --simplify-by-decoration --pretty=format:\"%ai %h %d\"
undo-commit = reset HEAD~ --soft
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true
[diff]
tool = difftastic
[difftool]
prompt = false
[difftool "difftastic"]
cmd = difft "$LOCAL" "$REMOTE"
[color]
ui = true
diff = auto
branch = auto
status = auto
[color "status"]
added = green bold
changed = yellow
deleted = red bold strike
untracked = cyan
branch = yellow black bold ul
[submodule]
recurse = true
# dotfiles special config
[includeIf "hasconfig:remote.*.url:https://github.com/ivuorinen/dotfiles.git"]
path = ~/.dotfiles/config/git/special/dotfiles ;

View File

@@ -0,0 +1,2 @@
[submodule]
recurse = false

View File

@@ -0,0 +1,331 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Ansi 0 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.27058823529411763</real>
<key>Green Component</key>
<real>0.2784313725490196</real>
<key>Blue Component</key>
<real>0.35294117647058826</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 1 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.9529411764705882</real>
<key>Green Component</key>
<real>0.5450980392156862</real>
<key>Blue Component</key>
<real>0.6588235294117647</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 2 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.6509803921568628</real>
<key>Green Component</key>
<real>0.8901960784313725</real>
<key>Blue Component</key>
<real>0.6313725490196078</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 3 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.9764705882352941</real>
<key>Green Component</key>
<real>0.8862745098039215</real>
<key>Blue Component</key>
<real>0.6862745098039216</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 4 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.5372549019607843</real>
<key>Green Component</key>
<real>0.7058823529411765</real>
<key>Blue Component</key>
<real>0.9803921568627451</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 5 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.9607843137254902</real>
<key>Green Component</key>
<real>0.7607843137254902</real>
<key>Blue Component</key>
<real>0.9058823529411765</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 6 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.5803921568627451</real>
<key>Green Component</key>
<real>0.8862745098039215</real>
<key>Blue Component</key>
<real>0.8352941176470589</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 7 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.7294117647058823</real>
<key>Green Component</key>
<real>0.7607843137254902</real>
<key>Blue Component</key>
<real>0.8705882352941177</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 8 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.34509803921568627</real>
<key>Green Component</key>
<real>0.3568627450980392</real>
<key>Blue Component</key>
<real>0.4392156862745098</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 9 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.9529411764705882</real>
<key>Green Component</key>
<real>0.5450980392156862</real>
<key>Blue Component</key>
<real>0.6588235294117647</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 10 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.6509803921568628</real>
<key>Green Component</key>
<real>0.8901960784313725</real>
<key>Blue Component</key>
<real>0.6313725490196078</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 11 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.9764705882352941</real>
<key>Green Component</key>
<real>0.8862745098039215</real>
<key>Blue Component</key>
<real>0.6862745098039216</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 12 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.5372549019607843</real>
<key>Green Component</key>
<real>0.7058823529411765</real>
<key>Blue Component</key>
<real>0.9803921568627451</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 13 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.9607843137254902</real>
<key>Green Component</key>
<real>0.7607843137254902</real>
<key>Blue Component</key>
<real>0.9058823529411765</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 14 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.5803921568627451</real>
<key>Green Component</key>
<real>0.8862745098039215</real>
<key>Blue Component</key>
<real>0.8352941176470589</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Ansi 15 Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.6509803921568628</real>
<key>Green Component</key>
<real>0.6784313725490196</real>
<key>Blue Component</key>
<real>0.7843137254901961</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Background Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.11764705882352941</real>
<key>Green Component</key>
<real>0.11764705882352941</real>
<key>Blue Component</key>
<real>0.1803921568627451</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Foreground Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.803921568627451</real>
<key>Green Component</key>
<real>0.8392156862745098</real>
<key>Blue Component</key>
<real>0.9568627450980393</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Link Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.5372549019607843</real>
<key>Green Component</key>
<real>0.8627450980392157</real>
<key>Blue Component</key>
<real>0.9215686274509803</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Bold Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.803921568627451</real>
<key>Green Component</key>
<real>0.8392156862745098</real>
<key>Blue Component</key>
<real>0.9568627450980393</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Cursor Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.9607843137254902</real>
<key>Green Component</key>
<real>0.8784313725490196</real>
<key>Blue Component</key>
<real>0.8627450980392157</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Cursor Text Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.803921568627451</real>
<key>Green Component</key>
<real>0.8392156862745098</real>
<key>Blue Component</key>
<real>0.9568627450980393</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Cursor Guide Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.803921568627451</real>
<key>Green Component</key>
<real>0.8392156862745098</real>
<key>Blue Component</key>
<real>0.9568627450980393</real>
<key>Alpha Component</key>
<real>0.07</real>
</dict>
<key>Selection Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.34509803921568627</real>
<key>Green Component</key>
<real>0.3568627450980392</real>
<key>Blue Component</key>
<real>0.4392156862745098</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
<key>Selected Text Color</key>
<dict>
<key>Color Space</key>
<string>sRGB</string>
<key>Red Component</key>
<real>0.803921568627451</real>
<key>Green Component</key>
<real>0.8392156862745098</real>
<key>Blue Component</key>
<real>0.9568627450980393</real>
<key>Alpha Component</key>
<real>1</real>
</dict>
</dict>
</plist>

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,417 @@
{
"Badge Text" : "",
"Working Directory" : "\/Users\/ivuorinen\/Code",
"Prompt Before Closing 2" : false,
"Selected Text Color" : {
"Red Component" : 0.80392156862745101,
"Color Space" : "sRGB",
"Blue Component" : 0.95686274509803926,
"Alpha Component" : 1,
"Green Component" : 0.83921568627450982
},
"Rows" : 25,
"Ansi 11 Color" : {
"Red Component" : 0.97647058823529409,
"Color Space" : "sRGB",
"Blue Component" : 0.68627450980392157,
"Alpha Component" : 1,
"Green Component" : 0.88627450980392153
},
"Use Italic Font" : true,
"Foreground Color" : {
"Red Component" : 0.80392156862745101,
"Color Space" : "sRGB",
"Blue Component" : 0.95686274509803926,
"Alpha Component" : 1,
"Green Component" : 0.83921568627450982
},
"Right Option Key Sends" : 0,
"Character Encoding" : 4,
"Selection Color" : {
"Red Component" : 0.34509803921568627,
"Color Space" : "sRGB",
"Blue Component" : 0.4392156862745098,
"Alpha Component" : 1,
"Green Component" : 0.35686274509803922
},
"Blend" : 0.24709154211956524,
"Mouse Reporting" : true,
"Cursor Boost" : 0,
"Ansi 4 Color" : {
"Red Component" : 0.53725490196078429,
"Color Space" : "sRGB",
"Blue Component" : 0.98039215686274506,
"Alpha Component" : 1,
"Green Component" : 0.70588235294117652
},
"Non-ASCII Anti Aliased" : true,
"Sync Title" : false,
"Badge Font" : "JetBrainsMonoNerdFontCompleteM-Bold",
"Disable Window Resizing" : true,
"Description" : "Default",
"Close Sessions On End" : true,
"Jobs to Ignore" : [
"rlogin",
"ssh",
"slogin",
"telnet"
],
"Scrollback Lines" : 0,
"Draw Powerline Glyphs" : true,
"Flashing Bell" : true,
"Cursor Guide Color" : {
"Red Component" : 0.80392156862745101,
"Color Space" : "sRGB",
"Blue Component" : 0.95686274509803926,
"Alpha Component" : 0.070000000000000007,
"Green Component" : 0.83921568627450982
},
"BM Growl" : true,
"Ansi 3 Color" : {
"Red Component" : 0.97647058823529409,
"Color Space" : "sRGB",
"Blue Component" : 0.68627450980392157,
"Alpha Component" : 1,
"Green Component" : 0.88627450980392153
},
"Icon" : 1,
"Use Non-ASCII Font" : false,
"Link Color" : {
"Red Component" : 0.53725490196078429,
"Color Space" : "sRGB",
"Blue Component" : 0.92156862745098034,
"Alpha Component" : 1,
"Green Component" : 0.86274509803921573
},
"Shortcut" : "",
"Background Image Location" : "",
"Bold Color" : {
"Red Component" : 0.80392156862745101,
"Color Space" : "sRGB",
"Blue Component" : 0.95686274509803926,
"Alpha Component" : 1,
"Green Component" : 0.83921568627450982
},
"Use Cursor Guide" : false,
"Unlimited Scrollback" : true,
"Custom Command" : "No",
"Title Components" : 512,
"Keyboard Map" : {
"0xf700-0x260000" : {
"Action" : 10,
"Text" : "[1;6A"
},
"0x37-0x40000" : {
"Action" : 11,
"Text" : "0x1f"
},
"0x32-0x40000" : {
"Action" : 11,
"Text" : "0x00"
},
"0xf709-0x20000" : {
"Action" : 10,
"Text" : "[17;2~"
},
"0xf70c-0x20000" : {
"Action" : 10,
"Text" : "[20;2~"
},
"0xf729-0x20000" : {
"Action" : 10,
"Text" : "[1;2H"
},
"0xf72b-0x40000" : {
"Action" : 10,
"Text" : "[1;5F"
},
"0xf705-0x20000" : {
"Action" : 10,
"Text" : "[1;2Q"
},
"0xf703-0x260000" : {
"Action" : 10,
"Text" : "[1;6C"
},
"0xf700-0x220000" : {
"Action" : 10,
"Text" : "[1;2A"
},
"0xf701-0x280000" : {
"Action" : 11,
"Text" : "0x1b 0x1b 0x5b 0x42"
},
"0x38-0x40000" : {
"Action" : 11,
"Text" : "0x7f"
},
"0x33-0x40000" : {
"Action" : 11,
"Text" : "0x1b"
},
"0xf703-0x220000" : {
"Action" : 10,
"Text" : "[1;2C"
},
"0xf701-0x240000" : {
"Action" : 10,
"Text" : "[1;5B"
},
"0xf70d-0x20000" : {
"Action" : 10,
"Text" : "[21;2~"
},
"0xf702-0x260000" : {
"Action" : 10,
"Text" : "[1;6D"
},
"0xf729-0x40000" : {
"Action" : 10,
"Text" : "[1;5H"
},
"0xf706-0x20000" : {
"Action" : 10,
"Text" : "[1;2R"
},
"0x34-0x40000" : {
"Action" : 11,
"Text" : "0x1c"
},
"0xf700-0x280000" : {
"Action" : 11,
"Text" : "0x1b 0x1b 0x5b 0x41"
},
"0x2d-0x40000" : {
"Action" : 11,
"Text" : "0x1f"
},
"0xf70e-0x20000" : {
"Action" : 10,
"Text" : "[23;2~"
},
"0xf702-0x220000" : {
"Action" : 10,
"Text" : "[1;2D"
},
"0xf703-0x280000" : {
"Action" : 11,
"Text" : "0x1b 0x1b 0x5b 0x43"
},
"0xf700-0x240000" : {
"Action" : 10,
"Text" : "[1;5A"
},
"0xf707-0x20000" : {
"Action" : 10,
"Text" : "[1;2S"
},
"0xf70a-0x20000" : {
"Action" : 10,
"Text" : "[18;2~"
},
"0x35-0x40000" : {
"Action" : 11,
"Text" : "0x1d"
},
"0xf70f-0x20000" : {
"Action" : 10,
"Text" : "[24;2~"
},
"0xf703-0x240000" : {
"Action" : 10,
"Text" : "[1;5C"
},
"0xf701-0x260000" : {
"Action" : 10,
"Text" : "[1;6B"
},
"0xf702-0x280000" : {
"Action" : 11,
"Text" : "0x1b 0x1b 0x5b 0x44"
},
"0xf72b-0x20000" : {
"Action" : 10,
"Text" : "[1;2F"
},
"0x36-0x40000" : {
"Action" : 11,
"Text" : "0x1e"
},
"0xf708-0x20000" : {
"Action" : 10,
"Text" : "[15;2~"
},
"0xf701-0x220000" : {
"Action" : 10,
"Text" : "[1;2B"
},
"0xf70b-0x20000" : {
"Action" : 10,
"Text" : "[19;2~"
},
"0xf702-0x240000" : {
"Action" : 10,
"Text" : "[1;5D"
},
"0xf704-0x20000" : {
"Action" : 10,
"Text" : "[1;2P"
}
},
"Ansi 14 Color" : {
"Red Component" : 0.58039215686274515,
"Color Space" : "sRGB",
"Blue Component" : 0.83529411764705885,
"Alpha Component" : 1,
"Green Component" : 0.88627450980392153
},
"Ansi 2 Color" : {
"Red Component" : 0.65098039215686276,
"Color Space" : "sRGB",
"Blue Component" : 0.63137254901960782,
"Alpha Component" : 1,
"Green Component" : 0.8901960784313725
},
"Send Code When Idle" : false,
"ASCII Anti Aliased" : true,
"Tags" : [
],
"Ansi 9 Color" : {
"Red Component" : 0.95294117647058818,
"Color Space" : "sRGB",
"Blue Component" : 0.6588235294117647,
"Alpha Component" : 1,
"Green Component" : 0.54509803921568623
},
"Badge Right Margin" : 10,
"Use Bold Font" : true,
"Silence Bell" : false,
"Ansi 12 Color" : {
"Red Component" : 0.53725490196078429,
"Color Space" : "sRGB",
"Blue Component" : 0.98039215686274506,
"Alpha Component" : 1,
"Green Component" : 0.70588235294117652
},
"Window Type" : 0,
"Use Bright Bold" : true,
"Cursor Text Color" : {
"Red Component" : 0.80392156862745101,
"Color Space" : "sRGB",
"Blue Component" : 0.95686274509803926,
"Alpha Component" : 1,
"Green Component" : 0.83921568627450982
},
"Default Bookmark" : "No",
"Cursor Color" : {
"Red Component" : 0.96078431372549022,
"Color Space" : "sRGB",
"Blue Component" : 0.86274509803921573,
"Alpha Component" : 1,
"Green Component" : 0.8784313725490196
},
"Ansi 1 Color" : {
"Red Component" : 0.95294117647058818,
"Color Space" : "sRGB",
"Blue Component" : 0.6588235294117647,
"Alpha Component" : 1,
"Green Component" : 0.54509803921568623
},
"Name" : "Default",
"Blinking Cursor" : false,
"Guid" : "82636119-EA17-4A26-9AA7-408172F4A9C8",
"Badge Max Width" : 0.45000000000000001,
"Idle Code" : 0,
"Ansi 10 Color" : {
"Red Component" : 0.65098039215686276,
"Color Space" : "sRGB",
"Blue Component" : 0.63137254901960782,
"Alpha Component" : 1,
"Green Component" : 0.8901960784313725
},
"Ansi 8 Color" : {
"Red Component" : 0.34509803921568627,
"Color Space" : "sRGB",
"Blue Component" : 0.4392156862745098,
"Alpha Component" : 1,
"Green Component" : 0.35686274509803922
},
"Badge Color" : {
"Red Component" : 1,
"Color Space" : "sRGB",
"Blue Component" : 0,
"Alpha Component" : 0.5,
"Green Component" : 0.14910030364990234
},
"Smart Cursor Color" : true,
"Ambiguous Double Width" : false,
"Blur Radius" : 9.5927277260638313,
"Badge Max Height" : 0.10000000000000001,
"Ansi 0 Color" : {
"Red Component" : 0.27058823529411763,
"Color Space" : "sRGB",
"Blue Component" : 0.35294117647058826,
"Alpha Component" : 1,
"Green Component" : 0.27843137254901962
},
"Blur" : true,
"Normal Font" : "JetBrainsMonoNerdFontCompleteM-Light 15",
"Vertical Spacing" : 1,
"Ansi 7 Color" : {
"Red Component" : 0.72941176470588232,
"Color Space" : "sRGB",
"Blue Component" : 0.87058823529411766,
"Alpha Component" : 1,
"Green Component" : 0.76078431372549016
},
"Command" : "",
"Terminal Type" : "xterm-256color",
"Horizontal Spacing" : 1,
"Option Key Sends" : 0,
"Only The Default BG Color Uses Transparency" : true,
"Minimum Contrast" : 0.14973958333333334,
"Ansi 15 Color" : {
"Red Component" : 0.65098039215686276,
"Color Space" : "sRGB",
"Blue Component" : 0.78431372549019607,
"Alpha Component" : 1,
"Green Component" : 0.67843137254901964
},
"Ansi 6 Color" : {
"Red Component" : 0.58039215686274515,
"Color Space" : "sRGB",
"Blue Component" : 0.83529411764705885,
"Alpha Component" : 1,
"Green Component" : 0.88627450980392153
},
"Badge Top Margin" : 10,
"Transparency" : 0.10293218085106381,
"Background Color" : {
"Red Component" : 0.11764705882352941,
"Color Space" : "sRGB",
"Blue Component" : 0.1803921568627451,
"Alpha Component" : 1,
"Green Component" : 0.11764705882352941
},
"Screen" : -2,
"Non Ascii Font" : "Monaco 12",
"Ansi 13 Color" : {
"Red Component" : 0.96078431372549022,
"Color Space" : "sRGB",
"Blue Component" : 0.90588235294117647,
"Alpha Component" : 1,
"Green Component" : 0.76078431372549016
},
"Columns" : 120,
"Visual Bell" : true,
"ASCII Ligatures" : false,
"Ansi 5 Color" : {
"Red Component" : 0.96078431372549022,
"Color Space" : "sRGB",
"Blue Component" : 0.90588235294117647,
"Alpha Component" : 1,
"Green Component" : 0.76078431372549016
},
"Custom Directory" : "Yes"
}

864
config/neofetch/config.conf Normal file
View File

@@ -0,0 +1,864 @@
# See this wiki page for more info:
# https://github.com/dylanaraps/neofetch/wiki/Customizing-Info
print_info() {
info title
info underline
info "OS" distro
info "Host" model
# info "Kernel" kernel
info "Uptime" uptime
# info "Packages" packages
info "Shell" shell
info "Resolution" resolution
# info "DE" de
# info "WM" wm
# info "WM Theme" wm_theme
info "Theme" theme
info "Icons" icons
info "Terminal" term
info "Terminal Font" term_font
info "CPU" cpu
info "GPU" gpu
info "Memory" memory
# info "GPU Driver" gpu_driver # Linux/macOS only
# info "CPU Usage" cpu_usage
# info "Disk" disk
# info "Battery" battery
# info "Font" font
# info "Song" song
# [[ "$player" ]] && prin "Music Player" "$player"
info "Local IP" local_ip
# info "Public IP" public_ip
# info "Users" users
info "Locale" locale # This only works on glibc systems.
info cols
}
# Title
# Hide/Show Fully qualified domain name.
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --title_fqdn
title_fqdn="off"
# Kernel
# Shorten the output of the kernel function.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --kernel_shorthand
# Supports: Everything except *BSDs (except PacBSD and PC-BSD)
#
# Example:
# on: '4.8.9-1-ARCH'
# off: 'Linux 4.8.9-1-ARCH'
kernel_shorthand="on"
# Distro
# Shorten the output of the distro function
#
# Default: 'off'
# Values: 'on', 'tiny', 'off'
# Flag: --distro_shorthand
# Supports: Everything except Windows and Haiku
distro_shorthand="on"
# Show/Hide OS Architecture.
# Show 'x86_64', 'x86' and etc in 'Distro:' output.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --os_arch
#
# Example:
# on: 'Arch Linux x86_64'
# off: 'Arch Linux'
os_arch="on"
# Uptime
# Shorten the output of the uptime function
#
# Default: 'on'
# Values: 'on', 'tiny', 'off'
# Flag: --uptime_shorthand
#
# Example:
# on: '2 days, 10 hours, 3 mins'
# tiny: '2d 10h 3m'
# off: '2 days, 10 hours, 3 minutes'
uptime_shorthand="tiny"
# Memory
# Show memory pecentage in output.
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --memory_percent
#
# Example:
# on: '1801MiB / 7881MiB (22%)'
# off: '1801MiB / 7881MiB'
memory_percent="on"
# Change memory output unit.
#
# Default: 'mib'
# Values: 'kib', 'mib', 'gib'
# Flag: --memory_unit
#
# Example:
# kib '1020928KiB / 7117824KiB'
# mib '1042MiB / 6951MiB'
# gib: ' 0.98GiB / 6.79GiB'
memory_unit="gib"
# Packages
# Show/Hide Package Manager names.
#
# Default: 'tiny'
# Values: 'on', 'tiny' 'off'
# Flag: --package_managers
#
# Example:
# on: '998 (pacman), 8 (flatpak), 4 (snap)'
# tiny: '908 (pacman, flatpak, snap)'
# off: '908'
package_managers="on"
# Shell
# Show the path to $SHELL
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --shell_path
#
# Example:
# on: '/bin/bash'
# off: 'bash'
shell_path="off"
# Show $SHELL version
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --shell_version
#
# Example:
# on: 'bash 4.4.5'
# off: 'bash'
shell_version="on"
# CPU
# CPU speed type
#
# Default: 'bios_limit'
# Values: 'scaling_cur_freq', 'scaling_min_freq', 'scaling_max_freq', 'bios_limit'.
# Flag: --speed_type
# Supports: Linux with 'cpufreq'
# NOTE: Any file in '/sys/devices/system/cpu/cpu0/cpufreq' can be used as a value.
speed_type="bios_limit"
# CPU speed shorthand
#
# Default: 'off'
# Values: 'on', 'off'.
# Flag: --speed_shorthand
# NOTE: This flag is not supported in systems with CPU speed less than 1 GHz
#
# Example:
# on: 'i7-6500U (4) @ 3.1GHz'
# off: 'i7-6500U (4) @ 3.100GHz'
speed_shorthand="off"
# Enable/Disable CPU brand in output.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --cpu_brand
#
# Example:
# on: 'Intel i7-6500U'
# off: 'i7-6500U (4)'
cpu_brand="on"
# CPU Speed
# Hide/Show CPU speed.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --cpu_speed
#
# Example:
# on: 'Intel i7-6500U (4) @ 3.1GHz'
# off: 'Intel i7-6500U (4)'
cpu_speed="on"
# CPU Cores
# Display CPU cores in output
#
# Default: 'logical'
# Values: 'logical', 'physical', 'off'
# Flag: --cpu_cores
# Support: 'physical' doesn't work on BSD.
#
# Example:
# logical: 'Intel i7-6500U (4) @ 3.1GHz' (All virtual cores)
# physical: 'Intel i7-6500U (2) @ 3.1GHz' (All physical cores)
# off: 'Intel i7-6500U @ 3.1GHz'
cpu_cores="logical"
# CPU Temperature
# Hide/Show CPU temperature.
# Note the temperature is added to the regular CPU function.
#
# Default: 'off'
# Values: 'C', 'F', 'off'
# Flag: --cpu_temp
# Supports: Linux, BSD
# NOTE: For FreeBSD and NetBSD-based systems, you'll need to enable
# coretemp kernel module. This only supports newer Intel processors.
#
# Example:
# C: 'Intel i7-6500U (4) @ 3.1GHz [27.2°C]'
# F: 'Intel i7-6500U (4) @ 3.1GHz [82.0°F]'
# off: 'Intel i7-6500U (4) @ 3.1GHz'
cpu_temp="off"
# GPU
# Enable/Disable GPU Brand
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --gpu_brand
#
# Example:
# on: 'AMD HD 7950'
# off: 'HD 7950'
gpu_brand="on"
# Which GPU to display
#
# Default: 'all'
# Values: 'all', 'dedicated', 'integrated'
# Flag: --gpu_type
# Supports: Linux
#
# Example:
# all:
# GPU1: AMD HD 7950
# GPU2: Intel Integrated Graphics
#
# dedicated:
# GPU1: AMD HD 7950
#
# integrated:
# GPU1: Intel Integrated Graphics
gpu_type="all"
# Resolution
# Display refresh rate next to each monitor
# Default: 'off'
# Values: 'on', 'off'
# Flag: --refresh_rate
# Supports: Doesn't work on Windows.
#
# Example:
# on: '1920x1080 @ 60Hz'
# off: '1920x1080'
refresh_rate="off"
# Gtk Theme / Icons / Font
# Shorten output of GTK Theme / Icons / Font
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --gtk_shorthand
#
# Example:
# on: 'Numix, Adwaita'
# off: 'Numix [GTK2], Adwaita [GTK3]'
gtk_shorthand="off"
# Enable/Disable gtk2 Theme / Icons / Font
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --gtk2
#
# Example:
# on: 'Numix [GTK2], Adwaita [GTK3]'
# off: 'Adwaita [GTK3]'
gtk2="on"
# Enable/Disable gtk3 Theme / Icons / Font
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --gtk3
#
# Example:
# on: 'Numix [GTK2], Adwaita [GTK3]'
# off: 'Numix [GTK2]'
gtk3="on"
# IP Address
# Website to ping for the public IP
#
# Default: 'http://ident.me'
# Values: 'url'
# Flag: --ip_host
public_ip_host="http://ident.me"
# Public IP timeout.
#
# Default: '2'
# Values: 'int'
# Flag: --ip_timeout
public_ip_timeout=2
# Desktop Environment
# Show Desktop Environment version
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --de_version
de_version="on"
# Disk
# Which disks to display.
# The values can be any /dev/sdXX, mount point or directory.
# NOTE: By default we only show the disk info for '/'.
#
# Default: '/'
# Values: '/', '/dev/sdXX', '/path/to/drive'.
# Flag: --disk_show
#
# Example:
# disk_show=('/' '/dev/sdb1'):
# 'Disk (/): 74G / 118G (66%)'
# 'Disk (/mnt/Videos): 823G / 893G (93%)'
#
# disk_show=('/'):
# 'Disk (/): 74G / 118G (66%)'
#
disk_show=('/')
# Disk subtitle.
# What to append to the Disk subtitle.
#
# Default: 'mount'
# Values: 'mount', 'name', 'dir', 'none'
# Flag: --disk_subtitle
#
# Example:
# name: 'Disk (/dev/sda1): 74G / 118G (66%)'
# 'Disk (/dev/sdb2): 74G / 118G (66%)'
#
# mount: 'Disk (/): 74G / 118G (66%)'
# 'Disk (/mnt/Local Disk): 74G / 118G (66%)'
# 'Disk (/mnt/Videos): 74G / 118G (66%)'
#
# dir: 'Disk (/): 74G / 118G (66%)'
# 'Disk (Local Disk): 74G / 118G (66%)'
# 'Disk (Videos): 74G / 118G (66%)'
#
# none: 'Disk: 74G / 118G (66%)'
# 'Disk: 74G / 118G (66%)'
# 'Disk: 74G / 118G (66%)'
disk_subtitle="mount"
# Disk percent.
# Show/Hide disk percent.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --disk_percent
#
# Example:
# on: 'Disk (/): 74G / 118G (66%)'
# off: 'Disk (/): 74G / 118G'
disk_percent="on"
# Song
# Manually specify a music player.
#
# Default: 'auto'
# Values: 'auto', 'player-name'
# Flag: --music_player
#
# Available values for 'player-name':
#
# amarok
# audacious
# banshee
# bluemindo
# clementine
# cmus
# deadbeef
# deepin-music
# dragon
# elisa
# exaile
# gnome-music
# gmusicbrowser
# gogglesmm
# guayadeque
# io.elementary.music
# iTunes
# juk
# lollypop
# mocp
# mopidy
# mpd
# muine
# netease-cloud-music
# olivia
# playerctl
# pogo
# pragha
# qmmp
# quodlibet
# rhythmbox
# sayonara
# smplayer
# spotify
# strawberry
# tauonmb
# tomahawk
# vlc
# xmms2d
# xnoise
# yarock
music_player="auto"
# Format to display song information.
#
# Default: '%artist% - %album% - %title%'
# Values: '%artist%', '%album%', '%title%'
# Flag: --song_format
#
# Example:
# default: 'Song: Jet - Get Born - Sgt Major'
song_format="%artist% - %album% - %title%"
# Print the Artist, Album and Title on separate lines
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --song_shorthand
#
# Example:
# on: 'Artist: The Fratellis'
# 'Album: Costello Music'
# 'Song: Chelsea Dagger'
#
# off: 'Song: The Fratellis - Costello Music - Chelsea Dagger'
song_shorthand="off"
# 'mpc' arguments (specify a host, password etc).
#
# Default: ''
# Example: mpc_args=(-h HOST -P PASSWORD)
mpc_args=()
# Text Colors
# Text Colors
#
# Default: 'distro'
# Values: 'distro', 'num' 'num' 'num' 'num' 'num' 'num'
# Flag: --colors
#
# Each number represents a different part of the text in
# this order: 'title', '@', 'underline', 'subtitle', 'colon', 'info'
#
# Example:
# colors=(distro) - Text is colored based on Distro colors.
# colors=(4 6 1 8 8 6) - Text is colored in the order above.
colors=(distro)
# Text Options
# Toggle bold text
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --bold
bold="on"
# Enable/Disable Underline
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --underline
underline_enabled="on"
# Underline character
#
# Default: '-'
# Values: 'string'
# Flag: --underline_char
underline_char="-"
# Info Separator
# Replace the default separator with the specified string.
#
# Default: ':'
# Flag: --separator
#
# Example:
# separator="->": 'Shell-> bash'
# separator=" =": 'WM = dwm'
separator=":"
# Color Blocks
# Color block range
# The range of colors to print.
#
# Default: '0', '15'
# Values: 'num'
# Flag: --block_range
#
# Example:
#
# Display colors 0-7 in the blocks. (8 colors)
# neofetch --block_range 0 7
#
# Display colors 0-15 in the blocks. (16 colors)
# neofetch --block_range 0 15
block_range=(0 15)
# Toggle color blocks
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --color_blocks
color_blocks="on"
# Color block width in spaces
#
# Default: '3'
# Values: 'num'
# Flag: --block_width
block_width=3
# Color block height in lines
#
# Default: '1'
# Values: 'num'
# Flag: --block_height
block_height=1
# Color Alignment
#
# Default: 'auto'
# Values: 'auto', 'num'
# Flag: --col_offset
#
# Number specifies how far from the left side of the terminal (in spaces) to
# begin printing the columns, in case you want to e.g. center them under your
# text.
# Example:
# col_offset="auto" - Default behavior of neofetch
# col_offset=7 - Leave 7 spaces then print the colors
col_offset="auto"
# Progress Bars
# Bar characters
#
# Default: '-', '='
# Values: 'string', 'string'
# Flag: --bar_char
#
# Example:
# neofetch --bar_char 'elapsed' 'total'
# neofetch --bar_char '-' '='
bar_char_elapsed="-"
bar_char_total="="
# Toggle Bar border
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --bar_border
bar_border="on"
# Progress bar length in spaces
# Number of chars long to make the progress bars.
#
# Default: '15'
# Values: 'num'
# Flag: --bar_length
bar_length=15
# Progress bar colors
# When set to distro, uses your distro's logo colors.
#
# Default: 'distro', 'distro'
# Values: 'distro', 'num'
# Flag: --bar_colors
#
# Example:
# neofetch --bar_colors 3 4
# neofetch --bar_colors distro 5
bar_color_elapsed="distro"
bar_color_total="distro"
# Info display
# Display a bar with the info.
#
# Default: 'off'
# Values: 'bar', 'infobar', 'barinfo', 'off'
# Flags: --cpu_display
# --memory_display
# --battery_display
# --disk_display
#
# Example:
# bar: '[---=======]'
# infobar: 'info [---=======]'
# barinfo: '[---=======] info'
# off: 'info'
cpu_display="off"
memory_display="off"
battery_display="off"
disk_display="off"
# Backend Settings
# Image backend.
#
# Default: 'ascii'
# Values: 'ascii', 'caca', 'chafa', 'jp2a', 'iterm2', 'off',
# 'pot', 'termpix', 'pixterm', 'tycat', 'w3m', 'kitty'
# Flag: --backend
image_backend="ascii"
# Image Source
#
# Which image or ascii file to display.
#
# Default: 'auto'
# Values: 'auto', 'ascii', 'wallpaper', '/path/to/img', '/path/to/ascii', '/path/to/dir/'
# 'command output (neofetch --ascii "$(fortune | cowsay -W 30)")'
# Flag: --source
#
# NOTE: 'auto' will pick the best image source for whatever image backend is used.
# In ascii mode, distro ascii art will be used and in an image mode, your
# wallpaper will be used.
image_source="auto"
# Ascii Options
# Ascii distro
# Which distro's ascii art to display.
#
# Default: 'auto'
# Values: 'auto', 'distro_name'
# Flag: --ascii_distro
# NOTE: AIX, Alpine, Anarchy, Android, Antergos, antiX, "AOSC OS",
# "AOSC OS/Retro", Apricity, ArcoLinux, ArchBox, ARCHlabs,
# ArchStrike, XFerience, ArchMerge, Arch, Artix, Arya, Bedrock,
# Bitrig, BlackArch, BLAG, BlankOn, BlueLight, bonsai, BSD,
# BunsenLabs, Calculate, Carbs, CentOS, Chakra, ChaletOS,
# Chapeau, Chrom*, Cleanjaro, ClearOS, Clear_Linux, Clover,
# Condres, Container_Linux, CRUX, Cucumber, Debian, Deepin,
# DesaOS, Devuan, DracOS, DarkOs, DragonFly, Drauger, Elementary,
# EndeavourOS, Endless, EuroLinux, Exherbo, Fedora, Feren, FreeBSD,
# FreeMiNT, Frugalware, Funtoo, GalliumOS, Garuda, Gentoo, Pentoo,
# gNewSense, GNOME, GNU, GoboLinux, Grombyang, Guix, Haiku, Huayra,
# Hyperbola, janus, Kali, KaOS, KDE_neon, Kibojoe, Kogaion,
# Korora, KSLinux, Kubuntu, LEDE, LFS, Linux_Lite,
# LMDE, Lubuntu, Lunar, macos, Mageia, MagpieOS, Mandriva,
# Manjaro, Maui, Mer, Minix, LinuxMint, MX_Linux, Namib,
# Neptune, NetBSD, Netrunner, Nitrux, NixOS, Nurunner,
# NuTyX, OBRevenge, OpenBSD, openEuler, OpenIndiana, openmamba,
# OpenMandriva, OpenStage, OpenWrt, osmc, Oracle, OS Elbrus, PacBSD,
# Parabola, Pardus, Parrot, Parsix, TrueOS, PCLinuxOS, Peppermint,
# popos, Porteus, PostMarketOS, Proxmox, Puppy, PureOS, Qubes, Radix,
# Raspbian, Reborn_OS, Redstar, Redcore, Redhat, Refracted_Devuan,
# Regata, Rosa, sabotage, Sabayon, Sailfish, SalentOS, Scientific,
# Septor, SereneLinux, SharkLinux, Siduction, Slackware, SliTaz,
# SmartOS, Solus, Source_Mage, Sparky, Star, SteamOS, SunOS,
# openSUSE_Leap, openSUSE_Tumbleweed, openSUSE, SwagArch, Tails,
# Trisquel, Ubuntu-Budgie, Ubuntu-GNOME, Ubuntu-MATE, Ubuntu-Studio,
# Ubuntu, Venom, Void, Obarun, windows10, Windows7, Xubuntu, Zorin,
# and IRIX have ascii logos
# NOTE: Arch, Ubuntu, Redhat, and Dragonfly have 'old' logo variants.
# Use '{distro name}_old' to use the old logos.
# NOTE: Ubuntu has flavor variants.
# Change this to Lubuntu, Kubuntu, Xubuntu, Ubuntu-GNOME,
# Ubuntu-Studio, Ubuntu-Mate or Ubuntu-Budgie to use the flavors.
# NOTE: Arcolinux, Dragonfly, Fedora, Alpine, Arch, Ubuntu,
# CRUX, Debian, Gentoo, FreeBSD, Mac, NixOS, OpenBSD, android,
# Antrix, CentOS, Cleanjaro, ElementaryOS, GUIX, Hyperbola,
# Manjaro, MXLinux, NetBSD, Parabola, POP_OS, PureOS,
# Slackware, SunOS, LinuxLite, OpenSUSE, Raspbian,
# postmarketOS, and Void have a smaller logo variant.
# Use '{distro name}_small' to use the small variants.
ascii_distro="auto"
# Ascii Colors
#
# Default: 'distro'
# Values: 'distro', 'num' 'num' 'num' 'num' 'num' 'num'
# Flag: --ascii_colors
#
# Example:
# ascii_colors=(distro) - Ascii is colored based on Distro colors.
# ascii_colors=(4 6 1 8 8 6) - Ascii is colored using these colors.
ascii_colors=(distro)
# Bold ascii logo
# Whether or not to bold the ascii logo.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --ascii_bold
ascii_bold="on"
# Image Options
# Image loop
# Setting this to on will make neofetch redraw the image constantly until
# Ctrl+C is pressed. This fixes display issues in some terminal emulators.
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --loop
image_loop="off"
# Thumbnail directory
#
# Default: '~/.cache/thumbnails/neofetch'
# Values: 'dir'
thumbnail_dir="${XDG_CACHE_HOME:-${HOME}/.cache}/thumbnails/neofetch"
# Crop mode
#
# Default: 'normal'
# Values: 'normal', 'fit', 'fill'
# Flag: --crop_mode
#
# See this wiki page to learn about the fit and fill options.
# https://github.com/dylanaraps/neofetch/wiki/What-is-Waifu-Crop%3F
crop_mode="normal"
# Crop offset
# Note: Only affects 'normal' crop mode.
#
# Default: 'center'
# Values: 'northwest', 'north', 'northeast', 'west', 'center'
# 'east', 'southwest', 'south', 'southeast'
# Flag: --crop_offset
crop_offset="center"
# Image size
# The image is half the terminal width by default.
#
# Default: 'auto'
# Values: 'auto', '00px', '00%', 'none'
# Flags: --image_size
# --size
image_size="auto"
# Gap between image and text
#
# Default: '3'
# Values: 'num', '-num'
# Flag: --gap
gap=3
# Image offsets
# Only works with the w3m backend.
#
# Default: '0'
# Values: 'px'
# Flags: --xoffset
# --yoffset
yoffset=0
xoffset=0
# Image background color
# Only works with the w3m backend.
#
# Default: ''
# Values: 'color', 'blue'
# Flag: --bg_color
background_color=
# Misc Options
# Stdout mode
# Turn off all colors and disables image backend (ASCII/Image).
# Useful for piping into another command.
# Default: 'off'
# Values: 'on', 'off'
stdout="off"

View File

@@ -2,8 +2,7 @@ blade-formatter
corepack
editorconfig-checker
github-release-notes
js-debug
neovim
prettier
standardjs
stylelint-lsp
tldr

44
config/task/taskrc Normal file
View File

@@ -0,0 +1,44 @@
# [Created by task 2.6.2 5/11/2023 09:33:14]
# Taskwarrior program configuration file.
# For more documentation, see https://taskwarrior.org or try 'man task', 'man task-color',
# 'man task-sync' or 'man taskrc'
# Here is an example of entries that use the default, override and blank values
# variable=foo -- By specifying a value, this overrides the default
# variable= -- By specifying no value, this means no default
# #variable=foo -- By commenting out the line, or deleting it, this uses the default
# You can also refence environment variables:
# variable=$HOME/task
# variable=$VALUE
# Use the command 'task show' to see all defaults and overrides
# Files
data.location=$XDG_DATA_HOME/task/
# To use the default location of the XDG directories,
# move this configuration file from ~/.taskrc to ~/.config/task/taskrc and uncomment below
#data.location=$XDG_DATA_HOME/task
#hooks.location=~/.config/task/hooks
# Color theme (uncomment one to use)
#include light-16.theme
#include light-256.theme
#include dark-16.theme
#include dark-256.theme
#include dark-red-256.theme
#include dark-green-256.theme
#include dark-blue-256.theme
#include dark-violets-256.theme
#include dark-yellow-green.theme
#include dark-gray-256.theme
#include dark-gray-blue-256.theme
#include solarized-dark-256.theme
#include solarized-light-256.theme
#include no-color.theme
weekstart=monday
news.version=2.6.0

View File

@@ -2,44 +2,113 @@
#
# Contains configuration from the follwing sources:
# - https://tmuxguide.readthedocs.io/en/latest/tmux/tmux.html
# -
# - https://github.com/dreamsofcode-io/tmux/blob/main/tmux.conf
# unbind default prefix and set it to ctrl-a
unbind C-b
set -g prefix C-a
bind C-a send-prefix
## Install plugins, starting with plugin manager
set -g @tpm_plugins ' \
tmux-plugins/tpm \
b0o/tmux-autoreload \
catppuccin/tmux \
ChanderG/tmux-notify \
christoomey/vim-tmux-navigator \
yardnsm/tmux-1password \
jaclu/tmux-menus \
sainnhe/tmux-fzf \
tmux-plugins/tmux-continuum \
tmux-plugins/tmux-resurrect \
tmux-plugins/tmux-sensible \
tmux-plugins/tmux-sessionist \
tmux-plugins/tmux-yank \
'
# make delay shorter
set-option -sa terminal-overrides ",xterm*:Tc"
# Mouse support
set -g mouse on
# Make delay shorter
set -sg escape-time 0
# Set <prefix> to Control + Space
unbind C-b
set -g prefix C-Space
bind C-Space send-prefix
#### key bindings ####
# reload config file
bind r source-file ~/.dotfiles/config/tmux/tmux.conf \; display "tmux.conf reloaded!"
# quickly open a new window
bind N new-window
# synchronize all panes in a window
bind y setw synchronize-panes
# pane movement shortcuts (same as vim)
# Vim style pane selection
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# enable mouse support for switching panes/windows
#set -g mouse-utf8 on
#set -g mouse on
# Start windows and panes at 1, not 0
set -g base-index 1
set -g pane-base-index 1
set-window-option -g pane-base-index 1
set-option -g renumber-windows on
# Use Alt-arrow keys without prefix key to switch panes
bind -n M-Left select-pane -L
bind -n M-Right select-pane -R
bind -n M-Up select-pane -U
bind -n M-Down select-pane -D
# Shift arrow to switch windows
bind -n S-Left previous-window
bind -n S-Right next-window
# Shift Alt vim keys to switch windows
bind -n M-H previous-window
bind -n M-L next-window
# Reload tmux config with <prefix> + r
bind r source-file ~/.config/tmux/tmux.conf \; display "tmux cfg reloaded!"
# Open a new window with <prefix> + N
bind N new-window
# Plugins related configurations
## https://github.com/jaclu/tmux-menus
set -g @menus_trigger 'm'
## https://github.com/jaclu/tmux-1password
set -g @1password-key 'x'
## https://github.com/catppuccin/tmux
set -g @catppuccin_flavour 'mocha' # latte/frappe/macchiato/mocha
set -g @catppuccin_window_tabs_enabled on # or off to disable window_tabs
## https://github.com/tmux-plugins/tmux-continuum
set -g @continuum-restore 'on'
set -g @continuum-boot 'on'
set -g @continuum-boot-options 'iterm'
## https://github.com/tmux-plugins/tmux-resurrect
set -g @resurrect-strategy-nvim 'session'
## https://github.com/b0o/tmux-autoreload
set-option -g @tmux-autoreload-configs '~/.config/tmux/tmux.conf'
## https://github.com/sainnhe/tmux-fzf
TMUX_FZF_LAUNCH_KEY="l"
## https://github.com/ChanderG/tmux-notify
set -g @tnotify-verbose 'on'
# set vi-mode
set-window-option -g mode-keys vi
# keybindings
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
bind-key -T copy-mode-vi y send-keys -X copy-selection-and-cancel
bind '"' split-window -v -c "#{pane_current_path}"
bind % split-window -h -c "#{pane_current_path}"
# synchronize all panes in a window
bind y setw synchronize-panes
#### copy mode : vim ####
# set vi mode for copy mode
setw -g mode-keys vi
# copy mode using 'Esc'
unbind [
bind Escape copy-mode
@@ -51,3 +120,5 @@ bind Escape copy-mode
unbind p
bind p paste-buffer
# Finally run the tmux plugin manager
run '~/.config/tmux/plugins/tpm/tpm'

32
config/yamllint/config Normal file
View File

@@ -0,0 +1,32 @@
---
extends: default
ignore-from-file: [.gitignore, .yamlignore]
rules:
braces:
level: warning
max-spaces-inside: 1
brackets:
level: warning
max-spaces-inside: 1
colons:
level: warning
commas:
level: warning
comments: disable
comments-indentation: disable
document-start: disable
empty-lines:
level: warning
hyphens:
level: warning
indentation:
level: warning
indent-sequences: consistent
line-length:
level: warning
allow-non-breakable-inline-mappings: true
max: 120
truthy: disable

174
config/zsh/completion/_nb Normal file
View File

@@ -0,0 +1,174 @@
#compdef nb
###############################################################################
# __ _
# \ \ _ __ | |__
# \ \ | '_ \| '_ \
# / / | | | | |_) |
# /_/ |_| |_|_.__/
#
# [nb] Command line and local web note-taking, bookmarking, and archiving with
# plain text data storage, encryption, filtering and search, pinning, #tagging,
# Git-backed versioning and syncing, Pandoc-backed conversion, global and local
# notebooks, customizable color themes, [[wiki-style linking]], plugins, and
# more in a single portable, user-friendly script.
#
# https://github.com/xwmx/nb
###############################################################################
_nb_subcommands() {
# _nb_cache_completions()
#
# Usage:
# _nb_cache_completions <path>
#
# Description:
# Cache completions for `nb`. Generating completions can be slow and
# native shell caching doesn't appear to help.
_nb_cache_completions() {
local _cache_path="${1:-}"
[[ -z "${_cache_path:-}" ]] && return 0
# Remove outdated cache files.
local _base_cache_path="${_cache_path%-*}"
local __suffix=
for __suffix in "zsh" "v1"
do
if [[ -e "${_base_cache_path:?}-${__suffix:?}" ]]
then
rm -f "${_base_cache_path:?}-${__suffix:?}"
fi
done
# Rebuild completion cache.
local _commands=
IFS=$'\n' _commands=($(nb subcommands))
local _notebooks=
IFS=$'\n' _notebooks=($(nb notebooks --names --no-color --unarchived))
local _completions=()
IFS=$'\n' _completions=(${_commands[@]})
local _commands_cached=
local _notebooks_cached=
if [[ -e "${_cache_path}" ]]
then
local _counter=0
local __line=
while IFS= read -r __line
do
_counter=$((_counter+1))
if [[ "${_counter}" == 1 ]]
then
_commands_cached="${__line}"
elif [[ "${_counter}" == 2 ]]
then
_notebooks_cached="${__line}"
else
break
fi
done < "${_cache_path}"
fi
if [[ "${_commands_cached}" != "${_commands[*]:-}" ]] ||
[[ "${_notebooks_cached}" != "${_notebooks[*]:-}" ]]
then
# Construct <notebook>:<subcommand> completions.
local __notebook=
for __notebook in "${_notebooks[@]}"
do
local __command=
for __command in "${_commands[@]}"
do
if [[ -n "${__notebook:-}" ]] &&
[[ -n "${__command:-}" ]]
then
_completions+=("${__notebook}:${__command}")
fi
done
done
local _directory_path=
_directory_path="$(dirname "${_cache_path}")"
mkdir -p "${_directory_path}"
if [[ -f "${_cache_path:?}" ]]
then
rm -f "${_cache_path:?}"
fi
touch "${_cache_path:?}"
{
(IFS=$' '; printf "%s\\n" "${_commands[*]}")
(IFS=$' '; printf "%s\\n" "${_notebooks[*]}")
printf "%s\\n" "${_completions[@]}"
} >> "${_cache_path}"
fi
}
local _nb_dir=
_nb_dir="$(nb env | grep 'NB_DIR' | cut -d = -f 2)"
if [[ -z "${_nb_dir:?}" ]] ||
[[ ! -e "${_nb_dir}" ]]
then
return 0
elif [[ -L "${_nb_dir}" ]]
then
if hash "realpath" 2>/dev/null
then
_nb_dir="$(realpath "${_nb_dir}")"
else
_nb_dir="$(readlink "${_nb_dir}")"
fi
fi
if [[ ! -d "${_nb_dir}" ]]
then
return 0
fi
local _cache_path="${_nb_dir:?}/.cache/nb-completion-cache-v2"
local _completions_cached=()
if [[ ! -e "${_cache_path}" ]]
then
_nb_cache_completions "${_cache_path}"
fi
if [[ -e "${_cache_path}" ]]
then
local _counter=0
local __line=
while IFS= read -r __line
do
_counter=$((_counter+1))
if [[ "${_counter}" -gt 2 ]]
then
_completions_cached+=("${__line}")
fi
done < "${_cache_path}"
(_nb_cache_completions "${_cache_path}" &)
fi
if [[ "${?}" -eq 0 ]]
then
compadd -- "${_completions_cached[@]}"
return 0
else
return 1
fi
}
_nb_subcommands "$@"

View File

@@ -0,0 +1,27 @@
# shellcheck shell=zsh
# Source: https://github.com/nvm-sh/nvm#zsh
# place this after nvm initialization!
autoload -U add-zsh-hook
load-nvmrc() {
local nvmrc_path
nvmrc_path="$(nvm_find_nvmrc)"
if [ -n "$nvmrc_path" ]; then
local nvmrc_node_version
nvmrc_node_version=$(nvm version "$(cat "${nvmrc_path}")")
if [ "$nvmrc_node_version" = "N/A" ]; then
nvm install
elif [ "$nvmrc_node_version" != "$(nvm version)" ]; then
nvm use
fi
elif [ -n "$(PWD=$OLDPWD nvm_find_nvmrc)" ] && [ "$(nvm version)" != "$(nvm version default)" ]; then
echo "Reverting to nvm default version"
nvm use default
fi
}
add-zsh-hook chpwd load-nvmrc
load-nvmrc

220
docs/nvim-keybindings.md Normal file
View File

@@ -0,0 +1,220 @@
# nvim keybindings
```md
n ! * <Cmd>lua require("which-key").show("!", {mode = "n", auto = true})<CR>
n ' * <Cmd>lua require("which-key").show("'", {mode = "n", auto = true})<CR>
n " * <Cmd>lua require("which-key").show("\"", {mode = "n", auto = true})<CR>
n [ * <Cmd>lua require("which-key").show("[", {mode = "n", auto = true})<CR>
n [b * <Lua 246: ~/.config/nvim/lua/astronvim/mappings.lua:54> Previous buffer
n [g * <Lua 277: ~/.config/nvim/lua/astronvim/mappings.lua:150> Previous Git hunk
n [t * <Lua 281: ~/.config/nvim/lua/astronvim/mappings.lua:120> Previous tab
n ] * <Cmd>lua require("which-key").show("]", {mode = "n", auto = true})<CR>
n ]b * <Lua 250: ~/.config/nvim/lua/astronvim/mappings.lua:52> Next buffer
n ]g * <Lua 278: ~/.config/nvim/lua/astronvim/mappings.lua:149> Next Git hunk
n ]t * <Lua 282: ~/.config/nvim/lua/astronvim/mappings.lua:119> Next tab
n @ * <Cmd>lua require("which-key").show("@", {mode = "n", auto = true})<CR>
n \ * <Cmd>split<CR> Horizontal Split
n & * :&&<CR> Nvim builtin
n `* <Cmd>lua require("which-key").show("`", {mode = "n", auto = true})<CR>
n < * <Cmd>lua require("which-key").show("<", {mode = "n", auto = true})<CR>
n <b * <Lua 297: ~/.config/nvim/lua/astronvim/mappings.lua:62> Move buffer tab left
n <C-'> * <Cmd>ToggleTerm<CR> Toggle terminal
n <C-Down> * <Lua 263: ~/.config/nvim/lua/astronvim/mappings.lua:213> Resize split down
n <C-H> * <Lua 266: ~/.config/nvim/lua/astronvim/mappings.lua:208> Move to left split
n <C-J> * <Lua 283: ~/.config/nvim/lua/astronvim/mappings.lua:209> Move to below split
n <C-K> * <Lua 327: ~/.config/nvim/lua/astronvim/mappings.lua:210> Move to above split
n <C-L> * <Lua 265: ~/.config/nvim/lua/astronvim/mappings.lua:211> Move to right split
n <C-Left> * <Lua 262: ~/.config/nvim/lua/astronvim/mappings.lua:214> Resize split left
n <C-N> * <Lua 79: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Goto next mark
n <C-P> * <Lua 80: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Goto previous mark
n <C-Q> * <Cmd>q!<CR> Force quit
n <C-Right> * <Lua 261: ~/.config/nvim/lua/astronvim/mappings.lua:215> Resize split right
n <C-S> * <Cmd>w!<CR> Force write
n <C-Up> * <Lua 264: ~/.config/nvim/lua/astronvim/mappings.lua:212> Resize split up
n <C-W> * <Cmd>lua require("which-key").show("\23", {mode = "n", auto = true})<CR>
n <CR> *@<Lua 391: ~/.local/share/nvim/lazy/alpha-nvim/lua/alpha.lua:705>
n <F10> * <Lua 348: ~/.config/nvim/lua/astronvim/mappings.lua:353> Debugger: Step Over
n <F11> * <Lua 333: ~/.config/nvim/lua/astronvim/mappings.lua:354> Debugger: Step Into
n <F17> * <Lua 344: ~/.config/nvim/lua/astronvim/mappings.lua:341> Debugger: Stop
n <F21> * <Lua 342: ~/.config/nvim/lua/astronvim/mappings.lua:343> Debugger: Conditional Breakpoint
n <F23> * <Lua 331: ~/.config/nvim/lua/astronvim/mappings.lua:355> Debugger: Step Out
n <F29> * <Lua 334: ~/.config/nvim/lua/astronvim/mappings.lua:350> Debugger: Restart
n <F5> * <Lua 341: ~/.config/nvim/lua/astronvim/mappings.lua:340> Debugger: Start
n <F6> * <Lua 339: ~/.config/nvim/lua/astronvim/mappings.lua:351> Debugger: Pause
n <F7> * <Cmd>ToggleTerm<CR> Toggle terminal
n <F9> * <Lua 337: ~/.config/nvim/lua/astronvim/mappings.lua:352> Debugger: Toggle Breakpoint
n <M-CR> *@<Lua 394: ~/.local/share/nvim/lazy/alpha-nvim/lua/alpha.lua:708>
n <Plug>PlenaryTestFile *:lua require('plenary.test_harness').test_directory(vim.fn.expand("%:p"))<CR>
n <Space> * <Cmd>lua require("which-key").show(" ", {mode = "n", auto = true})<CR>
n <Space>/ * <Lua 279: ~/.config/nvim/lua/astronvim/mappings.lua:139> Comment line
n <Space><Space> * <Lua 49: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Harpoon
n <Space><Space>a * <Lua 81: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Add file
n <Space><Space>e * <Lua 82: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Toggle quick menu
n <Space><Space>j * <Lua 48: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Goto to TMUX tmux window
n <Space><Space>m * <Lua 83: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Show marks in Telescope
n <Space><Space>t * <Lua 84: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Goto to terminal window
n <Space>a * <Lua 102: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Annotation
n <Space>a<CR> * <Lua 103: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Current
n <Space>ac * <Lua 104: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Class
n <Space>af * <Lua 105: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Function
n <Space>aF * <Lua 96: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> File
n <Space>at * <Lua 86: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Type
n <Space>b\ * <Lua 285: ~/.config/nvim/lua/astronvim/mappings.lua:100> Horizontal split buffer from tabline
n <Space>b| * <Lua 284: ~/.config/nvim/lua/astronvim/mappings.lua:109> Vertical split buffer from tabline
n <Space>bb * <Lua 294: ~/.config/nvim/lua/astronvim/mappings.lua:71> Select buffer from tabline
n <Space>bC * <Lua 295: ~/.config/nvim/lua/astronvim/mappings.lua:69> Close all buffers
n <Space>bc * <Lua 296: ~/.config/nvim/lua/astronvim/mappings.lua:68> Close all buffers except current
n <Space>bd * <Lua 293: ~/.config/nvim/lua/astronvim/mappings.lua:77> Delete buffer from tabline
n <Space>bD * <Lua 320: ~/.config/astronvim/lua/user/mappings.lua:13> Pick to close
n <Space>bl * <Lua 292: ~/.config/nvim/lua/astronvim/mappings.lua:85> Close all buffers to the left
n <Space>bn * <Cmd>tabnew<CR> New tab
n <Space>br * <Lua 291: ~/.config/nvim/lua/astronvim/mappings.lua:87> Close all buffers to the right
n <Space>bse * <Lua 290: ~/.config/nvim/lua/astronvim/mappings.lua:90> Sort by extension (buffers)
n <Space>bsi * <Lua 287: ~/.config/nvim/lua/astronvim/mappings.lua:96> Sort by buffer number (buffers)
n <Space>bsm * <Lua 286: ~/.config/nvim/lua/astronvim/mappings.lua:98> Sort by modification (buffers)
n <Space>bsp * <Lua 288: ~/.config/nvim/lua/astronvim/mappings.lua:94> Sort by full path (buffers)
n <Space>bsr * <Lua 289: ~/.config/nvim/lua/astronvim/mappings.lua:92> Sort by relative path (buffers)
n <Space>C * <Lua 299: ~/.config/nvim/lua/astronvim/mappings.lua:50> Force close buffer
n <Space>c * <Lua 300: ~/.config/nvim/lua/astronvim/mappings.lua:49> Close buffer
n <Space>dB * <Lua 328: ~/.config/nvim/lua/astronvim/mappings.lua:357> Clear Breakpoints
n <Space>db * <Lua 329: ~/.config/nvim/lua/astronvim/mappings.lua:356> Toggle Breakpoint (F9)
n <Space>dC * <Lua 324: ~/.config/nvim/lua/astronvim/mappings.lua:360> Conditional Breakpoint (S-F9)
n <Space>dc * <Lua 326: ~/.config/nvim/lua/astronvim/mappings.lua:358> Start/Continue (F5)
n <Space>dE * <Lua 308: ~/.config/nvim/lua/astronvim/mappings.lua:379> Evaluate Input
n <Space>dh * <Lua 305: ~/.config/nvim/lua/astronvim/mappings.lua:388> Debugger Hover
n <Space>di * <Lua 323: ~/.config/nvim/lua/astronvim/mappings.lua:367> Step Into (F11)
n <Space>dO * <Lua 321: ~/.config/nvim/lua/astronvim/mappings.lua:369> Step Out (S-F11)
n <Space>do * <Lua 322: ~/.config/nvim/lua/astronvim/mappings.lua:368> Step Over (F10)
n <Space>dp * <Lua 316: ~/.config/nvim/lua/astronvim/mappings.lua:372> Pause (F6)
n <Space>dQ * <Lua 318: ~/.config/nvim/lua/astronvim/mappings.lua:371> Terminate Session (S-F5)
n <Space>dq * <Lua 319: ~/.config/nvim/lua/astronvim/mappings.lua:370> Close Session
n <Space>dR * <Lua 312: ~/.config/nvim/lua/astronvim/mappings.lua:374> Toggle REPL
n <Space>dr * <Lua 314: ~/.config/nvim/lua/astronvim/mappings.lua:373> Restart (C-F5)
n <Space>ds * <Lua 310: ~/.config/nvim/lua/astronvim/mappings.lua:375> Run To Cursor
n <Space>du * <Lua 315: ~/.config/nvim/lua/astronvim/mappings.lua:387> Toggle Debugger UI
n <Space>e * <Cmd>Neotree toggle<CR> Toggle Explorer
n <Space>f' * <Lua 255: ~/.config/nvim/lua/astronvim/mappings.lua:241> Find marks
n <Space>f<CR> * <Lua 256: ~/.config/nvim/lua/astronvim/mappings.lua:240> Resume previous search
n <Space>fa * <Lua 254: ~/.config/nvim/lua/astronvim/mappings.lua:243> Find AstroNvim config files
n <Space>fb * <Lua 253: ~/.config/nvim/lua/astronvim/mappings.lua:263> Find buffers
n <Space>fC * <Lua 251: ~/.config/nvim/lua/astronvim/mappings.lua:266> Find commands
n <Space>fc * <Lua 252: ~/.config/nvim/lua/astronvim/mappings.lua:265> Find for word under cursor
n <Space>fF * <Lua 248: ~/.config/nvim/lua/astronvim/mappings.lua:269> Find all files
n <Space>ff * <Lua 249: ~/.config/nvim/lua/astronvim/mappings.lua:267> Find files
n <Space>fh * <Lua 247: ~/.config/nvim/lua/astronvim/mappings.lua:272> Find help
n <Space>fk * <Lua 245: ~/.config/nvim/lua/astronvim/mappings.lua:273> Find keymaps
n <Space>fm * <Lua 309: ~/.config/nvim/lua/astronvim/mappings.lua:274> Find man
n <Space>fn * <Lua 242: ~/.config/nvim/lua/astronvim/mappings.lua:277> Find notifications
n <Space>fo * <Lua 240: ~/.config/nvim/lua/astronvim/mappings.lua:279> Find history
n <Space>fr * <Lua 239: ~/.config/nvim/lua/astronvim/mappings.lua:280> Find registers
n <Space>ft * <Lua 238: ~/.config/nvim/lua/astronvim/mappings.lua:282> Find themes
n <Space>fW * <Lua 236: ~/.config/nvim/lua/astronvim/mappings.lua:285> Find words in all files
n <Space>fw * <Lua 237: ~/.config/nvim/lua/astronvim/mappings.lua:283> Find words
n <Space>gb * <Lua 259: ~/.config/nvim/lua/astronvim/mappings.lua:237> Git branches
n <Space>gc * <Lua 258: ~/.config/nvim/lua/astronvim/mappings.lua:238> Git commits
n <Space>gd * <Lua 268: ~/.config/nvim/lua/astronvim/mappings.lua:159> View Git diff
n <Space>gg * <Lua 304: ~/.config/nvim/lua/astronvim/mappings.lua:312> ToggleTerm lazygit
n <Space>gh * <Lua 273: ~/.config/nvim/lua/astronvim/mappings.lua:154> Reset Git hunk
n <Space>gL * <Lua 275: ~/.config/nvim/lua/astronvim/mappings.lua:152> View full Git blame
n <Space>gl * <Lua 276: ~/.config/nvim/lua/astronvim/mappings.lua:151> View Git blame
n <Space>gp * <Lua 274: ~/.config/nvim/lua/astronvim/mappings.lua:153> Preview Git hunk
n <Space>gr * <Lua 272: ~/.config/nvim/lua/astronvim/mappings.lua:155> Reset Git buffer
n <Space>gS * <Lua 270: ~/.config/nvim/lua/astronvim/mappings.lua:157> Stage Git buffer
n <Space>gs * <Lua 271: ~/.config/nvim/lua/astronvim/mappings.lua:156> Stage Git hunk
n <Space>gt * <Lua 257: ~/.config/nvim/lua/astronvim/mappings.lua:239> Git status
n <Space>gu * <Lua 269: ~/.config/nvim/lua/astronvim/mappings.lua:158> Unstage Git hunk
n <Space>h * <Lua 280: ~/.config/nvim/lua/astronvim/mappings.lua:125> Home Screen
n <Space>lD * <Lua 313: ~/.config/nvim/lua/astronvim/mappings.lua:293> Search diagnostics
n <Space>ls * <Lua 235: ~/.config/nvim/lua/astronvim/mappings.lua:295> Search symbols
n <Space>lS * <Lua 260: ~/.config/nvim/lua/astronvim/mappings.lua:230> Symbols outline
n <Space>n * <Cmd>enew<CR> New File
n <Space>o * <Lua 267: ~/.config/nvim/lua/astronvim/mappings.lua:166> Toggle Explorer Focus
n <Space>p * <Cmd>lua require("which-key").show(" p", {mode = "n", auto = true})<CR>
n <Space>pA * <Cmd>AstroUpdate<CR> AstroNvim Update
n <Space>pa * <Cmd>AstroUpdatePackages<CR> Update Plugins and Mason
n <Space>pi * <Lua 307: ~/.config/nvim/lua/astronvim/mappings.lua:36> Plugins Install
n <Space>pl * <Cmd>AstroChangelog<CR> AstroNvim Changelog
n <Space>pm * <Cmd>Mason<CR> Mason Installer
n <Space>pM * <Cmd>MasonUpdateAll<CR> Mason Update
n <Space>pS * <Lua 233: ~/.config/nvim/lua/astronvim/mappings.lua:38> Plugins Sync
n <Space>ps * <Lua 234: ~/.config/nvim/lua/astronvim/mappings.lua:37> Plugins Status
n <Space>pU * <Lua 229: ~/.config/nvim/lua/astronvim/mappings.lua:40> Plugins Update
n <Space>pu * <Lua 231: ~/.config/nvim/lua/astronvim/mappings.lua:39> Plugins Check Updates
n <Space>pv * <Cmd>AstroVersion<CR> AstroNvim Version
n <Space>q * <Cmd>confirm q<CR> Quit
n <Space>s * <Lua 45: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Search / Replace
n <Space>S. * <Cmd>SessionManager! load_current_dir_session<CR> Load current directory session
n <Space>Sd * <Cmd>SessionManager! delete_session<CR> Delete session
n <Space>Sf * <Cmd>SessionManager! load_session<CR> Search sessions
n <Space>sf * <Lua 36: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Spectre (current file)
n <Space>Sl * <Cmd>SessionManager! load_last_session<CR> Load last session
n <Space>Ss * <Cmd>SessionManager! save_current_session<CR> Save this session
n <Space>ss * <Lua 35: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Spectre
n <Space>tf * <Cmd>ToggleTerm direction=float<CR> ToggleTerm float
n <Space>th * <Cmd>ToggleTerm size=10 direction=horizontal<CR> ToggleTerm horizontal split
n <Space>tl * <Lua 232: ~/.config/nvim/lua/astronvim/mappings.lua:313> ToggleTerm lazygit
n <Space>tn * <Lua 230: ~/.config/nvim/lua/astronvim/mappings.lua:316> ToggleTerm node
n <Space>tp * <Lua 311: ~/.config/nvim/lua/astronvim/mappings.lua:325> ToggleTerm python
n <Space>tt * <Lua 306: ~/.config/nvim/lua/astronvim/mappings.lua:322> ToggleTerm btm
n <Space>tu * <Lua 355: ~/.config/nvim/lua/astronvim/mappings.lua:319> ToggleTerm gdu
n <Space>tv * <Cmd>ToggleTerm size=80 direction=vertical<CR> ToggleTerm vertical split
n <Space>ua * <Lua 350: ~/.config/nvim/lua/astronvim/utils/ui.lua:27> Toggle autopairs
n <Space>ub * <Lua 303: ~/.config/nvim/lua/astronvim/utils/ui.lua:58> Toggle background
n <Space>uC * <Cmd>ColorizerToggle<CR> Toggle color highlight
n <Space>uc * <Lua 354: ~/.config/nvim/lua/astronvim/utils/ui.lua:64> Toggle autocompletion
n <Space>ud * <Lua 353: ~/.config/nvim/lua/astronvim/utils/ui.lua:43> Toggle diagnostics
n <Space>ug * <Lua 301: ~/.config/nvim/lua/astronvim/utils/ui.lua:134> Toggle signcolumn
n <Space>uh * <Lua 352: ~/.config/nvim/lua/astronvim/utils/ui.lua:215> Toggle foldcolumn
n <Space>ui * <Lua 325: ~/.config/nvim/lua/astronvim/utils/ui.lua:146> Change indent setting
n <Space>ul * <Lua 330: ~/.config/nvim/lua/astronvim/utils/ui.lua:117> Toggle statusline
n <Space>uL * <Lua 345: ~/.config/nvim/lua/astronvim/utils/ui.lua:98> Toggle CodeLens
n <Space>uN * <Lua 340: ~/.config/nvim/lua/astronvim/utils/ui.lua:21> Toggle UI notifications
n <Space>un * <Lua 343: ~/.config/nvim/lua/astronvim/utils/ui.lua:161> Change line numbering
n <Space>up * <Lua 338: ~/.config/nvim/lua/astronvim/utils/ui.lua:183> Toggle paste mode
n <Space>uS * <Lua 332: ~/.config/nvim/lua/astronvim/utils/ui.lua:111> Toggle conceal
n <Space>us * <Lua 335: ~/.config/nvim/lua/astronvim/utils/ui.lua:177> Toggle spellcheck
n <Space>uT * <Cmd>TransparentToggle<CR> Toggle transparency
n <Space>ut * <Lua 302: ~/.config/nvim/lua/astronvim/utils/ui.lua:105> Toggle tabline
n <Space>uu * <Lua 351: ~/.config/nvim/lua/astronvim/utils/ui.lua:208> Toggle URL highlight
n <Space>uw * <Lua 349: ~/.config/nvim/lua/astronvim/utils/ui.lua:189> Toggle wrap
n <Space>uy * <Lua 346: ~/.config/nvim/lua/astronvim/utils/ui.lua:195> Toggle syntax highlight
n <Space>w * <Cmd>w<CR> Save
n <Space>x * <Lua 126: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Trouble
n <Space>xl * <Lua 171: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Location List (Trouble)
n <Space>xq * <Lua 172: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Quickfix List (Trouble)
n <Space>xX * <Lua 132: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Workspace Diagnostics (Trouble)
n <Space>xx * <Lua 170: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Document Diagnostics (Trouble)
n > * <Cmd>lua require("which-key").show(">", {mode = "n", auto = true})<CR>
n >b * <Lua 298: ~/.config/nvim/lua/astronvim/mappings.lua:58> Move buffer tab right
n | * <Cmd>vsplit<CR> Vertical Split
n c * <Cmd>lua require("which-key").show("c", {mode = "n", auto = true})<CR>
n d * <Cmd>lua require("which-key").show("d", {mode = "n", auto = true})<CR>
n g * <Cmd>lua require("which-key").show("g", {mode = "n", auto = true})<CR>
n gb * <Lua 123: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Comment toggle blockwise
n gc * <Lua 107: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Comment toggle linewise
n gx * <Lua 241: ~/.config/nvim/lua/astronvim/utils/init.lua:134> Open the file under cursor with system app
n j * v:count == 0 ? 'gj' : 'j' Move cursor down
n k * v:count == 0 ? 'gk' : 'k' Move cursor up
n v * <Cmd>lua require("which-key").show("v", {mode = "n", auto = true})<CR>
n y * <Cmd>lua require("which-key").show("y", {mode = "n", auto = true})<CR>
n Y * y$ Nvim builtin
n z * <Cmd>lua require("which-key").show("z", {mode = "n", auto = true})<CR>
n zM * <Lua 244: ~/.config/nvim/lua/astronvim/mappings.lua:395> Close all folds
n zm * <Lua 317: ~/.config/nvim/lua/astronvim/mappings.lua:397> Fold more
n zp * <Lua 347: ~/.config/nvim/lua/astronvim/mappings.lua:398> Peek fold
n zr * <Lua 243: ~/.config/nvim/lua/astronvim/mappings.lua:396> Fold less
n zR * <Lua 336: ~/.config/nvim/lua/astronvim/mappings.lua:394> Open all folds
v <Tab> * >gv indent line
v <S-Tab> * <gv unindent line
v <Space>/ * <Esc><Cmd>lua require('Comment.api').toggle.linewise(vim.fn.visualmode())<CR> Toggle comment line
v <Space>dE * <Lua 228: ~/.config/nvim/lua/astronvim/mappings.lua:386> Evaluate Input
v gb * <Lua 124: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Comment toggle blockwise
v gc * <Lua 114: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Comment toggle linewise
x " * <Cmd>lua require("which-key").show("\"", {mode = "v", auto = true})<CR>
x ** y/\V<C-R>"<CR> Nvim builtin
x # * y?\V<C-R>"<CR> Nvim builtin
x <Space> * <Cmd>lua require("which-key").show(" ", {mode = "v", auto = true})<CR>
x <Space>s * <Lua 46: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Search / Replace
x <Space>sw * <Lua 47: ~/.local/share/nvim/lazy/lazy.nvim/lua/lazy/core/handler/keys.lua:67> Spectre (current word)
x g * <Cmd>lua require("which-key").show("g", {mode = "v", auto = true})<CR>
```

316
docs/tmux-keybindings.md Normal file
View File

@@ -0,0 +1,316 @@
# tmux keybindings
Leader: `<ctrl><space>`
```
bind-key -T copy-mode C-Space send-keys -X begin-selection
bind-key -T copy-mode C-a send-keys -X start-of-line
bind-key -T copy-mode C-b send-keys -X cursor-left
bind-key -T copy-mode C-c send-keys -X cancel
bind-key -T copy-mode C-e send-keys -X end-of-line
bind-key -T copy-mode C-f send-keys -X cursor-right
bind-key -T copy-mode C-g send-keys -X clear-selection
bind-key -T copy-mode C-k send-keys -X copy-pipe-end-of-line-and-cancel
bind-key -T copy-mode C-n send-keys -X cursor-down
bind-key -T copy-mode C-p send-keys -X cursor-up
bind-key -T copy-mode C-r command-prompt -i -I "#{pane_search_string}" -T search -p "(search up)" { send-keys -X search-backward-incremental "%%" }
bind-key -T copy-mode C-s command-prompt -i -I "#{pane_search_string}" -T search -p "(search down)" { send-keys -X search-forward-incremental "%%" }
bind-key -T copy-mode C-v send-keys -X page-down
bind-key -T copy-mode C-w send-keys -X copy-pipe-and-cancel
bind-key -T copy-mode Escape send-keys -X cancel
bind-key -T copy-mode Space send-keys -X page-down
bind-key -T copy-mode ! send-keys -X copy-pipe-and-cancel "tr -d '
' | pbcopy"
bind-key -T copy-mode , send-keys -X jump-reverse
bind-key -T copy-mode \; send-keys -X jump-again
bind-key -T copy-mode F command-prompt -1 -p "(jump backward)" { send-keys -X jump-backward "%%" }
bind-key -T copy-mode N send-keys -X search-reverse
bind-key -T copy-mode P send-keys -X toggle-position
bind-key -T copy-mode R send-keys -X rectangle-toggle
bind-key -T copy-mode T command-prompt -1 -p "(jump to backward)" { send-keys -X jump-to-backward "%%" }
bind-key -T copy-mode X send-keys -X set-mark
bind-key -T copy-mode Y send-keys -X copy-pipe-and-cancel "tmux paste-buffer"
bind-key -T copy-mode f command-prompt -1 -p "(jump forward)" { send-keys -X jump-forward "%%" }
bind-key -T copy-mode g command-prompt -p "(goto line)" { send-keys -X goto-line "%%" }
bind-key -T copy-mode n send-keys -X search-again
bind-key -T copy-mode q send-keys -X cancel
bind-key -T copy-mode r send-keys -X refresh-from-pane
bind-key -T copy-mode t command-prompt -1 -p "(jump to forward)" { send-keys -X jump-to-forward "%%" }
bind-key -T copy-mode y send-keys -X copy-pipe-and-cancel pbcopy
bind-key -T copy-mode MouseDown1Pane select-pane
bind-key -T copy-mode MouseDrag1Pane select-pane \; send-keys -X begin-selection
bind-key -T copy-mode MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel pbcopy
bind-key -T copy-mode WheelUpPane select-pane \; send-keys -X -N 5 scroll-up
bind-key -T copy-mode WheelDownPane select-pane \; send-keys -X -N 5 scroll-down
bind-key -T copy-mode DoubleClick1Pane select-pane \; send-keys -X select-word \; run-shell -d 0.3 \; send-keys -X copy-pipe-and-cancel
bind-key -T copy-mode TripleClick1Pane select-pane \; send-keys -X select-line \; run-shell -d 0.3 \; send-keys -X copy-pipe-and-cancel
bind-key -T copy-mode Home send-keys -X start-of-line
bind-key -T copy-mode End send-keys -X end-of-line
bind-key -T copy-mode NPage send-keys -X page-down
bind-key -T copy-mode PPage send-keys -X page-up
bind-key -T copy-mode Up send-keys -X cursor-up
bind-key -T copy-mode Down send-keys -X cursor-down
bind-key -T copy-mode Left send-keys -X cursor-left
bind-key -T copy-mode Right send-keys -X cursor-right
bind-key -T copy-mode M-C-b send-keys -X previous-matching-bracket
bind-key -T copy-mode M-C-f send-keys -X next-matching-bracket
bind-key -T copy-mode M-1 command-prompt -N -I 1 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode M-2 command-prompt -N -I 2 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode M-3 command-prompt -N -I 3 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode M-4 command-prompt -N -I 4 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode M-5 command-prompt -N -I 5 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode M-6 command-prompt -N -I 6 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode M-7 command-prompt -N -I 7 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode M-8 command-prompt -N -I 8 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode M-9 command-prompt -N -I 9 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode M-< send-keys -X history-top
bind-key -T copy-mode M-> send-keys -X history-bottom
bind-key -T copy-mode M-R send-keys -X top-line
bind-key -T copy-mode M-b send-keys -X previous-word
bind-key -T copy-mode M-f send-keys -X next-word-end
bind-key -T copy-mode M-m send-keys -X back-to-indentation
bind-key -T copy-mode M-r send-keys -X middle-line
bind-key -T copy-mode M-v send-keys -X page-up
bind-key -T copy-mode M-w send-keys -X copy-pipe-and-cancel
bind-key -T copy-mode M-x send-keys -X jump-to-mark
bind-key -T copy-mode M-y send-keys -X copy-pipe-and-cancel "pbcopy; tmux paste-buffer"
bind-key -T copy-mode "M-{" send-keys -X previous-paragraph
bind-key -T copy-mode "M-}" send-keys -X next-paragraph
bind-key -T copy-mode M-Up send-keys -X halfpage-up
bind-key -T copy-mode M-Down send-keys -X halfpage-down
bind-key -T copy-mode C-Up send-keys -X scroll-up
bind-key -T copy-mode C-Down send-keys -X scroll-down
bind-key -T copy-mode-vi C-b send-keys -X page-up
bind-key -T copy-mode-vi C-c send-keys -X cancel
bind-key -T copy-mode-vi C-d send-keys -X halfpage-down
bind-key -T copy-mode-vi C-e send-keys -X scroll-down
bind-key -T copy-mode-vi C-f send-keys -X page-down
bind-key -T copy-mode-vi C-h select-pane -L
bind-key -T copy-mode-vi C-j select-pane -D
bind-key -T copy-mode-vi C-k select-pane -U
bind-key -T copy-mode-vi C-l select-pane -R
bind-key -T copy-mode-vi Enter send-keys -X copy-pipe-and-cancel
bind-key -T copy-mode-vi C-u send-keys -X halfpage-up
bind-key -T copy-mode-vi C-v send-keys -X rectangle-toggle
bind-key -T copy-mode-vi C-y send-keys -X scroll-up
bind-key -T copy-mode-vi Escape send-keys -X clear-selection
bind-key -T copy-mode-vi C-\ select-pane -l
bind-key -T copy-mode-vi Space send-keys -X begin-selection
bind-key -T copy-mode-vi ! send-keys -X copy-pipe-and-cancel "tr -d '
' | pbcopy"
bind-key -T copy-mode-vi \# send-keys -FX search-backward "#{copy_cursor_word}"
bind-key -T copy-mode-vi \$ send-keys -X end-of-line
bind-key -T copy-mode-vi \% send-keys -X next-matching-bracket
bind-key -T copy-mode-vi * send-keys -FX search-forward "#{copy_cursor_word}"
bind-key -T copy-mode-vi , send-keys -X jump-reverse
bind-key -T copy-mode-vi / command-prompt -T search -p "(search down)" { send-keys -X search-forward "%%" }
bind-key -T copy-mode-vi 0 send-keys -X start-of-line
bind-key -T copy-mode-vi 1 command-prompt -N -I 1 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode-vi 2 command-prompt -N -I 2 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode-vi 3 command-prompt -N -I 3 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode-vi 4 command-prompt -N -I 4 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode-vi 5 command-prompt -N -I 5 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode-vi 6 command-prompt -N -I 6 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode-vi 7 command-prompt -N -I 7 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode-vi 8 command-prompt -N -I 8 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode-vi 9 command-prompt -N -I 9 -p (repeat) { send-keys -N "%%" }
bind-key -T copy-mode-vi : command-prompt -p "(goto line)" { send-keys -X goto-line "%%" }
bind-key -T copy-mode-vi \; send-keys -X jump-again
bind-key -T copy-mode-vi ? command-prompt -T search -p "(search up)" { send-keys -X search-backward "%%" }
bind-key -T copy-mode-vi A send-keys -X append-selection-and-cancel
bind-key -T copy-mode-vi B send-keys -X previous-space
bind-key -T copy-mode-vi D send-keys -X copy-pipe-end-of-line-and-cancel
bind-key -T copy-mode-vi E send-keys -X next-space-end
bind-key -T copy-mode-vi F command-prompt -1 -p "(jump backward)" { send-keys -X jump-backward "%%" }
bind-key -T copy-mode-vi G send-keys -X history-bottom
bind-key -T copy-mode-vi H send-keys -X top-line
bind-key -T copy-mode-vi J send-keys -X scroll-down
bind-key -T copy-mode-vi K send-keys -X scroll-up
bind-key -T copy-mode-vi L send-keys -X bottom-line
bind-key -T copy-mode-vi M send-keys -X middle-line
bind-key -T copy-mode-vi N send-keys -X search-reverse
bind-key -T copy-mode-vi P send-keys -X toggle-position
bind-key -T copy-mode-vi T command-prompt -1 -p "(jump to backward)" { send-keys -X jump-to-backward "%%" }
bind-key -T copy-mode-vi V send-keys -X select-line
bind-key -T copy-mode-vi W send-keys -X next-space
bind-key -T copy-mode-vi X send-keys -X set-mark
bind-key -T copy-mode-vi Y send-keys -X copy-pipe-and-cancel "tmux paste-buffer"
bind-key -T copy-mode-vi ^ send-keys -X back-to-indentation
bind-key -T copy-mode-vi b send-keys -X previous-word
bind-key -T copy-mode-vi e send-keys -X next-word-end
bind-key -T copy-mode-vi f command-prompt -1 -p "(jump forward)" { send-keys -X jump-forward "%%" }
bind-key -T copy-mode-vi g send-keys -X history-top
bind-key -T copy-mode-vi h send-keys -X cursor-left
bind-key -T copy-mode-vi j send-keys -X cursor-down
bind-key -T copy-mode-vi k send-keys -X cursor-up
bind-key -T copy-mode-vi l send-keys -X cursor-right
bind-key -T copy-mode-vi n send-keys -X search-again
bind-key -T copy-mode-vi o send-keys -X other-end
bind-key -T copy-mode-vi q send-keys -X cancel
bind-key -T copy-mode-vi r send-keys -X refresh-from-pane
bind-key -T copy-mode-vi t command-prompt -1 -p "(jump to forward)" { send-keys -X jump-to-forward "%%" }
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi w send-keys -X next-word
bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel pbcopy
bind-key -T copy-mode-vi \{ send-keys -X previous-paragraph
bind-key -T copy-mode-vi \} send-keys -X next-paragraph
bind-key -T copy-mode-vi MouseDown1Pane select-pane
bind-key -T copy-mode-vi MouseDrag1Pane select-pane \; send-keys -X begin-selection
bind-key -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel pbcopy
bind-key -T copy-mode-vi WheelUpPane select-pane \; send-keys -X -N 5 scroll-up
bind-key -T copy-mode-vi WheelDownPane select-pane \; send-keys -X -N 5 scroll-down
bind-key -T copy-mode-vi DoubleClick1Pane select-pane \; send-keys -X select-word \; run-shell -d 0.3 \; send-keys -X copy-pipe-and-cancel
bind-key -T copy-mode-vi TripleClick1Pane select-pane \; send-keys -X select-line \; run-shell -d 0.3 \; send-keys -X copy-pipe-and-cancel
bind-key -T copy-mode-vi BSpace send-keys -X cursor-left
bind-key -T copy-mode-vi NPage send-keys -X page-down
bind-key -T copy-mode-vi PPage send-keys -X page-up
bind-key -T copy-mode-vi Up send-keys -X cursor-up
bind-key -T copy-mode-vi Down send-keys -X cursor-down
bind-key -T copy-mode-vi Left send-keys -X cursor-left
bind-key -T copy-mode-vi Right send-keys -X cursor-right
bind-key -T copy-mode-vi M-x send-keys -X jump-to-mark
bind-key -T copy-mode-vi M-y send-keys -X copy-pipe-and-cancel "pbcopy; tmux paste-buffer"
bind-key -T copy-mode-vi C-Up send-keys -X scroll-up
bind-key -T copy-mode-vi C-Down send-keys -X scroll-down
bind-key -T join-pane \" run-shell "'/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/join_pane.sh' 'join-pane' '-b' '-v'"
bind-key -T join-pane \% run-shell "'/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/join_pane.sh' 'join-pane' '-b' '-h'"
bind-key -T join-pane - run-shell "'/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/join_pane.sh' 'join-pane' '-b' '-v'"
bind-key -T join-pane @ run-shell "'/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/join_pane.sh' 'join-pane' '-b' '-b'"
bind-key -T join-pane f run-shell "'/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/join_pane.sh' 'join-pane' '-b' '-b'"
bind-key -T join-pane h run-shell "'/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/join_pane.sh' 'join-pane' '-b' '-h'"
bind-key -T join-pane v run-shell "'/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/join_pane.sh' 'join-pane' '-b' '-v'"
bind-key -T join-pane | run-shell "'/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/join_pane.sh' 'join-pane' '-b' '-h'"
bind-key -T prefix C-Space run-shell "/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/promote_window.sh '#{session_name}' '#{window_id}' '#{window_name}' '#{pane_current_path}'"
bind-key -T prefix C-n next-window
bind-key -T prefix C-o rotate-window
bind-key -T prefix C-p previous-window
bind-key -T prefix C-r run-shell /Users/ivuorinen/.config/tmux/plugins/tmux-resurrect/scripts/restore.sh
bind-key -T prefix C-s run-shell /Users/ivuorinen/.config/tmux/plugins/tmux-resurrect/scripts/save.sh
bind-key -T prefix C-z suspend-client
bind-key -T prefix Escape copy-mode
bind-key -T prefix Space next-layout
bind-key -T prefix ! break-pane
bind-key -T prefix \" split-window -v -c "#{pane_current_path}"
bind-key -T prefix \# list-buffers
bind-key -T prefix \$ command-prompt -I "#S" { rename-session "%%" }
bind-key -T prefix \% split-window -h -c "#{pane_current_path}"
bind-key -T prefix & confirm-before -p "kill-window #W? (y/n)" kill-window
bind-key -T prefix \' command-prompt -T window-target -p index { select-window -t ":%%" }
bind-key -T prefix ( switch-client -p
bind-key -T prefix ) switch-client -n
bind-key -T prefix , command-prompt -I "#W" { rename-window "%%" }
bind-key -T prefix - delete-buffer
bind-key -T prefix . command-prompt -T target { move-window -t "%%" }
bind-key -T prefix / command-prompt -k -p key { list-keys -1N "%%" }
bind-key -T prefix 0 select-window -t :=0
bind-key -T prefix 1 select-window -t :=1
bind-key -T prefix 2 select-window -t :=2
bind-key -T prefix 3 select-window -t :=3
bind-key -T prefix 4 select-window -t :=4
bind-key -T prefix 5 select-window -t :=5
bind-key -T prefix 6 select-window -t :=6
bind-key -T prefix 7 select-window -t :=7
bind-key -T prefix 8 select-window -t :=8
bind-key -T prefix 9 select-window -t :=9
bind-key -T prefix : command-prompt
bind-key -T prefix \; last-pane
bind-key -T prefix < display-menu -T "#[align=centre]#{window_index}:#{window_name}" -x W -y W "#{?#{>:#{session_windows},1},,-}Swap Left" l { swap-window -t :-1 } "#{?#{>:#{session_windows},1},,-}Swap Right" r { swap-window -t :+1 } "#{?pane_marked_set,,-}Swap Marked" s { swap-window } '' Kill X { kill-window } Respawn R { respawn-window -k } "#{?pane_marked,Unmark,Mark}" m { select-pane -m } Rename n { command-prompt -F -I "#W" { rename-window -t "#{window_id}" "%%" } } '' "New After" w { new-window -a } "New At End" W { new-window }
bind-key -T prefix = choose-buffer -Z
bind-key -T prefix > display-menu -T "#[align=centre]#{pane_index} (#{pane_id})" -x P -y P "#{?#{m/r:(copy|view)-mode,#{pane_mode}},Go To Top,}" < { send-keys -X history-top } "#{?#{m/r:(copy|view)-mode,#{pane_mode}},Go To Bottom,}" > { send-keys -X history-bottom } '' "#{?mouse_word,Search For #[underscore]#{=/9/...:mouse_word},}" C-r { if-shell -F "#{?#{m/r:(copy|view)-mode,#{pane_mode}},0,1}" "copy-mode -t=" ; send-keys -X -t = search-backward "#{q:mouse_word}" } "#{?mouse_word,Type #[underscore]#{=/9/...:mouse_word},}" C-y { copy-mode -q ; send-keys -l "#{q:mouse_word}" } "#{?mouse_word,Copy #[underscore]#{=/9/...:mouse_word},}" c { copy-mode -q ; set-buffer "#{q:mouse_word}" } "#{?mouse_line,Copy Line,}" l { copy-mode -q ; set-buffer "#{q:mouse_line}" } '' "Horizontal Split" h { split-window -h } "Vertical Split" v { split-window -v } '' "#{?#{>:#{window_panes},1},,-}Swap Up" u { swap-pane -U } "#{?#{>:#{window_panes},1},,-}Swap Down" d { swap-pane -D } "#{?pane_marked_set,,-}Swap Marked" s { swap-pane } '' Kill X { kill-pane } Respawn R { respawn-pane -k } "#{?pane_marked,Unmark,Mark}" m { select-pane -m } "#{?#{>:#{window_panes},1},,-}#{?window_zoomed_flag,Unzoom,Zoom}" z { resize-pane -Z }
bind-key -T prefix ? list-keys -N
bind-key -T prefix @ run-shell "/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/promote_pane.sh '#{session_name}' '#{pane_id}' '#{pane_current_path}'"
bind-key -T prefix C run-shell /Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/new_session_prompt.sh
bind-key -T prefix D choose-client -Z
bind-key -T prefix E select-layout -E
bind-key -T prefix I run-shell /Users/ivuorinen/.config/tmux/plugins/tpm/bindings/install_plugins
bind-key -T prefix L switch-client -l
bind-key -T prefix M select-pane -M
bind-key -T prefix N new-window
bind-key -T prefix R run-shell " tmux source-file /Users/ivuorinen/.config/tmux/tmux.conf > /dev/null; tmux display-message 'Sourced /Users/ivuorinen/.config/tmux/tmux.conf!'"
bind-key -T prefix S switch-client -l
bind-key -T prefix U run-shell /Users/ivuorinen/.config/tmux/plugins/tpm/bindings/update_plugins
bind-key -T prefix X run-shell "/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/kill_session_prompt.sh '#{session_name}' '#{session_id}'"
bind-key -T prefix Y run-shell -b /Users/ivuorinen/.config/tmux/plugins/tmux-yank/scripts/copy_pane_pwd.sh
bind-key -T prefix ] paste-buffer -p
bind-key -T prefix c new-window
bind-key -T prefix d detach-client
bind-key -T prefix f command-prompt { find-window -Z "%%" }
bind-key -T prefix g run-shell /Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/goto_session.sh
bind-key -T prefix h select-pane -L
bind-key -T prefix i display-message
bind-key -T prefix j select-pane -D
bind-key -T prefix k select-pane -U
bind-key -T prefix l run-shell -b /Users/ivuorinen/.config/tmux/plugins/tmux-fzf/main.sh
bind-key -T prefix m run-shell /Users/ivuorinen/.config/tmux/plugins/tmux-menus/items/main.sh
bind-key -T prefix n next-window
bind-key -T prefix o select-pane -t :.+
bind-key -T prefix p paste-buffer
bind-key -T prefix q display-panes
bind-key -T prefix r source-file /Users/ivuorinen/.dotfiles/config/tmux/tmux.conf \; display-message "tmux cfg reloaded!"
bind-key -T prefix s choose-tree -Zs
bind-key -T prefix t run-shell "/Users/ivuorinen/.config/tmux/plugins/tmux-sessionist/scripts/join_pane.sh 'join-pane' '-b'"
bind-key -T prefix w choose-tree -Zw
bind-key -T prefix x confirm-before -p "kill-pane #P? (y/n)" kill-pane
bind-key -T prefix y run-shell -b /Users/ivuorinen/.config/tmux/plugins/tmux-yank/scripts/copy_line.sh
bind-key -T prefix z resize-pane -Z
bind-key -T prefix \{ swap-pane -U
bind-key -T prefix \} swap-pane -D
bind-key -T prefix \~ show-messages
bind-key -r -T prefix DC refresh-client -c
bind-key -T prefix PPage copy-mode -u
bind-key -r -T prefix Up select-pane -U
bind-key -r -T prefix Down select-pane -D
bind-key -r -T prefix Left select-pane -L
bind-key -r -T prefix Right select-pane -R
bind-key -T prefix M-1 select-layout even-horizontal
bind-key -T prefix M-2 select-layout even-vertical
bind-key -T prefix M-3 select-layout main-horizontal
bind-key -T prefix M-4 select-layout main-vertical
bind-key -T prefix M-5 select-layout tiled
bind-key -T prefix M-n next-window -a
bind-key -T prefix M-o rotate-window -D
bind-key -T prefix M-p previous-window -a
bind-key -T prefix M-u run-shell /Users/ivuorinen/.config/tmux/plugins/tpm/bindings/clean_plugins
bind-key -r -T prefix M-Up resize-pane -U 5
bind-key -r -T prefix M-Down resize-pane -D 5
bind-key -r -T prefix M-Left resize-pane -L 5
bind-key -r -T prefix M-Right resize-pane -R 5
bind-key -r -T prefix C-Up resize-pane -U
bind-key -r -T prefix C-Down resize-pane -D
bind-key -r -T prefix C-Left resize-pane -L
bind-key -r -T prefix C-Right resize-pane -R
bind-key -r -T prefix S-Up refresh-client -U 10
bind-key -r -T prefix S-Down refresh-client -D 10
bind-key -r -T prefix S-Left refresh-client -L 10
bind-key -r -T prefix S-Right refresh-client -R 10
bind-key -T root C-h if-shell "ps -o state= -o comm= -t '#{pane_tty}' | grep -iqE '^[^TXZ ]+ +(\S+\/)?g?(view|l?n?vim?x?)(diff)?$'" "send-keys C-h" "select-pane -L"
bind-key -T root C-j if-shell "ps -o state= -o comm= -t '#{pane_tty}' | grep -iqE '^[^TXZ ]+ +(\S+\/)?g?(view|l?n?vim?x?)(diff)?$'" "send-keys C-j" "select-pane -D"
bind-key -T root C-k if-shell "ps -o state= -o comm= -t '#{pane_tty}' | grep -iqE '^[^TXZ ]+ +(\S+\/)?g?(view|l?n?vim?x?)(diff)?$'" "send-keys C-k" "select-pane -U"
bind-key -T root C-l if-shell "ps -o state= -o comm= -t '#{pane_tty}' | grep -iqE '^[^TXZ ]+ +(\S+\/)?g?(view|l?n?vim?x?)(diff)?$'" "send-keys C-l" "select-pane -R"
bind-key -T root C-\ if-shell "ps -o state= -o comm= -t '#{pane_tty}' | grep -iqE '^[^TXZ ]+ +(S+/)?g?(view|l?n?vim?x?)(diff)?$'" "send-keys C-\\" "select-pane -l"
bind-key -T root MouseDown1Pane select-pane -t = \; send-keys -M
bind-key -T root MouseDown1Status select-window -t =
bind-key -T root MouseDown2Pane select-pane -t = \; if-shell -F "#{||:#{pane_in_mode},#{mouse_any_flag}}" { send-keys -M } { paste-buffer -p }
bind-key -T root MouseDown3Pane if-shell -F -t = "#{||:#{mouse_any_flag},#{&&:#{pane_in_mode},#{?#{m/r:(copy|view)-mode,#{pane_mode}},0,1}}}" { select-pane -t = ; send-keys -M } { display-menu -T "#[align=centre]#{pane_index} (#{pane_id})" -t = -x M -y M "#{?#{m/r:(copy|view)-mode,#{pane_mode}},Go To Top,}" < { send-keys -X history-top } "#{?#{m/r:(copy|view)-mode,#{pane_mode}},Go To Bottom,}" > { send-keys -X history-bottom } '' "#{?mouse_word,Search For #[underscore]#{=/9/...:mouse_word},}" C-r { if-shell -F "#{?#{m/r:(copy|view)-mode,#{pane_mode}},0,1}" "copy-mode -t=" ; send-keys -X -t = search-backward "#{q:mouse_word}" } "#{?mouse_word,Type #[underscore]#{=/9/...:mouse_word},}" C-y { copy-mode -q ; send-keys -l "#{q:mouse_word}" } "#{?mouse_word,Copy #[underscore]#{=/9/...:mouse_word},}" c { copy-mode -q ; set-buffer "#{q:mouse_word}" } "#{?mouse_line,Copy Line,}" l { copy-mode -q ; set-buffer "#{q:mouse_line}" } '' "Horizontal Split" h { split-window -h } "Vertical Split" v { split-window -v } '' "#{?#{>:#{window_panes},1},,-}Swap Up" u { swap-pane -U } "#{?#{>:#{window_panes},1},,-}Swap Down" d { swap-pane -D } "#{?pane_marked_set,,-}Swap Marked" s { swap-pane } '' Kill X { kill-pane } Respawn R { respawn-pane -k } "#{?pane_marked,Unmark,Mark}" m { select-pane -m } "#{?#{>:#{window_panes},1},,-}#{?window_zoomed_flag,Unzoom,Zoom}" z { resize-pane -Z } }
bind-key -T root MouseDown3Status display-menu -T "#[align=centre]#{window_index}:#{window_name}" -t = -x W -y W "#{?#{>:#{session_windows},1},,-}Swap Left" l { swap-window -t :-1 } "#{?#{>:#{session_windows},1},,-}Swap Right" r { swap-window -t :+1 } "#{?pane_marked_set,,-}Swap Marked" s { swap-window } '' Kill X { kill-window } Respawn R { respawn-window -k } "#{?pane_marked,Unmark,Mark}" m { select-pane -m } Rename n { command-prompt -F -I "#W" { rename-window -t "#{window_id}" "%%" } } '' "New After" w { new-window -a } "New At End" W { new-window }
bind-key -T root MouseDown3StatusLeft display-menu -T "#[align=centre]#{session_name}" -t = -x M -y W Next n { switch-client -n } Previous p { switch-client -p } '' Renumber N { move-window -r } Rename n { command-prompt -I "#S" { rename-session "%%" } } '' "New Session" s { new-session } "New Window" w { new-window }
bind-key -T root MouseDrag1Pane if-shell -F "#{||:#{pane_in_mode},#{mouse_any_flag}}" { send-keys -M } { copy-mode -M }
bind-key -T root MouseDrag1Border resize-pane -M
bind-key -T root WheelUpPane if-shell -F "#{||:#{pane_in_mode},#{mouse_any_flag}}" { send-keys -M } { copy-mode -e }
bind-key -T root WheelUpStatus previous-window
bind-key -T root WheelDownStatus next-window
bind-key -T root DoubleClick1Pane select-pane -t = \; if-shell -F "#{||:#{pane_in_mode},#{mouse_any_flag}}" { send-keys -M } { copy-mode -H ; send-keys -X select-word ; run-shell -d 0.3 ; send-keys -X copy-pipe-and-cancel }
bind-key -T root TripleClick1Pane select-pane -t = \; if-shell -F "#{||:#{pane_in_mode},#{mouse_any_flag}}" { send-keys -M } { copy-mode -H ; send-keys -X select-line ; run-shell -d 0.3 ; send-keys -X copy-pipe-and-cancel }
bind-key -T root M-H previous-window
bind-key -T root M-L next-window
bind-key -T root M-MouseDown3Pane display-menu -T "#[align=centre]#{pane_index} (#{pane_id})" -t = -x M -y M "#{?#{m/r:(copy|view)-mode,#{pane_mode}},Go To Top,}" < { send-keys -X history-top } "#{?#{m/r:(copy|view)-mode,#{pane_mode}},Go To Bottom,}" > { send-keys -X history-bottom } '' "#{?mouse_word,Search For #[underscore]#{=/9/...:mouse_word},}" C-r { if-shell -F "#{?#{m/r:(copy|view)-mode,#{pane_mode}},0,1}" "copy-mode -t=" ; send-keys -X -t = search-backward "#{q:mouse_word}" } "#{?mouse_word,Type #[underscore]#{=/9/...:mouse_word},}" C-y { copy-mode -q ; send-keys -l "#{q:mouse_word}" } "#{?mouse_word,Copy #[underscore]#{=/9/...:mouse_word},}" c { copy-mode -q ; set-buffer "#{q:mouse_word}" } "#{?mouse_line,Copy Line,}" l { copy-mode -q ; set-buffer "#{q:mouse_line}" } '' "Horizontal Split" h { split-window -h } "Vertical Split" v { split-window -v } '' "#{?#{>:#{window_panes},1},,-}Swap Up" u { swap-pane -U } "#{?#{>:#{window_panes},1},,-}Swap Down" d { swap-pane -D } "#{?pane_marked_set,,-}Swap Marked" s { swap-pane } '' Kill X { kill-pane } Respawn R { respawn-pane -k } "#{?pane_marked,Unmark,Mark}" m { select-pane -m } "#{?#{>:#{window_panes},1},,-}#{?window_zoomed_flag,Unzoom,Zoom}" z { resize-pane -Z }
bind-key -T root M-Up select-pane -U
bind-key -T root M-Down select-pane -D
bind-key -T root M-Left select-pane -L
bind-key -T root M-Right select-pane -R
bind-key -T root S-Left previous-window
bind-key -T root S-Right next-window
```

1
dotbot

Submodule dotbot deleted from 328bcb3259

Submodule dotbot-include deleted from 6943c52125

View File

@@ -1,4 +1,4 @@
- include: 'hosts/defaults.yaml'
- include: "tools/dotbot-defaults.yaml"
- shell:
- echo "Configuring air"
- brewfile:

View File

@@ -1,4 +1,4 @@
- include: 'hosts/defaults.yaml'
- include: "tools/dotbot-defaults.yaml"
- shell:
- echo "Configuring lakka"
- link:

View File

@@ -1,4 +1,4 @@
- include: 'hosts/defaults.yaml'
- include: "tools/dotbot-defaults.yaml"
- shell:
- echo "Configuring tunkki"
- link:

View File

@@ -1,60 +1,11 @@
[include]
path = ~/.dotfiles/config/git/shared
[user]
name = Ismo Vuorinen
email = ismo.vuorinen@vincit.fi
signingkey = ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDLyOvkr1nRqMVv3UAizmk6C+q40H4khvw7qIXXXyOyFmzjwYx/Cuxoi4uZVjX+q4qFYJ+c312uu6YXiEtfyoCao3wub8r1cLBQ3eIvuyWp2K8Ixcd9JmFmLmoeiENpJxqyr0WPZLDkrCWUZCsQQh8zzGFnfciUdUdTiZ7s21AEhhmFRSdFlVfQSlGMFxU321psg1YilcP80bDwFd1FsL4TssSkwlbgP/twqnpZ4436TTo7kp0UnH/RZkfRdDWScKHaWgncBG0CZeQxGWnRp8fvZn/7gDnthcZhvnDALVBE7QFuZ90GxqVw3IGpHryV0mFO6EGQ9Ke9YX7pKVZPUXZjeCN4SVKsqFdVJ6AjaSJ9K7nL98rYK7qNzndT3cKqPNgPteyXWRulH68A51ecQqHrjTttZcdN9hKt9uBHpzuXsby2QObT+VB4MNjZapa+YYF/WgwJCml4lzn2xMFg1vYZD78pfoJ9e5f2cL1MMlUSDb0TNxmEXfDQ77H/pRpKDz0=
[core]
excludesfile = ~/.config/git/gitignore
[alias]
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
nah = !git reset --hard && git clean -df
undo-commit = reset HEAD~ --soft
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
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\"
branchbydate = for-each-ref --count=30 --sort=-committerdate refs/heads/ --format='%(refname:short)'
branchcolor = "!for ref in $(git for-each-ref --sort=-committerdate --format=\"%(refname)\" refs/heads/ refs/remotes ); do git log -n1 $ref --pretty=format:\"%Cgreen%cr%Creset %C(yellow)%d%Creset %C(bold blue)<%an>%Creset%n\" | cat ; done | awk '! a[$0]++'"
[diff]
tool = difftastic
[difftool]
prompt = false
[difftool "difftastic"]
cmd = difft "$LOCAL" "$REMOTE"
[filter "lfs"]
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
required = true
[init]
defaultBranch = main
[pull]
rebase = true
[color]
ui = true
diff = auto
branch = auto
status = auto
[color "status"]
added = green bold
changed = yellow
deleted = red bold strike
untracked = cyan
branch = yellow black bold ul
[gpg]
format = ssh
[gpg "ssh"]
program = /Applications/1Password.app/Contents/MacOS/op-ssh-sign
allowedSignersFile = ~/.ssh/allowed_signers
@@ -69,7 +20,3 @@
[credential "https://gist.github.com"]
helper =
helper = !/opt/homebrew/bin/gh auth git-credential
[submodule]
recurse = true

View File

@@ -1,4 +1,4 @@
- include: 'hosts/defaults.yaml'
- include: "tools/dotbot-defaults.yaml"
- shell:
- echo "Configuring v"
- brewfile:

14
install
View File

@@ -3,12 +3,12 @@
set -e
CONFIG="install.conf.yaml"
DOTBOT_DIR="dotbot"
DOTBOT_DIR="tools/dotbot"
DOTBOT_BIN="bin/dotbot"
BASEDIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
DOTBOT_BIN_PATH="${BASEDIR}/${DOTBOT_DIR}/${DOTBOT_BIN}"
DOTBOT_HOST="$(hostname -s)" || ''
DOTBOT_HOST="$(hostname -s)"
cd "$BASEDIR"
git submodule sync --quiet --recursive
@@ -16,9 +16,8 @@ git submodule update --init --recursive
"${DOTBOT_BIN_PATH}" \
-d "${BASEDIR}" \
--plugin-dir=dotbot-brew \
--plugin-dir=dotbot-gh-extension \
--plugin-dir=dotbot-include \
--plugin-dir=tools/dotbot-brew \
--plugin-dir=tools/dotbot-include \
-c "${CONFIG}" \
"${@}"
@@ -29,9 +28,8 @@ if [ "${DOTBOT_HOST}" != "" ]; then
&& echo "(!) Found $DOTBOT_HOST_CONFIG" \
&& "$DOTBOT_BIN_PATH" \
-d "$BASEDIR" \
--plugin-dir=dotbot-brew \
--plugin-dir=dotbot-gh-extension \
--plugin-dir=dotbot-include \
--plugin-dir=tools/dotbot-brew \
--plugin-dir=tools/dotbot-include \
-c "$DOTBOT_HOST_CONFIG" \
"${@}"
fi

View File

@@ -1,33 +0,0 @@
#!/usr/bin/env bash
set -e
CONFIG="install.conf.yaml"
DOTBOT_DIR="dotbot"
DOTBOT_BIN="bin/dotbot"
BASEDIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
DOTBOT_HOST="$(hostname -s)" || ''
DOTBOT_BIN_PATH="${BASEDIR}/${DOTBOT_DIR}/${DOTBOT_BIN}"
cd "$BASEDIR"
git submodule sync --quiet --recursive
git submodule update --init --recursive
"${DOTBOT_BIN_PATH}" \
-d "${BASEDIR}" \
--plugin-dir=dotbot-include \
-c "${CONFIG}" \
"${@}"
if [ "${DOTBOT_HOST}" != "" ]; then
DOTBOT_HOST_CONFIG="${BASEDIR}/hosts/${DOTBOT_HOST}/${CONFIG}"
echo "-> Trying if host config can be found: ${DOTBOT_HOST_CONFIG}"
[ -r "$DOTBOT_HOST_CONFIG" ] && [ -f "$DOTBOT_HOST_CONFIG" ] \
&& echo "(!) Found $DOTBOT_HOST_CONFIG" \
&& "$DOTBOT_BIN_PATH" \
-d "$BASEDIR" \
--plugin-dir=dotbot-include \
-c "$DOTBOT_HOST_CONFIG" \
"${@}"
fi

View File

@@ -1,4 +1,4 @@
- include: 'hosts/defaults.yaml'
- include: "tools/dotbot-defaults.yaml"
- clean:
~/:
~/.config:
@@ -9,6 +9,9 @@
~/.cache:
~/.cache/git:
~/.config:
~/.config/cheat/cheatsheets/personal:
~/.config/cheat/cheatsheets/pure-bash-bible:
~/.config/cheat/cheatsheets/tldr:
~/.local:
~/.local/run:
~/.local/share:

View File

@@ -9,6 +9,7 @@
# Helper variables, override with ENVs like `VERBOSE=1 dfm help`
: "${VERBOSE:=0}"
: "${DOTFILES:=$HOME/.dotfiles}"
: "${SHARED_SCRIPT:=$DOTFILES/scripts/shared.sh}"
: "${INSTALL_SCRIPT:=$DOTFILES/scripts/install-dotfiles.sh}"
: "${BREWFILE:=$DOTFILES/Brewfile}"
: "${HOSTFILES:=$DOTFILES/hosts}"
@@ -18,11 +19,29 @@ SCRIPT=$(basename "$0")
VERSION_NVM="v0.39.3"
# shellcheck source=./../../scripts/shared.sh
source "$DOTFILES/scripts/shared.sh"
source "$SHARED_SCRIPT"
function section_install
{
USAGE_PREFIX="$SCRIPT install"
USAGE_PREFIX="$SCRIPT install <command>"
MENU=(
"all:Installs everything in the correct order"
"antigen:Updates the antigen.zsh file"
"cheat-databases:Install cheat external cheatsheet databases"
"composer:Install composer"
"dotenv:Install dotenv-linter"
"gh:Install GitHub CLI Extensions"
"go:Install Go Packages"
"imagick:Install ImageMagick CLI"
"starship:Install starship.rs"
"macos:Setup nice macOS defaults"
"neofetch:Install neofetch"
"nvm:Install Node Version Manager (nvm)"
"npm:Install NPM Packages"
"ntfy:Install ntfy"
"z:Install z"
)
case "$1" in
all)
@@ -32,125 +51,155 @@ function section_install
$0 brew install
$0 install composer
$0 install dotenv
$0 install fzf
$0 install gh
$0 install go
$0 install cheat-databases
$0 install imagick
$0 install neofetch
$0 install nvm
$0 install npm
$0 install ntfy
$0 install z
;;
antigen)
curl -L git.io/antigen > "$DOTFILES/local/bin/antigen.zsh" \
&& msg_done "🎉 New antigen installed!"
curl -sSfL git.io/antigen -o "$DOTFILES/local/bin/antigen.zsh" \
&& msg_yay "New antigen installed!"
;;
cheat-databases)
for database in "$DOTFILES"/scripts/install-cheat-*; do
bash "$database" \
&& msg_yay "Cheat: $database run"
done
;;
composer)
bash "$DOTFILES/scripts/install-composer.sh" \
&& msg_done "🎉 composer installed!"
&& msg_yay "composer installed!"
;;
dotenv)
curl -sSfL \
https://raw.githubusercontent.com/dotenv-linter/dotenv-linter/master/install.sh \
| sh -s -- -b "$XDG_BIN_HOME" \
&& msg_done "🎉 dotenv-linter installed!"
&& msg_yay "dotenv-linter installed!"
;;
fzf)
bash "$DOTFILES/scripts/install-fzf.sh" \
&& msg_yay "fzf installed!"
;;
gh)
bash "$DOTFILES/scripts/install-gh-extensions.sh" \
&& msg_done "🎉 github cli extensions installed!"
&& msg_yay "github cli extensions installed!"
;;
go)
bash "$DOTFILES/scripts/install-go-packages.sh" \
&& msg_done "🎉 go packages installed!"
&& msg_yay "go packages installed!"
;;
imagick)
wget https://imagemagick.org/archive/binaries/magick > "$XDG_BIN_HOME/magick" \
&& msg_done "🎉 imagick installed!"
curl -L https://imagemagick.org/archive/binaries/magick > "$XDG_BIN_HOME/magick" \
&& chmod +x "$XDG_BIN_HOME/magick" \
&& msg_yay "imagick installed!"
;;
starship)
curl -sS https://starship.rs/install.sh | sh -s -- --bin-dir ~/.local/bin \
&& msg_done "🎉 starship installed!"
curl -sS https://starship.rs/install.sh | sh -s -- \
--bin-dir ~/.local/bin \
--yes \
&& msg_yay "starship installed!"
;;
macos)
bash "$DOTFILES/scripts/set-macos-defaults.sh" \
&& msg_done "🎉 Brewfile defined apps has been installed!"
&& msg_yay "Brewfile defined apps has been installed!"
;;
neofetch)
bash "$DOTFILES/scripts/install-neofetch.sh" \
&& msg_yay "neofetch installed!"
;;
nvm)
curl -o- "https://raw.githubusercontent.com/nvm-sh/nvm/$VERSION_NVM/install.sh" | bash \
&& nvm install --lts --latest-npm --default \
&& git checkout "$HOME/.zshrc" \
&& msg_done "🎉 nvm installed!"
&& nvm install --lts --latest-npm --default
git checkout "$DOTFILES/base/zshrc"
msg_yay "nvm installed!"
;;
npm)
bash "$DOTFILES/scripts/install-npm-packages.sh" \
&& msg_done "🎉 NPM Packages have been installed!"
&& msg_yay "NPM Packages have been installed!"
;;
ntfy)
bash "$DOTFILES/scripts/install-ntfy.sh" \
&& msg_done "🎉 ntfy installed!"
&& msg_yay "ntfy installed!"
;;
z)
bash "$DOTFILES/scripts/install-z.sh" \
&& msg_done "🎉 z has been installed!"
;;
*)
menu_section "$USAGE_PREFIX" "all | antigen | composer | dotenv | gh | go | imagick | starship | macos | nvm | npm"
menu_item "all" "Installs macos defaults, antigen, starship, brew, nvm, npm packages and others"
menu_item "antigen" "Updates the antigen.zsh file"
menu_item "composer" "Install composer"
menu_item "dotenv" "Install dotenv-linter"
menu_item "gh" "Install GitHub CLI Extensions"
menu_item "go" "Install Go Packages"
menu_item "imagick" "Install ImageMagick CLI"
menu_item "starship" "Install starship.rs"
menu_item "macos" "Setup nice macOS defaults"
menu_item "nvm" "Install Node Version Manager (nvm)"
menu_item "npm" "Install NPM Packages"
menu_item "ntfy" "Install ntfy"
menu_item "z" "Install z"
&& msg_yay "z has been installed!"
;;
*) menu_usage "$USAGE_PREFIX" "${MENU[@]}" ;;
esac
}
function section_brew
{
USAGE_PREFIX="$SCRIPT brew"
USAGE_PREFIX="$SCRIPT brew <command>"
if ! command -v brew &> /dev/null; then
menu_section "$USAGE_PREFIX" "brew not available on this system"
else
MENU=(
"install:Installs items defined in Brewfile"
"update:Updates and upgrades brew packages"
"updatebundle:Updates Brewfile with descriptions"
"autoupdate:Setups brew auto-update and runs it immediately"
)
have brew && {
case "$1" in
install)
brew bundle install --file="$BREWFILE" && msg_done "🎉 Done!"
brew bundle install --file="$BREWFILE" && msg_yay "Done!"
;;
update)
brew update && brew outdated && brew upgrade && brew cleanup
msg_done "🎉 Done!"
msg_yay "Done!"
;;
updatebundle)
# Updates .dotfiles/Brewfile with descriptions
brew bundle dump \
--force \
--file="$BREWFILE" \
--describe && msg_done "🎉 Done!"
--describe && msg_yay "Done!"
;;
autoupdate)
brew autoupdate delete
brew autoupdate start 43200 --upgrade --cleanup --immediate
;;
*)
menu_section "$USAGE_PREFIX" "install | update | updatebundle | autoupdate"
menu_item "install" "Installs items defined in Brewfile"
menu_item "update" "Updates and upgrades brew packages"
menu_item "updatebundle" "Updates Brewfile with descriptions"
menu_item "autoupdate" "Setups brew auto-update and runs it immediately"
menu_usage "$USAGE_PREFIX" "${MENU[@]}"
;;
esac
fi
}
! have brew && menu_section "$USAGE_PREFIX" "brew not available on this system"
}
function section_docs
{
USAGE_PREFIX="$SCRIPT docs <command>"
MENU=(
"tmux:Update tmux keybindings documentation"
)
case "$1" in
tmux) bash "$DOTFILES/local/bin/x-dfm-docs-xterm-keybindings" ;;
*) menu_usage "$USAGE_PREFIX" "${MENU[@]}" ;;
esac
}
function section_dotfiles
{
USAGE_PREFIX="$SCRIPT dotfiles"
USAGE_PREFIX="$SCRIPT dotfiles <command>"
MENU=(
"fmt:Run all formatters"
"yamlfmt:Run yamlfmt to all dotfiles, which are in our control"
"shfmt:Run shfmt to all dotfiles"
"reset_all:Reset everything, runs all configured reset actions"
"reset_nvim:Resets nvim. Deletes caches, removes nvim folders and relinks nvim folders"
)
case "$1" in
fmt)
@@ -171,16 +220,17 @@ function section_dotfiles
~/.config/astronvim \
~/.config/nvim
msg_ok "Deleted old nvim files"
ln -s ~/.dotfiles/config/astronvim ~/.config/astronvim
ln -s ~/.dotfiles/config/nvim ~/.config/nvim
ln -s "$DOTFILES/config/astronvim" ~/.config/astronvim
ln -s "$DOTFILES/config/nvim" ~/.config/nvim
msg_ok "Linked nvim and astronvim"
hash npm 2> /dev/null && $0 install npm
have npm && $0 install npm
msg_ok "Installed packages"
msg_done "nvim reset!"
;;
yamlfmt)
# format yaml files
yamlfmt -conf "$DOTFILES/.yamlfmt"
have yamlfmt && yamlfmt -conf "$DOTFILES/.yamlfmt"
! have yamlfmt && msg_err "yamlfmt not found"
;;
shfmt)
# Format shell scripts according to following rules.
@@ -188,6 +238,7 @@ function section_dotfiles
-type f -perm +111 \
-not -path '*/.git/*' \
-not -path '*dotbot*' \
-not -path '*tmux*' \
-not -name '*.pl' \
-not -name '*.py' \
-not -name '*.php' \
@@ -197,25 +248,23 @@ function section_dotfiles
--func-next-line --list --write \
--indent 2 --case-indent --space-redirects \
--binary-next-line {} \;
msg_done "🎉 dotfiles have been shfmt formatted!"
;;
*)
menu_section "$USAGE_PREFIX" "fmt | reset_all | reset_nvim | yamlfmt | shfmt"
menu_item "fmt" "Run all formatters"
menu_item "reset_all" "Reset everything, runs all configured reset actions"
menu_item "reset_nvim" "Resets nvim. Deletes caches, removes nvim folders and relinks nvim folders"
menu_item "yamlfmt" "Run yamlfmt to all dotfiles, which are in our control"
menu_item "shfmt" "Run shfmt to all dotfiles"
msg_yay "dotfiles have been shfmt formatted!"
;;
*) menu_usage "$USAGE_PREFIX" "${MENU[@]}" ;;
esac
}
function section_check
{
USAGE_PREFIX="$SCRIPT check"
USAGE_PREFIX="$SCRIPT check <command>"
X_HOSTNAME=$(hostname)
X_ARCH=$(uname)
MENU=(
"arch <arch>:Empty <arch> returns current. Exit code 0=match to current, 1=no match."
"host <host>:Empty <host> returns current. Exit code 0=match to current, 1=no match."
)
case "$1" in
a | arch)
[[ "$2" = "" ]] && echo "$X_ARCH" && exit 0
@@ -225,44 +274,45 @@ function section_check
[[ "$2" = "" ]] && echo "$X_HOSTNAME" && exit 0
[[ $X_HOSTNAME = "$2" ]] && exit 0 || exit 1
;;
*)
menu_section "$USAGE_PREFIX" "arch | host"
menu_item "arch <arch>" "Empty returns current. Exit code 0 when match, 1 when not."
menu_item "host <host>" "Empty returns current. Exit code 0 when match, 1 when not."
;;
*) menu_usage "$USAGE_PREFIX" "${MENU[@]}" ;;
esac
}
# Secret menu for visual tests
function section_tests
{
USAGE_PREFIX="$SCRIPT tests"
USAGE_PREFIX="$SCRIPT tests <command>"
MENU=(
"msg:List all log functions from shared.sh"
)
case "$1" in
msg)
msg "msg"
msg_done "msg_done"
msg_prompt "msg_prompt"
msg_prompt_done "msg_prompt_done"
msg_done_suffix "msg_done_suffix"
msg_err "msg_err"
msg_nested "msg_nested"
msg_nested_done "msg_nested_done"
msg_run "msg_run" "second_param"
msg_ok "msg_ok"
msg_prompt "msg_prompt"
msg_prompt_done "msg_prompt_done"
msg_run "msg_run" "second_param"
msg_run_done "msg_run_done" "second_param"
msg_warn "msg_warn"
msg_err "msg_err"
;;
*)
menu_section "$USAGE_PREFIX" "msg"
menu_item "msg" "List all log functions from shared.sh"
msg_yay "msg_yay"
msg_yay_done "msg_yay_done"
;;
*) menu_usage "$USAGE_PREFIX" "${MENU[@]}" ;;
esac
}
function usage
{
echo ""
menu_section "Usage: $SCRIPT" "install | reset | brew | check | dotfiles"
echo $" All commands have their own subcommands."
msg_prompt "Usage: $SCRIPT <section> <command>"
echo $" Empty <command> prints <section> help."
echo ""
section_install
echo ""
@@ -271,6 +321,8 @@ function usage
section_check
echo ""
section_dotfiles
echo ""
section_docs
}
# The main loop. first keyword after $0 triggers section, or help.
@@ -279,6 +331,7 @@ case "$1" in
brew) section_brew "$2" ;;
check) section_check "$2" ;;
dotfiles) section_dotfiles "$2" ;;
docs) section_docs "$2" ;;
tests) section_tests "$2" ;;
*) usage && exit 0 ;;
esac

BIN
local/bin/phpcs Executable file

Binary file not shown.

View File

@@ -13,11 +13,13 @@ if [ -z "${FILENAME}" ]; then
FILENAME=$DIRECTORY
fi
FILENAME=${FILENAME} \
| tr '/' _ \
| iconv -t ascii//TRANSLIT \
| sed -r s/[^a-zA-Z0-9]+/_/g \
| sed -r s/^_+\|-+$//g
FILENAME=$(
${FILENAME} \
| tr '/' _ \
| iconv -t ascii//TRANSLIT \
| sed -r s/[^a-zA-Z0-9]+/_/g \
| sed -r s/^_+\|-+$//g
)
TIMESTAMP=$(date "+%Y%m%d_%H%M%S")
FILENAME_TIMESTAMP="${FILENAME}_${TIMESTAMP}"

View File

@@ -11,4 +11,3 @@ dir="$1"
if [ ! -d "$dir" ]; then
mkdir -p "$dir" && exit 0
fi

View File

@@ -0,0 +1,22 @@
#!/usr/bin/env bash
#
# x-xterm-update-keybindings
# Updates $HOME/.dotfiles/docs/tmux.md with my keybindings.
# shellcheck source=./../../scripts/shared.sh
source "$HOME/.dotfiles/scripts/shared.sh"
have tmux || {
msg_err "tmux not found" && exit 0
}
TMUX_KEYBINDINGS_DOCS="$DOTFILES/docs/tmux-keybindings.md"
CB="\n\`\`\`\n"
KB=$(tmux list-keys)
H="# tmux keybindings\n"
L="\n\nLeader: \`<ctrl><space>\`\n\n"
msg "Outputting tmux keybindings to $TMUX_KEYBINDINGS_DOCS"
echo -e "${H}${L}${CB}${KB}${CB}" > "$TMUX_KEYBINDINGS_DOCS"
msg_done "Done!"

53
local/bin/x-hr Executable file
View File

@@ -0,0 +1,53 @@
#!/usr/bin/env bash
# Simple script to output a solid line in the terminal
# Useful for marking the end of a task in your bash log
# Inspired by @LuRsT's script of the same name
# Can be called directly, or source'd in *rc file
#
# Licensed under MIT, (C) Alicia Sykes 2022
# See: https://github.com/Lissy93/dotfiles
#
# Modified by Ismo Vuorinen <https://github.com/ivuorinen> 2023
# Determine width of terminal
hr_col_count="$(tput cols)"
if [ -z "${hr_col_count+set}" ] || [ "$hr_col_count" -lt 1 ]; then
hr_col_count="${COLUMNS:-80}"
fi
# Colors
CLR_RED="\033[1;31m"
hr_color="${hr_color:=$CLR_RED}"
hr_reset="\033[0m"
# Prints the HR line
hr_draw_char() {
local CHAR="$1"
local LINE=''
LINE=$(printf "%*s" "$((hr_col_count - 2))")
LINE="${LINE// /${CHAR}}"
echo -e "◀${hr_color}${LINE:0:${hr_col_count}}${hr_reset}▶"
}
# Passes param and calls hr()
hr() {
for WORD in "${@:--}"; do
hr_draw_char "$WORD"
done
}
# Determine if file is being run directly or sourced
(
[[ -n $ZSH_EVAL_CONTEXT && $ZSH_EVAL_CONTEXT =~ :file$ ]] \
|| [[ -n $KSH_VERSION && $(cd "$(dirname -- "$0")" \
&& printf '%s' "${PWD%/}/")$(basename -- "$0") != "${.sh.file}" ]] \
|| [[ -n $BASH_VERSION ]] && (return 0 2>/dev/null)
) && sourced=1 || sourced=0
# Either instantiate immediately, or set alias for later
if [ "$sourced" -eq 0 ]; then
[ "$0" == "${BASH_SOURCE[0]}" ] && hr "$@"
else
export alias hr='hr'
fi

View File

@@ -2,4 +2,3 @@
# Source: https://github.com/thirtythreeforty/dotfiles/blob/master/bin/extip
curl icanhazip.com "${@}"

View File

@@ -8,24 +8,24 @@ $quota = '';
$output = [];
$fsCharLenght = 0;
if ($debug) {
$quota = "Disk quotas for user viir (uid 2913):
Filesystem blocks quota limit grace files quota limit grace
10.0.0.89:/www/webroots/2 8277615 52428800 52428800 0 0 0
10.0.0.179:/users1/users/2 1999431 52428800 52428800 0 0 0
10.0.0.90:/siilo/2 24835106 524288000 524288000 0 0 0";
} else {
// $quota = system("quota -w");
$quota = shell_exec("quota -w");
}
$quota = shell_exec("quota -w");
function pad($i, $n = 3, $p = ' ') {
/**
* Pad string
*
* @param string $i Input string
* @param int $n Length
* @param string $p Padding string
* @return string
*/
function pad($i, $n = 3, $p = ' ')
{
return str_pad($i, $n, $p, STR_PAD_LEFT);
}
if (empty($quota)) {
var_dump($quota);
die("quota was empty\n");
var_dump($quota);
die("quota was empty\n");
}
$quota = explode("\n", $quota);
@@ -41,34 +41,34 @@ foreach ($quota as $lineNum => $line) {
if (count($values) != 4) {
continue;
}
$result = array_combine(['fs', 'used', 'quota', 'limit'], $values);
$result['used_percentage'] = round($result['used'] / $result['quota'] * 100, 3);
$result['used_gb'] = round($result['used'] / 1024 / 1024, 2);
$result['quota_gb'] = round($result['quota'] / 1024 / 1024, 2);
$char = strlen($result['fs']);
if ($char > $fsCharLenght) {
$fsCharLenght = $char;
}
$output[] = $result;
}
if (!empty($output)) {
$header = sprintf("%s | %s | %s | %s",
$header = sprintf(
"%s | %s | %s | %s",
str_pad("Mount", $fsCharLenght),
'Usage%',
'Used/Total',
'Bar'
);
$headerWidth = strlen($header);
echo "\n" . $header . "\n";
echo str_repeat('-', $headerWidth + 24) . "\n";
foreach ($output as $i) {
$barUsed = round($i['used_percentage']) / 4;
echo sprintf(
@@ -82,4 +82,3 @@ if (!empty($output)) {
echo "\n\n";
}

93
local/bin/x-welcome-banner Executable file
View File

@@ -0,0 +1,93 @@
#!/usr/bin/env bash
######################################################################
# 🌞 Welcome Banner #
######################################################################
# Prints personal greeting, system info and data about today #
# Intended for use as a MOTD, for when using multiple systems #
# For docs and more info, see: https://github.com/lissy93/dotfiles #
# #
# Licensed under MIT (C) Alicia Sykes 2022 <https://aliciasykes.com> #
######################################################################
# Formatting variables
COLOR_P='\033[1;36m'
COLOR_S='\033[0;36m'
RESET='\033[0m'
# Print time-based personalized message, using figlet & lolcat if availible
function welcome_greeting () {
h=$(date +%H)
if [ "$h" -lt 04 ] || [[ $h -gt 22 ]];
then greeting="Good Night"
elif [ "$h" -lt 12 ];
then greeting="Good morning"
elif [ "$h" -lt 18 ];
then greeting="Good afternoon"
elif [ "$h" -lt 22 ];
then greeting="Good evening"
else
greeting="Hello"
fi
WELCOME_MSG="$greeting $USER!"
if hash lolcat 2>/dev/null && hash figlet 2>/dev/null; then
echo "${WELCOME_MSG}" | figlet | lolcat
else
echo -e "$COLOR_P${WELCOME_MSG}${RESET}\n"
fi
}
# Print system information with neofetch, if it's installed
function welcome_sysinfo () {
if hash neofetch 2>/dev/null; then
neofetch --shell_version off \
--disable kernel distro shell resolution de wm wm_theme theme icons terminal \
--backend off \
--colors 4 8 4 4 8 6 \
--color_blocks off \
--memory_display info
fi
}
# Print todays info: Date, IP, weather, etc
function welcome_today () {
timeout=1
echo -e "\033[1;34mToday\n------"
# Print date time
echo -e "$COLOR_S$(date '+🗓️ Date: %A, %B %d, %Y at %H:%M')"
# Print local weather
curl -s -m $timeout "https://wttr.in?format=%cWeather:+%C+%t,+%p+%w"
echo -e "${RESET}"
# Print IP address
if hash ip 2>/dev/null; then
ip_address=$(ip route get 8.8.8.8 | awk -F"src " 'NR==1{split($2,a," ");print a[1]}')
ip_interface=$(ip route get 8.8.8.8 | awk -F"dev " 'NR==1{split($2,a," ");print a[1]}')
echo -e "${COLOR_S}🌐 IP: $(curl -s -m $timeout 'https://ipinfo.io/ip') (${ip_address} on ${ip_interface})"
echo -e "${RESET}\n"
fi
}
# Putting it all together
function welcome() {
welcome_greeting
welcome_sysinfo
welcome_today
}
# Determine if file is being run directly or sourced
([[ -n $ZSH_EVAL_CONTEXT && $ZSH_EVAL_CONTEXT =~ :file$ ]] \
|| [[ -n $KSH_VERSION && $(cd "$(dirname -- "$0")" \
&& printf '%s' "${PWD%/}/")$(basename -- "$0") != "${.sh.file}" ]] \
|| [[ -n $BASH_VERSION ]] && (return 0 2>/dev/null)
) && sourced=1 || sourced=0
# If script being called directly run immediately
if [ "$sourced" -eq 0 ]; then
welcome "$@"
fi
# EOF

8
phpcs.xml Normal file
View File

@@ -0,0 +1,8 @@
<?xml version="1.0"?>
<ruleset name="PHP_CodeSniffer">
<description>PHP_CodeSniffer configuration</description>
<rule ref="PSR12">
<exclude name="PSR12.Operators.OperatorSpacing"/>
<exclude name="PSR1.Files.SideEffects.FoundWithSymbols"/>
</rule>
</ruleset>

View File

@@ -0,0 +1,55 @@
#!/usr/bin/env bash
# shellcheck disable=SC2231,SC2034,SC2181,SC2068
# shellcheck source=shared.sh
source "$HOME/.dotfiles/scripts/shared.sh"
PBB_REQUIRED_TOOLS=(basename git mkdir cheat ls grep head awk cp echo rm)
for t in ${PBB_REQUIRED_TOOLS[@]}; do
! have "$t" && echo "(!) $t is missing, can't continue..." && exit 1
done
PBB_GIT="https://github.com/dylanaraps/pure-bash-bible.git"
PBB_SOURCE="source: $PBB_GIT"
PBB_SYNTAX="syntax: bash"
PBB_TAGS="tags: [bash]"
PBB_TEMP_PREFIX=$(basename "$0")
PBB_TEMP_DIR="/tmp/pbb-$(rnd)"
# If there's no .git, clone the folder
if [ ! -d "$PBB_TEMP_DIR/.git" ]; then
msg_run "Starting to clone $PBB_GIT"
git clone --depth 1 --single-branch -q "$PBB_GIT" "$PBB_TEMP_DIR" \
&& msg_yay "Cloned $PBB_GIT"
fi
PBB_CHAPTERS=$(ls -1v "$PBB_TEMP_DIR"/manuscript/chapter*)
CHEAT_DEST="$(cheat -d | grep pure-bash-bible | head -1 | awk '{print $2}')"
if [ ! -d "$CHEAT_DEST" ]; then
mkdir -p "$CHEAT_DEST"
fi
for f in ${PBB_CHAPTERS[@]}; do
# get all headers, take the first one, strip the # and return the first word in lowercase
HEADER=$(grep -e '^[#] ' "$f" | head -1 | awk '{print tolower($2)}')
CHEAT_FILE="$CHEAT_DEST/${HEADER}"
if [ ! -f "$CHEAT_FILE" ]; then
cp "$f" "$CHEAT_FILE" && msg_run "$CHEAT_FILE"
fi
LC_ALL=C perl -pi.bak -e 's/\<\!-- CHAPTER END --\>//' "$CHEAT_FILE"
rm "$CHEAT_FILE.bak"
# add tags if the file doesn't have them
if [ '---' != "$(head -1 < "$CHEAT_FILE")" ]; then
T="$PBB_SYNTAX\n$PBB_TAGS\n$PBB_SOURCE\n"
echo -e "---\n$T---\n$(cat "$CHEAT_FILE")" > "$CHEAT_FILE"
fi
done
# Cleanup
if [ -d "$PBB_TEMP_DIR" ]; then
rm -rf "$PBB_TEMP_DIR"
fi

68
scripts/install-cheat-tldr.sh Executable file
View File

@@ -0,0 +1,68 @@
#!/usr/bin/env bash
# shellcheck disable=SC2231,SC2034,SC2181,SC2068
# shellcheck source=shared.sh
source "$HOME/.dotfiles/scripts/shared.sh"
TLDR_REQUIRED_TOOLS=(basename git mkdir cheat ls grep head awk cp echo rm)
for t in ${TLDR_REQUIRED_TOOLS[@]}; do
! have "$t" && echo "(!) $t is missing, can't continue..." && exit 1
done
TLDR_GIT="https://github.com/tldr-pages/tldr.git"
TLDR_SOURCE="source: $TLDR_GIT"
TLDR_SYNTAX="syntax: markdown"
TLDR_TEMP_PREFIX=$(basename "$0")
TLDR_TEMP_DIR="/tmp/cheat-tldr-$(rnd)"
# If there's no .git, clone the folder
if [ ! -d "$TLDR_TEMP_DIR/.git" ]; then
msg_run "Starting to clone $TLDR_GIT"
git clone --depth 1 --single-branch -q "$TLDR_GIT" "$TLDR_TEMP_DIR" \
&& msg_done "Cloned $TLDR_GIT"
fi
# Fetch the destination directory from cheat defined directories.
TLDR_CHEAT_DEST="$(cheat -d | grep tldr | head -1 | awk '{print $2}')"
[ "$TLDR_CHEAT_DEST" = "" ] \
&& msg_err "cheat doesn't know about the destination" \
&& exit 1
if [ ! -d "$TLDR_CHEAT_DEST" ]; then
mkdir -p "$TLDR_CHEAT_DEST"
fi
for d in "$TLDR_TEMP_DIR"/pages/*; do
DIRNAME=$(basename "$d")
# echo "-> $DIRNAME ($d)"
SECTION_DIR="${TLDR_CHEAT_DEST}/$DIRNAME"
TLDR_TAGS="tags: [$DIRNAME]"
if [ ! -d "$SECTION_DIR" ]; then
mkdir -p "$SECTION_DIR"
fi
for FILE in $d/*.md; do
BASENAME=$(basename "$FILE" .md)
FILENAME="${BASENAME%%.*}"
# echo "-> $FILE = $FILENAME"
TLDR_FILE="$SECTION_DIR/${FILENAME}"
# echo "-> dest: $TLDR_FILE"
if [ ! -f "$TLDR_FILE" ]; then
cp "$FILE" "$TLDR_FILE" && msg_run "$TLDR_FILE"
fi
if [ -f "$TLDR_FILE" ] && [ '---' != "$(head -1 < "$TLDR_FILE")" ]; then
echo -e "---\n$TLDR_SYNTAX\n$TLDR_TAGS\n$TLDR_SOURCE\n---\n$(cat "$TLDR_FILE")" > "$TLDR_FILE"
fi
done
done
# Cleanup
if [ -d "$TLDR_TEMP_DIR" ]; then
rm -rf "$TLDR_TEMP_DIR"
fi

View File

@@ -1,19 +1,23 @@
#!/bin/bash
#!/usr/bin/env bash
# Install PHP Package Manager Composer
#
# shellcheck source="shared.sh"
source "$HOME/.dotfiles/scripts/shared.sh"
if command -v php &> /dev/null; then
EXPECTED_CHECKSUM="$(php -r 'copy("https://composer.github.io/installer.sig", "php://stdout");')"
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
ACTUAL_CHECKSUM="$(php -r "echo hash_file('sha384', 'composer-setup.php');")"
! have php && msg_err "PHP Not Available, cannot install composer" && exit 0
if [ "$EXPECTED_CHECKSUM" != "$ACTUAL_CHECKSUM" ]; then
echo >&2 'ERROR: Invalid installer checksum'
rm composer-setup.php
exit 1
fi
EXPECTED_CHECKSUM="$(php -r 'copy("https://composer.github.io/installer.sig", "php://stdout");')"
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
ACTUAL_CHECKSUM="$(php -r "echo hash_file('sha384', 'composer-setup.php');")"
php composer-setup.php --quiet
RESULT=$?
if [ "$EXPECTED_CHECKSUM" != "$ACTUAL_CHECKSUM" ]; then
echo >&2 'ERROR: Invalid installer checksum'
rm composer-setup.php
mv composer.phar ~/.local/bin/composer
exit $RESULT
exit 1
fi
php composer-setup.php --quiet
RESULT=$?
rm composer-setup.php
mv composer.phar ~/.local/bin/composer
exit $RESULT

16
scripts/install-fzf.sh Executable file
View File

@@ -0,0 +1,16 @@
#!/usr/bin/env bash
#
# Install fzf
#
# shellcheck source=shared.sh
source "$HOME/.dotfiles/scripts/shared.sh"
FZF_GIT="https://github.com/junegunn/fzf.git"
FZF_PATH="${XDG_CONFIG_HOME}/fzf"
if [ ! -d "$FZF_PATH" ]; then
git clone --depth 1 "$FZF_GIT" "$FZF_PATH"
"$FZF_PATH/install" --xdg --all --no-update-rc
else
msg_done "fzf ($FZF_PATH/) already installed"
fi

View File

@@ -4,41 +4,41 @@
# shellcheck source="shared.sh"
source "$HOME/.dotfiles/scripts/shared.sh"
if ! command -v gh &> /dev/null; then
msg_run "gh (GitHub Client) could not be found, please install it first"
else
extensions=(
# GitHub CLI extension for generating a report on repository dependencies.
andyfeller/gh-dependency-report
# GitHub CLI extension to generate montage from GitHub user avatars
andyfeller/gh-montage
# An opinionated GitHub Cli extension for creating
# changelogs that adhere to the keep a changelog specification.
chelnak/gh-changelog
# Safely deletes local branches with no upstream and no un-pushed commits
davidraviv/gh-clean-branches
# A beautiful CLI dashboard for GitHub 🚀
dlvhdr/gh-dash
# A github-cli extension script to clone all repositories
# in an organization, optionally filtering by topic.
matt-bartel/gh-clone-org
# being an extension to view the overall health of
# an organization's use of actions
rsese/gh-actions-status
)
! have gh \
&& msg_err "gh (GitHub Client) could not be found, please install it first" \
&& exit 0
msg "Starting to install GitHub CLI extensions..."
extensions=(
# GitHub CLI extension for generating a report on repository dependencies.
andyfeller/gh-dependency-report
# GitHub CLI extension to generate montage from GitHub user avatars
andyfeller/gh-montage
# An opinionated GitHub Cli extension for creating
# changelogs that adhere to the keep a changelog specification.
chelnak/gh-changelog
# Safely deletes local branches with no upstream and no un-pushed commits
davidraviv/gh-clean-branches
# A beautiful CLI dashboard for GitHub 🚀
dlvhdr/gh-dash
# A github-cli extension script to clone all repositories
# in an organization, optionally filtering by topic.
matt-bartel/gh-clone-org
# being an extension to view the overall health of
# an organization's use of actions
rsese/gh-actions-status
)
for ext in "${extensions[@]}"; do
# Trim spaces
ext=${ext// /}
# Skip comments
if [[ ${ext:0:1} == "#" ]]; then continue; fi
msg "Starting to install GitHub CLI extensions..."
msg_run "Installing $ext"
gh extensions install "$ext"
echo ""
done
for ext in "${extensions[@]}"; do
# Trim spaces
ext=${ext// /}
# Skip comments
if [[ ${ext:0:1} == "#" ]]; then continue; fi
msg_ok "Done"
fi
msg_run "Installing $ext"
gh extensions install "$ext"
echo ""
done
msg_ok "Done"

View File

@@ -4,29 +4,36 @@
# shellcheck source=shared.sh
source "$HOME/.dotfiles/scripts/shared.sh"
if ! command -v go &> /dev/null; then
msg "go hasn't been installed yet."
else
packages=(
# sysadmin/scripting utilities, distributed as a single binary
github.com/skx/sysbox@latest
github.com/dotzero/git-profile@latest
github.com/google/yamlfmt/cmd/yamlfmt@latest
github.com/ericchiang/pup@latest
github.com/suntong/html2md@latest
)
! have go && msg "go hasn't been installed yet." && exit 0
for pkg in "${packages[@]}"; do
# Trim spaces
pkg=${pkg// /}
# Skip comments
if [[ ${pkg:0:1} == "#" ]]; then continue; fi
packages=(
# sysadmin/scripting utilities, distributed as a single binary
github.com/skx/sysbox@latest
# Git Profile allows you to switch between user profiles in git repos
github.com/dotzero/git-profile@latest
# An extensible command line tool or library to format yaml files.
github.com/google/yamlfmt/cmd/yamlfmt@latest
# Parsing HTML at the command line
github.com/ericchiang/pup@latest
# HTML to Markdown converter
github.com/suntong/html2md@latest
# cheat allows you to create and view interactive cheatsheets on the cli.
github.com/cheat/cheat/cmd/cheat@latest
# Render markdown on the CLI, with pizzazz! 💅
github.com/charmbracelet/glow@latest
# Static checker for GitHub Actions workflow files
github.com/rhysd/actionlint/cmd/actionlint@latest
)
msg_run "Installing go package:" "$pkg"
go install "$pkg"
echo ""
done
for pkg in "${packages[@]}"; do
# Trim spaces
pkg=${pkg// /}
# Skip comments
if [[ ${pkg:0:1} == "#" ]]; then continue; fi
msg_ok "Done"
msg_run "Installing go package:" "$pkg"
go install "$pkg"
echo ""
done
fi
msg_ok "Done"

25
scripts/install-neofetch.sh Executable file
View File

@@ -0,0 +1,25 @@
#!/usr/bin/env bash
#
# Install neofetch from source
#
# shellcheck source=shared.sh
source "$HOME/.dotfiles/scripts/shared.sh"
NEOFETCH_VERSION="7.1.0"
NEOFETCH_REPO="https://github.com/dylanaraps/neofetch"
NEOFETCH_URL="${NEOFETCH_REPO}/archive/refs/tags/${NEOFETCH_VERSION}.tar.gz"
NEOFETCH_TEMP="/tmp/neofetch"
NEOFETCH_INSTALL_PREFIX="$HOME/.local"
have neofetch || {
LC_ALL=C
mkdir -p "$NEOFETCH_TEMP" "$NEOFETCH_INSTALL_PREFIX"
curl -L "$NEOFETCH_URL" > "$NEOFETCH_TEMP.tar.gz"
tar zxvf "$NEOFETCH_TEMP.tar.gz" --directory="$NEOFETCH_TEMP"
cd "$NEOFETCH_TEMP/neofetch-$NEOFETCH_VERSION" \
&& make PREFIX="${NEOFETCH_INSTALL_PREFIX}" install \
&& rm -rf "$NEOFETCH_TEMP*" \
&& msg_yay "neofetch installed!"
}

View File

@@ -4,35 +4,38 @@
# shellcheck source=shared.sh
source "$HOME/.dotfiles/scripts/shared.sh"
if ! command -v npm &> /dev/null; then
msg_err "npm could not be found."
else
packages=(
# This is a tool to check if your files consider your .editorconfig rules.
"editorconfig-checker"
# Node module to create a release or a changelog from
# a tag and uses issues or commits to creating the release notes.
"github-release-notes"
"neovim"
"prettier"
"@bchatard/alfred-jetbrains"
"@johnnymorganz/stylua-bin"
"js-debug"
"stylelint-lsp"
"blade-formatter"
"@loopback/cli"
"corepack"
"standardjs"
)
! have npm && msg_err "npm could not be found." && exit 0
for pkg in "${packages[@]}"; do
# Trim spaces
pkg=${pkg// /}
# Skip comments
if [[ ${pkg:0:1} == "#" ]]; then continue; fi
packages=(
# This is a tool to check if your files consider your .editorconfig rules.
"editorconfig-checker"
# Node module to create a release or a changelog from
# a tag and uses issues or commits to creating the release notes.
"github-release-notes"
"neovim"
"corepack"
# CLI and local web plain text notetaking, bookmarking, and archiving
# with linking, tagging, filtering, search, Git versioning & syncing,
# Pandoc conversion, + more, in a single portable script.
"nb.sh"
)
for pkg in "${packages[@]}"; do
# Trim spaces
pkg=${pkg// /}
# Skip comments
if [[ ${pkg:0:1} == "#" ]]; then continue; fi
if [[ $(npm ls -g -p "$pkg") != "" ]]; then
msg_run_done "$pkg" "already installed"
else
msg_run "Installing npm package:" "$pkg"
npm install -g --no-fund --no-progress --no-timing "$pkg"
echo ""
done
fi
fi
echo ""
done
msg_run "Upgrading all global packages"
npm -g --no-progress --no-timing --no-fund outdated
npm -g --no-timing --no-fund upgrade

View File

@@ -1,33 +1,35 @@
#!/bin/bash
#!/usr/bin/env bash
#
# Install ntfy
#
# shellcheck source=shared.sh
source "$HOME/.dotfiles/scripts/shared.sh"
set -e
if ! command -v ntfy &> /dev/null; then
case $(dfm check arch) in
Linux)
NTFY_ARCH="linux_$(arch)"
;;
Darwin)
NTFY_ARCH="macOS_all"
;;
esac
have ntfy && msg "ntfy already installed" && exit 0
NTFY_VERSION=2.2.0
NTFY_URL="https://github.com/binwiederhier/ntfy"
NTFY_DEST="ntfy_${NTFY_VERSION}_${NTFY_ARCH}"
case $(dfm check arch) in
Linux)
NTFY_ARCH="linux_$(arch)"
;;
Darwin)
NTFY_ARCH="macOS_all"
;;
esac
curl -L "$NTFY_URL/releases/download/v${NTFY_VERSION}/${NTFY_DEST}.tar.gz" \
> "${NTFY_DEST}.tar.gz"
tar zxvf "${NTFY_DEST}.tar.gz"
cp -a "${NTFY_DEST}/ntfy" ~/.local/bin/ntfy
mkdir -p ~/.config/ntfy
NTFY_VERSION=2.2.0
NTFY_URL="https://github.com/binwiederhier/ntfy"
NTFY_DEST="ntfy_${NTFY_VERSION}_${NTFY_ARCH}"
# copy config only if it does not exist
if [ ! -f "$HOME/.config/ntfy/client.yml" ]; then
cp "${NTFY_DEST}/client/client.yml" ~/.config/ntfy/client.yml
fi
curl -L "$NTFY_URL/releases/download/v${NTFY_VERSION}/${NTFY_DEST}.tar.gz" \
> "${NTFY_DEST}.tar.gz"
tar zxvf "${NTFY_DEST}.tar.gz"
cp -a "${NTFY_DEST}/ntfy" ~/.local/bin/ntfy
mkdir -p ~/.config/ntfy
rm -rf "${NTFY_DEST}" "${NTFY_DEST}.tar.gz"
else
echo "ntfy already installed"
# copy config only if it does not exist
if [ ! -f "$HOME/.config/ntfy/client.yml" ]; then
cp "${NTFY_DEST}/client/client.yml" ~/.config/ntfy/client.yml
fi
rm -rf "${NTFY_DEST}" "${NTFY_DEST}.tar.gz"

View File

@@ -4,6 +4,12 @@
# Ismo Vuorinen <https://github.com/ivuorinen> 2018
#
[ "$(uname)" != "Darwin" ] && echo "Not a macOS system" && exit 0
! have xcode-select \
&& msg_err "xcode-select could not be found, skipping" \
&& exit 0
# Ask for the administrator password upfront
sudo -v
@@ -14,10 +20,12 @@ while true; do
kill -0 "$$" || exit
done 2> /dev/null &
# https://unix.stackexchange.com/a/408305
# check if user has git installed and propose to install if not installed
if [ "$(which git)" ]; then
echo "You already have git. Continuing..."
XCODE_TOOLS_PATH=$(xcode-select -p)
XCODE_SWIFT_PATH="$XCODE_TOOLS_PATH/usr/bin/swift"
# Modified from https://unix.stackexchange.com/a/408305
if [ -a "$XCODE_SWIFT_PATH" ]; then
echo "You have swift from xcode-select. Continuing..."
else
XCODE_MESSAGE="$(
osascript -e \
@@ -32,7 +40,7 @@ else
fi
fi
until [ "$(which git)" ]; do
until [ -f "$XCODE_SWIFT_PATH" ]; do
echo -n "."
sleep 1
done

View File

@@ -1,4 +1,9 @@
#!/usr/bin/env bash
#
# Install z
#
# shellcheck source=shared.sh
source "$HOME/.dotfiles/scripts/shared.sh"
Z_GIT_PATH="https://github.com/rupa/z.git"
Z_BIN_PATH="$XDG_BIN_HOME/z"
@@ -6,5 +11,5 @@ Z_BIN_PATH="$XDG_BIN_HOME/z"
if [ ! -d "$Z_BIN_PATH" ]; then
git clone "$Z_GIT_PATH" "$Z_BIN_PATH"
else
echo "z ($Z_BIN_PATH/) already installed"
msg_done "z ($Z_BIN_PATH/) already installed"
fi

Some files were not shown because too many files have changed in this diff Show More