Commit Graph

89 Commits

Author SHA1 Message Date
3eb9113546 hooks:pre-commit: Remove bashisms 2025-06-27 11:35:32 +02:00
e49e8a8ef0 hooks:pre-push: Put -E flag closer to --grep
Since they belong together.
2025-05-30 01:31:40 +02:00
136b56688a hooks:pre-push: Switch back to /bin/sh
It's not worth it to sacrifice the portability of the script for a bit
of integer-aid.
2025-05-30 01:31:17 +02:00
d4d21ceb1d hooks:pre-commit: Update to git's current version
The template has changed since I've added it.
2025-05-30 01:21:48 +02:00
4fba1bbf13 hooks:pre-commit: Fix symlink diff-filter
Renames are uninteresting for the link check. But we do care about
change in the type of the file.
2025-05-30 00:53:52 +02:00
a37080c948 hooks:pre-commit: Check for absolute links too
I don't really want any absolute links here.
2025-05-30 00:51:41 +02:00
88be20672a hooks:pre-commit: Fix non-tab indentation 2025-05-30 00:37:29 +02:00
f15ad722f4 vim:coc: Update and switch to release branch
This makes the installation via `yarn` obsolete (it was also outdated).
2025-03-10 16:21:39 +01:00
d23ed6a5cb meta:install: Do nothing if login shell is zsh already 2025-03-10 16:21:39 +01:00
9e7dd882cc meta:install: Don't link .config/.*
This makes problems since I added it and I don't even have files with
paths like these.
2025-03-10 15:48:31 +01:00
78e254251a hooks:pre-push: Don't use variables in format string
Link: https://www.shellcheck.net/wiki/SC2059
2025-03-04 12:55:50 +01:00
78464fdfb0 hooks:pre-push: Allow WIP commits on WIP branches 2025-03-03 18:27:46 +01:00
09a7497432 hooks:commit-msg: Visually separate error message
The warning is quickly overread when in the same paragraph as git's
normal output.
2024-10-16 14:53:39 +02:00
0a12cd58ed hooks:commit-msg: Source helpers directly from repo 2024-10-16 14:53:39 +02:00
a376ff7b78 hooks:commit-msg: Relax subject length limit to 60
There is no need to be that pedantic.
2024-10-16 14:53:27 +02:00
8b543f427c vim: Add en spellfile 2024-04-26 14:14:50 +02:00
80af6263a3 envrc: Kill shell when accessing repo from eduroam 2024-01-05 13:54:15 +01:00
84af8f96b3 meta:install: Fix typo in defaults directive 2023-07-10 18:54:52 +02:00
74b3d98b67 meta:envrc: Add modeline to set proper filetype 2023-01-27 00:06:34 +01:00
2afafef362 meta:envrc: Generate vim helptags when entering
Move the commands into a function, so that the function can be run in
the background.
2023-01-27 00:06:26 +01:00
d6e7f2d9f2 meta:install.conf: Fix git hooks symlink path 2022-10-21 01:01:18 +02:00
b82405a8c0 meta:commit-msg: Allow all characters in prefix
There is no real reason for a restriction.

Also merge the two character groups.
2022-10-21 00:49:17 +02:00
7666086dba *: Move die() into .local/bin/helpers.sh
The function `die` was redundantly implemented in various files.

Move the function into .local/bin/helpers.sh and source that where
previously implemented.

