Initial commit

This commit is contained in:
2025-07-21 02:29:06 +03:00
parent d4be866383
commit e72949d3f8
27 changed files with 1608 additions and 190 deletions

58
Justfile Normal file
View File

@@ -0,0 +1,58 @@
# Project automation for 'a' CLI wrapper for age encryption
# Set the shell to bash for compatibility
set shell := ["bash", "-cu"]
# Variables
BINARY := "a"
# Default: show help
default:
@just --list
# Format all code (Go, YAML, Markdown)
format:
gofmt -s -w .
goimports -w .
yamlfmt -c .yamlfmt.yml .
markdownlint -c .markdownlint.json --fix '**/*.md'
# Lint Go code and configs
lint:
golangci-lint run
yamllint -c .yamllint.yml .
markdownlint -c .markdownlint.json '**/*.md'
# Run all tests
test:
go test -v ./...
# Build the binary
build:
go build -o {{ BINARY }} .
# Run GoReleaser (dry-run by default)
release:
goreleaser release --clean --skip-publish --snapshot
# Run GoReleaser for actual release (requires env vars)
release-publish:
goreleaser release --clean
# Run pre-commit hooks on all files
precommit:
pre-commit run --all-files
# Update Go modules
tidy:
go mod tidy
# Clean build artifacts
clean:
rm -rf {{ BINARY }} dist/ coverage* *.log
# Show help
help:
@echo "Available commands:"
@just --list