Commit 226d7c3a authored by Mickaël Desfrênes's avatar Mickaël Desfrênes
Browse files

add vhs tapes

parent e0492882
Loading
Loading
Loading
Loading
+6 −0
Changes for LISEZMOI.md: 6 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -16,6 +16,12 @@ Ce dossier contient l'implémentation de `climax`, la CLI utilisée pour gérer

Voir [`commandes.md`](./commandes.md) pour la référence complète des commandes avec exemples.

![Exemple de la CLI Climax affichant la version, les informations du projet et les projets enregistrés](./docs/assets/climax-fr.gif)

L'enregistrement est généré avec [VHS](https://github.com/charmbracelet/vhs) depuis [`docs/vhs/climax-fr.tape`](./docs/vhs/climax-fr.tape).

Pour régénérer tous les enregistrements de la documentation, lancez `make docs-gifs` depuis la racine du dépôt avec Go, Bash, VHS, `ttyd` et `ffmpeg` dans votre `PATH`. Utilisez un Chrome/Chromium récent dans votre `PATH` si le navigateur téléchargé automatiquement par VHS se bloque. Les tapes utilisent une configuration de démonstration temporaire et un `CLIMAX_HOME` isolé ; aucune installation du runtime MaX n'est nécessaire.

## Périmètre et notes

