Development¶
The development environment requires these tools:
Clone this repo and enter the folder.
Run task help to list the commands of this project.
Testing¶
Tests are located in the tests/ folder. Each test is a standalone executable bash script that validates library commands.
Test scripts must be executable (chmod +x) to be picked up by the test runner.
Structure¶
Each test script follows this pattern:
- Create a temporary directory and clean up on exit with
trap - Source the library scripts from
bin/ - Run commands and verify results using assertion helpers (e.g.
assert_equals,assert_contains) - Report a pass/fail summary and exit with a non-zero code on failure
Run tests¶
Run all executable test scripts:
This executes every file in tests/ that has the executable bit set, prints the results, and reports a summary of passed and failed tests.
Style¶
The bash scripts follow the Bash Style Guide | ysap.sh. Have a look at the AGENTS.md for details on the applied styling.
Naming¶
The naming of functions is important. There are basically two styles:
- Action + Object
- Object + Action
The Taskfile functions use the first style. The name of the function starts with an action followed by an object. The object name can be singular or plural.
Examples for actions: activate, install, dev, develop, init, build, start, update, remove, delete, enable, disable, template, convert, create, edit, change, get, set, patch, fetch, generate, push, pull, import, export, list, publish, release, test, setup, prepare, restart, stop, store, restore, translate, upgrade, zip, visualize, sync, switch, run, reset, load, dump, checkout, commit, drop, deploy, handle, trigger, render, lint, uninstall, split, parse, fix, refactor, transform, cat, ls, rm, serve, help, show, filter, login, logout, encrypt, decrypt, upload, download, analyse, transpile, compile, minify, copy
Examples for objects: env, venv, submodule, container, database, snippet, model, module, repo, mail, doc, dependency, view, user, vault, file, host, node, log, password, hash, script, requirement, part, component, system, workspace, image, process, state, platform, dir, folder, readme, overview, lang, level, request, response, result, worker, server, proxy, workflow, volume, network, package, field, value, secret, chart, node, edge, function, method, firewall, html, css, image, svg, style, query, native, group, notebook
Objects can be tools: odoo, vupress, nodejs, zsh, bash, fish, podman, kind, minikube, helm, nvim, docker, podman, rust, python, tmux, vim, helix, system, git, pass, llm, sql, dotenv, javascript, vue, vite, astro, typescript, turbo, pnpm, eslint, jenkins, k8s, nextcloud, postgres, metabase, ansible, prometheus, grafana, hugo, deno, bun, babel, panda, gulp, grunt, electron, react, express, mongodb, angular, ionic, meteor, webpack, bower, jupyter