Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .agents/skills/rstack-cli-docs/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
name: rstack-cli-docs
description: Consult installed, version-matched Rstack docs only for user-facing `rs` command behavior, `rstack.config.*` semantics, or public `rstack` APIs. Do not use for purely internal implementation, tests, performance, or repository maintenance.
---

# Rstack CLI docs

Rstack CLI is the `rstack` package, exposed through the `rs` binaries. It provides one CLI, one
config file, and a consistent workflow for the Rstack JavaScript toolchain.

It covers web app, library, docs, test, lint, formatting, Git hook, and staged-file workflows.

## Read installed docs when this skill applies

When this skill applies, find and read the relevant Markdown documentation shipped with the installed `rstack` package.

Model knowledge can be outdated; the installed documentation is the source of truth for the project's Rstack version.

1. Start with `node_modules/rstack/docs/llms.txt`, then read only the linked pages relevant to the task before proposing or making changes.

2. For exact CLI flags and behavior, also run `rs -h` or `rs <command> -h` when supported.

If the bundled docs are not available at that path, locate the installed `rstack` package.

If they are still unavailable, verify that `rstack` is installed, and use CLI help plus the online [Rstack documentation](https://rstack.rs/) as a fallback.
1 change: 0 additions & 1 deletion .husky/pre-commit

This file was deleted.

11 changes: 0 additions & 11 deletions .prettierignore

This file was deleted.

4 changes: 0 additions & 4 deletions .prettierrc

This file was deleted.

1 change: 1 addition & 0 deletions .rstack/hooks/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
rs staged
2 changes: 1 addition & 1 deletion .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"recommendations": ["rstack.rslint", "esbenp.prettier-vscode"]
"recommendations": ["rstack.rstack"]
}
6 changes: 3 additions & 3 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@
"files.exclude": {
"**/.DS_Store": true
},
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.defaultFormatter": "rstack.rstack",
"mdx.validate.validateFileLinks": "ignore",
"[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
"editor.defaultFormatter": "rstack.rstack"
},
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
"editor.defaultFormatter": "rstack.rstack"
},
"cSpell.words": ["rstest"]
}
2 changes: 1 addition & 1 deletion AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ Top-level directories:

## Coding Conventions

- Formatting and linting: `Rslint` and `Prettier` are used (see `rslint.config.ts` and `.prettierrc`).
- Formatting, linting, staged-file tasks, and Git hooks use Rstack CLI (see `rstack.config.ts` and `.rstack/hooks/`).
- Default JS/TS quote style is single quotes.
- Line width is 100.
- Prefer minimal, example-focused changes. This repo is a collection of runnable examples; avoid refactors that reduce clarity.
Expand Down
24 changes: 6 additions & 18 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"name": "rstack-examples",
"version": "1.0.0",
"type": "module",
"description": "Repository for examples of rstack",
"license": "MIT",
"type": "module",
"scripts": {
"build": "pnpm run build:rspack && pnpm run build:rsbuild && pnpm run build:rspress && pnpm run build:rsdoctor && pnpm run build:rslib && pnpm run build:rstest",
"build:ci": "pnpm run build:rspack:ci && pnpm run build:rsbuild && pnpm run build:rspress && pnpm run build:rsdoctor && pnpm run build:rslib && pnpm run build:rstest",
Expand All @@ -15,30 +15,18 @@
"build:rspress": "pnpm --filter \"./rspress/**\" --stream build",
"build:rstest": "pnpm --filter \"./rstest/**\" --stream build",
"bump": "taze -l",
"lint": "rslint && prettier -c \"*.{json,jsonc,md,yml,yaml,ts}\" \".vscode/*.json\" \"{rspack,rsbuild,rspress,rsdoctor,rslib,rstest}/**/*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx,json,jsonc}\"",
"lint:write": "rslint --fix && prettier -w \"*.{json,jsonc,md,yml,yaml,ts}\" \".vscode/*.json\" \"{rspack,rsbuild,rspress,rsdoctor,rslib,rstest}/**/*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx,json,jsonc}\"",
"prepare": "husky",
"sort-package-json": "npx sort-package-json \"rspack/*/package.json\" \"rsbuild/*/package.json\" \"rspress/*/package.json\" \"rsdoctor/*/package.json\" \"rslib/*/package.json\" \"rstest/*/package.json\"",
"lint": "rs lint && rs fmt --check \"*.{json,jsonc,md,yml,yaml,ts}\" \".vscode/*.json\" \"{rspack,rsbuild,rspress,rsdoctor,rslib,rstest}/**/*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx,json,jsonc}\"",
"lint:write": "rs lint --fix && rs fmt \"*.{json,jsonc,md,yml,yaml,ts}\" \".vscode/*.json\" \"{rspack,rsbuild,rspress,rsdoctor,rslib,rstest}/**/*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx,json,jsonc}\"",
"prepare": "rs hooks",
"sort-package-json": "rs fmt \"rspack/*/package.json\" \"rsbuild/*/package.json\" \"rspress/*/package.json\" \"rsdoctor/*/package.json\" \"rslib/*/package.json\" \"rstest/*/package.json\"",
"test": "pnpm run test:rspack && pnpm run test:rstest",
"test:rspack": "pnpm --filter \"./rspack/**\" --stream test",
"test:rspack:eco-ci": "pnpm --filter \"./rspack/**\" --filter \"!./rspack/next-rspack-app-router\" --filter \"!./rspack/next-rspack-page-router\" --stream test",
"test:rstest": "pnpm --filter \"./rstest/**\" --stream test"
},
"lint-staged": {
"*.{js,ts,cjs,mjs,d.cts,d.mts,jsx,tsx}": [
"rslint --fix",
"prettier --write"
],
"*.{json,jsonc,md,mdx,yml,yaml,css,scss,less,html,vue}": [
"prettier --write"
]
},
"devDependencies": {
"@rslint/core": "^0.5.3",
"cross-env": "10.1.0",
"husky": "9.1.7",
"lint-staged": "16.4.0",
"prettier": "^3.8.3",
"rstack": "^0.7.2",
"taze": "^19.14.1"
},
"packageManager": "pnpm@10.34.1"
Expand Down
Loading
Loading