chore: add files from base_repo template

This commit is contained in:
Alexander Navarro 2025-02-10 13:16:28 -03:00
parent 5e8a72a714
commit fd44bd54a5
13 changed files with 151 additions and 31 deletions

View file

@ -1,14 +1,22 @@
set dotenv-load := true
export PATH := source_dir() + "/bin:" + source_dir() + "/scripts:" + env("PATH")
export AGEBOX_DEBUG := "0"
export AGEBOX_PUBLIC_KEYS := source_dir() + "/public_keys.txt"
fetch-deps:
.devfiles/scripts/fetch_gh_release.sh "slok/agebox" "agebox-linux-amd64" "agebox"
# Install agebox from the latest github realse
install-agebox:
curl -sSL "https://github.com/slok/agebox/releases/latest/download/agebox-linux-amd64" -o .devfiles/bin/agebox
chmod + x .devfiles/bin/agebox
[no-cd]
install-hooks:
cog install-hook --all
# Easy and simple file repository encryption tool based on Age.
[working-directory('..')]
agebox +ARGS="--help":
@.devfiles/bin/agebox {{ ARGS }}
@agebox {{ ARGS }}
# Encrypt the provided files, relative to project root.
encrypt +FILES: (agebox "encrypt " + FILES)
@ -26,7 +34,11 @@ decrypt-all: (agebox "decrypt --all --force")
reencrypt: (agebox "reencrypt")
# Show the content of an encrypted file to stdout.
peek +FILES: (agebox "cat " + FILES)
crypt-peek +FILES: (agebox "cat " + FILES)
# Validate that all tracked files are encrypted.
check:(agebox "validate --no-decrypt ")
crypt-check:(agebox "validate --no-decrypt ")
# Validate no credentials are pushed to git
leaks:
@gitleaks git --verbose --redact