diff --git a/.claude/skills/pr-title-description/SKILL.md b/.claude/skills/pr-title-description/SKILL.md new file mode 100644 index 0000000..4c589e5 --- /dev/null +++ b/.claude/skills/pr-title-description/SKILL.md @@ -0,0 +1,49 @@ +--- +name: pr-title-description +description: Write or update a PR title and description for the current branch, matching the style of recent PRs. +disable-model-invocation: true +user-invocable: true +--- + + + +# `pr-title-description` + +Write (or update) the title and description +for the pull request on the current branch. + + + +## Steps + + + +1. Identify the current branch and its PR + (if one exists) using + `gh pr list --head `. + +1. Get the full diff against `main`: + `git diff main..HEAD` and + `git log main..HEAD --oneline`. + +1. Fetch the body of the 3 most recent merged + PRs to match their style: + + ```sh + gh pr list --state merged --limit 3 \ + --json number,title,body + ``` + +1. Write a concise PR description that mirrors + the format and tone of those recent PRs. + Typically this means a `# Changes` section + with a numbered list. Add a `# Background` + section only if the changes need non-obvious + context. + +1. If a PR already exists for the branch, update + it with `gh pr edit --body "..."`. + Otherwise, report the description so the user + can create the PR. + +1. Show the user the PR URL when done. diff --git a/.gitignore b/.gitignore index e43b0f9..078609e 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ .DS_Store +deploy +target diff --git a/Cargo.toml b/Cargo.toml new file mode 100644 index 0000000..fe61489 --- /dev/null +++ b/Cargo.toml @@ -0,0 +1,10 @@ +[workspace] +members = [] + +[workspace.dependencies] +mollusk-svm = "0.10.3" +pinocchio = "0.10.2" + +[workspace.package] +edition = "2024" +version = "0.1.0" diff --git a/Makefile b/Makefile index 56bbb52..0f10aee 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,6 @@ # cspell:word vite .PHONY: all +.PHONY: asm .PHONY: clean .PHONY: test @@ -7,21 +8,25 @@ all: docs-prettier pre-commit-lint clean: test: +# Assemble the program. +asm: + sbpf build --arch v3 --deploy-dir deploy + # Build and serve docs locally for development. docs-dev: - cd docs \ + cd docs && npm install \ && rm -rf .vitepress/cache .vitepress/dist node_modules/.vite \ - && npx vitepress dev + && npx vitepress dev --open # Format docs with Prettier. docs-prettier: - cd docs && npx prettier --write . + cd docs && npm install && npx prettier --write . # Build and serve docs locally in production mode. docs-prod: cd docs \ && rm -rf .vitepress/cache .vitepress/dist node_modules/.vite \ && npm ci \ && npx vitepress build \ - && npx vitepress preview + && npx vitepress preview --open # Run pre-commit lint checks on all files. pre-commit-lint: pre-commit run --config cfg/pre-commit/lint.yml --all-files diff --git a/cfg/dictionary.txt b/cfg/dictionary.txt index 19186c8..24e63fa 100644 --- a/cfg/dictionary.txt +++ b/cfg/dictionary.txt @@ -1,6 +1,9 @@ dasmac dropset +insn katex +ldxb +ldxdw sbpf solana vitepress diff --git a/cfg/pre-commit/lint.yml b/cfg/pre-commit/lint.yml index 5979313..3920335 100644 --- a/cfg/pre-commit/lint.yml +++ b/cfg/pre-commit/lint.yml @@ -71,7 +71,10 @@ repos: repo: 'https://github.com/checkmake/checkmake.git' rev: 'v0.3.2' - hooks: - - id: 'chktex' + - args: + - '-n1' # Allow command terminated with space, e.g. `\STATE foo`. + - '-n8' # Allow standard dash in ALGORITHM-NAME. + id: 'chktex' repo: 'https://github.com/randolf-scholz/latex-hooks' rev: 'v0.1.24' ... diff --git a/docs/.vitepress/buildAlgorithmIndex.js b/docs/.vitepress/buildAlgorithmIndex.js index e3673aa..b7a3b8a 100644 --- a/docs/.vitepress/buildAlgorithmIndex.js +++ b/docs/.vitepress/buildAlgorithmIndex.js @@ -47,7 +47,7 @@ export function buildAlgorithmIndex() { for (const fullPath of findMdFiles(SRC_DIR)) { const md = readFileSync(fullPath, "utf-8"); const relPath = relative(SRC_DIR, fullPath); - for (const match of md.matchAll(/ +