Also prepend the program's name to the message and always terminate the
message with a newline. The newline was previously needed for a small
but unnecessary hack that prevented the need of the `[ -z "$1" ]` test.
2022-09-22 14:39:20 +02:00
329a6e6eca meta:commit-msg: Allow subject to start with quote
See previous commit (d44931df8 "meta:envrc: `git fetch` in background").
2022-08-30 19:52:23 +02:00
95a1ecf984 meta:envrc: git fetch in background
Close/pipe std{in,out,err} as well as file descriptor 3 which is
apparently necessary for the subshell not to wait for the fetch to
finish.
2022-08-30 19:52:20 +02:00
9586533e61 meta:install.conf: Set defaults
When executing commands, enable std{out,err} and create parent
directories for links.
2022-07-12 21:26:48 +02:00
11c8345566 meta:install.conf: Ignore missing hidden files
The install script is broken since 4716b1cab3 ("meta:install: Link
hidden files in .config as well"), as dotbot will complain that there is
no hidden file to glob in `.config`.

Add `ignore-missing` so that the installation runs through while still
supporting hidden files in the future.
2022-07-12 21:22:46 +02:00
66a9ccfcc7 meta:install.conf: Link entire .git/hooks folder
Instead of linking the globs of meta/git/hooks, create a link for the
entire folder. This way new hooks work automagically.
2022-07-12 21:22:46 +02:00
b9ac80551c meta:hooks:pre-push: Format printout
Forgot some newlines.
2022-07-12 21:00:13 +02:00
e40ee88520 meta:hooks:pre-push: Refactor if-condition 2022-07-12 21:00:13 +02:00
45cb607385 meta:hooks:pre-push: Adjust to more concise style
Adjust the sample code from git to a more concise coding style, placing
{do,then} on the same line and using `[` instead of `test`.
2022-07-12 21:00:13 +02:00
ee6153734a meta:hooks:pre-push: Extend pattern for autosquash
Extend the grep pattern for commits starting with `{squash,fixup}!`.
2022-07-12 21:00:12 +02:00
f4fe825ce7 meta:git:hooks: Add pre-push template 2022-07-12 21:00:12 +02:00
ecd66726d2 meta:install: Generate vim helptags
Generate all helptags after vim's plugins were pulled.
2022-07-12 21:00:06 +02:00
cc61d2ff45 meta:install.conf: Setup python3 support in neovim 2022-07-12 21:00:06 +02:00
c1cfd29420 meta:install: Update mandb 2022-07-12 21:00:02 +02:00
891cb063e6 git:filter-repo: Build manpage on installation 2022-07-12 21:00:02 +02:00
6c802cc70f meta:hooks:pre-commit: Check for broken symlinks
Check that added/moved symlinks are not broken.
2022-07-12 21:00:02 +02:00
40416ebd9c *: Move third-party plugins into .local/share/
Move all submodules that were under .config/ into .local/share/ (alias
XDG_DATA_HOME). I got convinced that they feel out of place in .config/.

Instead of updating the paths from which they are sourced (e.g.
`TMUX_PLUGIN_MANAGER_PATH` or `packpath`), keep a symlink in the old
location that points to the new one. This has the benefit that
everything related to one program remains mostly accessible from the
same place instead of spreading everything out.

I am still unsure if I really like the new location as I affiliate user
**data** more with something that has to be backed up as it is
non-recreatable. And moving them out of .config/ had the reasoning that
they are not my config files but rather data from the internet that
could be retrieved when deleting. But using XDG_CACHE_HOME seems
unreasonable as well.
We'll see.

Move the fzf-repo from ./local/bin/ to .local/share/.

Update all relative symlinks' (e.g. fzf) targets.
2022-07-12 21:00:01 +02:00
1dbd24fcf9 meta:install: Update meta/archive description
Meanwhile meta/archive backups everything that is going to be replaced
with links, not only the content of .config/
2022-07-12 21:00:00 +02:00
b96d32996b *: Wrap lines at 80 columns where appropriate
Wrap lines at 80 columns where appropriate and I had the energy to think
about how/where to wrap.

There are still lines longer than that, which I plan to wrap in the
future. But that is enough for now.
2022-06-23 23:59:00 +02:00
f620e6d577 meta:hooks:commit-msg: Improve body recognition
Before, the commit-msg hook would not catch too long lines when
squashing commits, as the provided message starts immediately with a
commented line.

Instead of simply using all lines until the first comment, use all lines
until git's cut-line and remove all commented lines in between.

Do not hard-code git's commentary character but rather use
`core.commentChar`. `auto` is depending of the context interpreted as
'any character' or `#`.
2022-06-23 23:58:34 +02:00
7126a40c71 meta:hooks:commit-msg: Allow {fixup,squash} prefix
Allow the "fixup! " and "squash! " prefix' created by the
`--fixup`/`--squash` flags to `git-commit`
2022-06-23 23:58:33 +02:00
1497fe3ed4 meta:install: Link all files in .ssh/
Link all files on installation, even though currently there is only the
one config file. This way potential new files in `.ssh/` do not have to
be tracked manually.
2022-03-31 03:23:15 +02:00
33faf7f25e ssh: Add config 2022-03-31 03:20:59 +02:00
4ba60da72c meta: Add envrc for direnv
Fetch all git remotes automatically when entering the repository.
2022-03-31 03:17:04 +02:00
41b1643a70 meta:install: Do not link .local/bin/fzf-repo
Only the executable (/the symlink to it) is interesting in .local/bin
2022-03-31 03:14:29 +02:00
4716b1cab3 meta:install: Link hidden files in .config as well
The globbing does not match hidden files without specifying the dot at
the beginning.
2022-03-31 03:12:09 +02:00
82a4dc8e19 meta:archive: Use stderr for log messages 2022-03-31 03:11:32 +02:00
98b33cc615 meta:archive: Get link targets by parsing config
Instead of only archiving the ~/.config/*, now parse `install.conf.yaml`
and extract the link targets dynamically.
2022-03-31 03:09:30 +02:00