- Les données de registre des projets sont stockées dans `~/.climax/projects.json`.
+5 −1
Changes for Makefile: 5 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -32,8 +32,9 @@ CHECKSUM_ARTIFACTS := \
RELEASE_CHECKSUMS := $(addsuffix .checksum.txt,$(CHECKSUM_ARTIFACTS))
RELEASE_UPLOAD_FILES := $(RELEASE_ARTIFACTS) $(RELEASE_CHECKSUMS)
GO_SOURCES := $(filter-out %_test.go,$(wildcard *.go))
VHS_TAPES ?= $(wildcard docs/vhs/*.tape)

.PHONY: build test format installer-macos installer-windows installer-deb release-checksums release-upload clean help
.PHONY: build test format docs-gifs installer-macos installer-windows installer-deb release-checksums release-upload clean help

build: ## Build cross-platform binaries into dist (linux/amd64, darwin/arm64, windows/amd64)
	mkdir -p $(DIST_DIR)
@@ -48,6 +49,9 @@ test: ## Run Go tests (including main_test.go explicitly)
format: ## Format Go sources
	gofmt -w *.go

docs-gifs: ## Regenerate documentation terminal recordings (requires VHS)
	@set -e; for tape in $(VHS_TAPES); do vhs "$$tape"; done

installer-macos: ## Build an unsigned macOS pkg installer (.pkg) for arm64 using pkgbuild
	mkdir -p $(DIST_DIR)
	CGO_ENABLED=0 GOOS=darwin GOARCH=arm64 go build $(GO_FLAGS) -o $(MACOS_EXE) .
+5 −0
Changes for README.md: 5 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -16,6 +16,11 @@ This directory contains the implementation of `climax`, the CLI used to manage [

See [`commands.md`](./commands.md) for the full command reference with examples.

![Climax CLI example showing version, project information, and registered projects](./docs/assets/climax-en.gif)

The recording is generated with [VHS](https://github.com/charmbracelet/vhs) from [`docs/vhs/climax-en.tape`](./docs/vhs/climax-en.tape).

To regenerate all documentation recordings, run `make docs-gifs` from the repository root with Go, Bash, VHS, `ttyd`, and `ffmpeg` on your `PATH`. Use a current Chrome/Chromium on your `PATH` if VHS's automatically downloaded browser stalls. The tapes use a disposable configuration fixture and an isolated `CLIMAX_HOME`; no MaX runtime installation is needed.

## Scope and Notes

+28 −0
Changes for commandes.md: 28 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -11,6 +11,8 @@ Options globales :
  sur `CLIMAX_LANG` et `LANG`.
- `--help` : affiche l'aide climax pour les commandes ordinaires.

Les enregistrements ci-dessous exécutent la CLI réelle avec des fichiers de configuration et de bundles de démonstration. Consultez [les sources VHS et les instructions de régénération](./docs/vhs/README.md) pour les reproduire avec un registre de projets isolé.

## new

Crée un nouveau projet MaX, ou initialise le dossier courant.
@@ -61,6 +63,12 @@ Options :

Démarre la stack HTTP/BaseX de MaX.

Consultez les options du serveur avec `start --help` :

![Aide de climax start présentant les options HTTP, BaseX et le port d'arrêt](./docs/assets/start-help-fr.gif)

[Source VHS](./docs/vhs/start-help-fr.tape)

- Démarre le projet courant avec les ports configurés :

```sh
@@ -126,6 +134,10 @@ Options :
Affiche la configuration du projet MaX. La sortie par défaut est un tableau
stylisé.

![Climax info affichant la même configuration de démonstration en tableau puis en JSON](./docs/assets/info-json-fr.gif)

[Source VHS](./docs/vhs/info-json-fr.tape)

- Affiche la configuration du projet courant sous forme de tableau stylisé :

```sh
@@ -192,6 +204,10 @@ Un bundle est un paquet d'extension MaX qui peut ajouter des templates, des
fichiers statiques, des scripts ou d'autres ressources au projet.
Le tableau indique aussi si chaque bundle est un bundle de vocabulaire.

![Climax bundles-list affichant les bundles configurés et la détection du vocabulaire](./docs/assets/bundles-list-fr.gif)

[Source VHS](./docs/vhs/bundles-list-fr.tape)

- Liste les bundles du projet courant :

```sh
@@ -483,6 +499,12 @@ Options :
Liste les fichiers de templates du bundle de vocabulaire configuré. La sortie
est une liste simple de chemins, une ligne par chemin.

Inspectez des templates et ressources statiques de démonstration du bundle de vocabulaire configuré :

![Climax templates-list et static-list affichant les chemins simples des fichiers de démonstration](./docs/assets/assets-fr.gif)

[Source VHS](./docs/vhs/assets-fr.tape)

- Liste les fichiers de templates du projet courant :

```sh
@@ -504,6 +526,8 @@ Options :
Liste les fichiers statiques du bundle de vocabulaire configuré. La sortie est
une liste simple de chemins, une ligne par chemin.

L'[enregistrement ci-dessus](#templates-list) illustre les deux commandes de liste de ressources.

- Liste les fichiers statiques du projet courant :

```sh
@@ -525,6 +549,10 @@ Options :
Liste les projets connus de climax. La sortie par défaut est un tableau
stylisé.

![Climax projects affichant le projet de démonstration enregistré en tableau puis en JSON](./docs/assets/projects-json-fr.gif)

[Source VHS](./docs/vhs/projects-json-fr.tape)

- Liste les projets connus sous forme de tableau stylisé :

```sh
+28 −0
Changes for commands.md: 28 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -10,6 +10,8 @@ Global options:
  `LANG`.
- `--help`: show climax help for normal commands.

The recordings below run the real CLI against sample configuration and bundle files. See [the VHS sources and regeneration instructions](./docs/vhs/README.md) to reproduce them with an isolated project registry.

## new

Create a new MaX project, or initialize the current directory.
@@ -60,6 +62,12 @@ Options:

Start the MaX HTTP/BaseX stack.

Preview the server options with `start --help`:

![Climax start help showing HTTP, BaseX, and stop-port options](./docs/assets/start-help-en.gif)

[VHS source](./docs/vhs/start-help-en.tape)

- Start the current project with the configured ports:

```sh
@@ -124,6 +132,10 @@ Options:

Show MaX project configuration. The default output is a styled table.

![Climax info showing the same sample configuration as a table and JSON](./docs/assets/info-json-en.gif)

[VHS source](./docs/vhs/info-json-en.tape)

- Show the current project's configuration as a styled table:

```sh
@@ -188,6 +200,10 @@ A bundle is a MaX extension package that can add templates, static assets,
scripts, or other project resources.
The table also indicates whether each bundle is a vocabulary bundle.

![Climax bundles-list showing configured bundles and vocabulary detection](./docs/assets/bundles-list-en.gif)

[VHS source](./docs/vhs/bundles-list-en.tape)

- List bundles for the current project:

```sh
@@ -476,6 +492,12 @@ Options:
List template files from the configured vocabulary bundle. Output is plain
line-by-line paths.

Inspect sample templates and static assets from the configured vocabulary bundle:

![Climax templates-list and static-list showing plain paths from sample bundle files](./docs/assets/assets-en.gif)

[VHS source](./docs/vhs/assets-en.tape)

- List template files for the current project:

```sh
@@ -497,6 +519,8 @@ Options:
List static files from the configured vocabulary bundle. Output is plain
line-by-line paths.

The [recording above](#templates-list) demonstrates both asset-list commands.

- List static files for the current project:

```sh
@@ -517,6 +541,10 @@ Options:

List projects known to climax. The default output is a styled table.

![Climax projects showing the registered sample project as a table and JSON](./docs/assets/projects-json-en.gif)

[VHS source](./docs/vhs/projects-json-en.tape)

- List known projects as a styled table:

```sh
Loading