Initialize Crystal Porting Project
Use this skill to create the project baseline before real porting starts.
Inputs
Collect the minimum missing facts:
- upstream repository URL
- optional upstream subdirectory
- port name if it should differ from the repo name
- submodule path if it should differ from
vendor/<port-name> - whether to track
mainor pin a tag/commit
If no upstream checkout exists, explicitly ask whether the source should be added as a git submodule and where the source-of-truth lives.
Workflow
1. Add upstream checkout
Prefer a git submodule:
git submodule add -b main <source_url> vendor/<port-name>
Pin a tag or commit immediately if that is the agreed policy.
2. Ensure Crystal baseline tooling
shard.ymlshould includeamebaas a development dependency.- Add runtime dependencies only when parity work actually needs them.
- Reuse the shared
.ameba.ymlbaseline fromcrystal-forge-setup-project.
3. Ensure standard repo commands
Expose at least:
installupdateformatlinttestclean
For Crystal repos, prefer format, ameba, and crystal spec gates.
4. Add docs baseline
Create or update:
README.mdwith clear upstream attribution and pinned source revisionAGENTS.mdwith source-of-truth and contributor workflow- missing docs under
docs/
Do not replace useful local content wholesale; merge with it.
5. Bootstrap the parity plan
./scripts/ensure_parity_plan.sh . <source_path> <language> auto 0
This should establish plans/inventory/* from day one.
6. Verify setup
Run:
./scripts/verify_initialized_project_baseline.sh <project_root>
Completion
Initialization is complete when:
- upstream checkout exists at the agreed ref
- baseline quality gates are present
- README and AGENTS document the source of truth
plans/inventory/*exists- the baseline verifier passes
Route next
- implementation work:
porting-to-crystal - inventory and drift checks:
cross-language-crystal-parity - dependency selection:
find-crystal-shards