Skip to content

Commit 0c33b3b

Browse files
authored
docs: improve readmes (#13)
1 parent 3e64200 commit 0c33b3b

5 files changed

Lines changed: 66 additions & 38 deletions

File tree

README.md

Lines changed: 55 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,52 +1,80 @@
1-
# ICP Recipes
1+
# ICP CLI Recipes
22

3-
A comprehensive repository of Internet Computer (IC) canister build recipes using Handlebars templates.
3+
[![License](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](./LICENSE)
44

5-
## Overview
5+
Official build recipe templates for Internet Computer (ICP) canisters. Recipes provide standardized, reusable build configurations using Handlebars templates.
66

7-
This repository serves as the official Dfinity recipe repository for various ICP projects. Recipes are specified as Handlebars templates that generate build configurations for different types of IC canisters.
7+
## Available Recipes
88

9-
## Using Recipes
9+
| Recipe | Description |
10+
|--------|-------------|
11+
| [**Rust**](recipes/rust/README.md) | Build Rust canisters using Cargo with WASM target |
12+
| [**Motoko**](recipes/motoko/README.md) | Compile Motoko source code using the moc compiler |
13+
| [**Pre-built**](recipes/prebuilt/README.md) | Use pre-compiled WASM files with metadata injection |
14+
| [**Asset Canister**](recipes/asset-canister/README.md) | Deploy the official IC assets canister for frontend apps |
1015

11-
Recipes are consumed by referencing them in your `icp.yaml` file:
16+
## Quick Start
17+
18+
### Using a Recipe
19+
20+
Reference a recipe in your `icp.yaml` file:
1221

1322
```yaml
1423
canister:
15-
name: my-canister
24+
name: backend
1625
recipe:
17-
type: prebuilt
18-
url: https://github.com/dfinity/icp-recipes/releases/download/v1.0.0/recipes/prebuilt/recipe.yml
26+
type: "@dfinity/rust"
1927
configuration:
20-
path: ../dist/my-canister.wasm
21-
sha256: 17a05e36278cd04c7ae6d3d3226c136267b9df7525a0657521405e22ec96be7a
28+
package: my-canister
29+
shrink: true
2230
```
2331
24-
## Recipe Types
32+
### Recipe Naming Convention
33+
34+
Recipes follow the `@dfinity/<recipe-name>` naming pattern:
35+
- `@dfinity/rust` - Rust canister recipe
36+
- `@dfinity/motoko` - Motoko canister recipe
37+
- `@dfinity/pre-built` - Pre-built WASM recipe
38+
- `@dfinity/asset-canister` - Asset canister recipe
2539

26-
- **prebuilt**: For using pre-compiled WASM files
27-
- **assets**: For the official IC assets canister with asset synchronization
28-
- **motoko**: For compiling Motoko source code
29-
- **rust**: For building Rust canisters with Cargo
40+
### Using Specific Versions
41+
42+
To pin to a specific recipe version, append `@<version>` to the recipe type:
43+
44+
```yaml
45+
canister:
46+
name: backend
47+
recipe:
48+
type: "@dfinity/rust@v3.0.0"
49+
configuration:
50+
package: my-canister
51+
```
3052

31-
## Authoring Recipes
53+
Without a version specified, the latest stable version is used. View available versions in the [releases page](https://github.com/dfinity/icp-cli-recipes/releases).
3254

33-
See [Recipe Authoring Guide](docs/recipe-authoring.md) for guidelines on creating new recipes.
55+
## Releases
3456

35-
## Versioning
57+
Each recipe is versioned independently. View release history by recipe type:
58+
- [Rust releases](https://github.com/dfinity/icp-cli-recipes/releases?q=rust&expanded=true)
59+
- [Motoko releases](https://github.com/dfinity/icp-cli-recipes/releases?q=motoko&expanded=true)
60+
- [Pre-built releases](https://github.com/dfinity/icp-cli-recipes/releases?q=prebuilt&expanded=true)
61+
- [Asset Canister releases](https://github.com/dfinity/icp-cli-recipes/releases?q=asset-canister&expanded=true)
3662

37-
This repository follows semantic versioning. Each release publishes recipe artifacts that can be referenced by URL.
63+
Releases follow semantic versioning and include auto-generated changelogs.
3864

39-
## Future Roadmap
65+
## Documentation
4066

41-
- [ ] Recipe validation framework
42-
- [ ] Advanced testing infrastructure
43-
- [ ] Template repository for creating custom recipe libraries
44-
- [ ] Enhanced documentation with interactive examples
45-
- [ ] Community recipe submission process
67+
- [Recipe Authoring Guide](docs/recipe-authoring.md) - Create custom recipes
68+
- [Recipe README Template](docs/recipe-readme-template.md) - Documentation template
4669

4770
## Contributing
4871

49-
Contributions are welcome! Please see the [contribution guide](./.github/CONTRIBUTING.md) for more information.
72+
Contributions are welcome! Please see the [contribution guide](./.github/CONTRIBUTING.md) for details.
73+
74+
## Support
75+
76+
- Report issues: [GitHub Issues](https://github.com/dfinity/icp-cli-recipes/issues)
77+
- Questions & discussions: [DFINITY Developer Forum](https://forum.dfinity.org/)
5078

5179
## License
5280

recipes/asset-canister/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,6 @@ The assets canister automatically synchronizes files from your specified directo
106106

107107
Use this recipe for frontend applications that need to serve static assets and web content on the Internet Computer.
108108

109-
## Version History
109+
## Release History
110110

111-
- v1.0.0 - Initial release with assets canister support and synchronization
111+
See the [release history](https://github.com/dfinity/icp-cli-recipes/releases?q=asset-canister&expanded=true) for changelogs, version updates, and breaking changes.

recipes/motoko/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,10 +120,10 @@ my-project/
120120

121121
- [Rust Recipe](../rust/README.md) - For building Rust canisters
122122
- [Pre-built Recipe](../prebuilt/README.md) - For using pre-compiled WASM files
123-
- [Assets Recipe](../assets/README.md) - For frontend assets canister
123+
- [Asset Canister Recipe](../asset-canister/README.md) - For frontend assets canister
124124

125125
Use this recipe when developing IC canisters in Motoko, the native language for the Internet Computer.
126126

127-
## Version History
127+
## Release History
128128

129-
- v1.0.0 - Initial release with Motoko compilation support
129+
See the [release history](https://github.com/dfinity/icp-cli-recipes/releases?q=motoko&expanded=true) for changelogs, version updates, and breaking changes.

recipes/prebuilt/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,10 +98,10 @@ When this recipe is executed:
9898

9999
- [Rust Recipe](../rust/README.md) - For building Rust canisters from source
100100
- [Motoko Recipe](../motoko/README.md) - For building Motoko canisters from source
101-
- [Assets Recipe](../assets/README.md) - For the official IC assets canister
101+
- [Asset Canister Recipe](../asset-canister/README.md) - For the official IC assets canister
102102

103103
Use this recipe when you have a pre-compiled WASM file and want to add metadata or optimize it without rebuilding from source.
104104

105-
## Version History
105+
## Release History
106106

107-
- v1.0.0 - Initial release with basic pre-built WASM support
107+
See the [release history](https://github.com/dfinity/icp-cli-recipes/releases?q=prebuilt&expanded=true) for changelogs, version updates, and breaking changes.

recipes/rust/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,10 +147,10 @@ serde = { version = "1.0", features = ["derive"] }
147147

148148
- [Motoko Recipe](../motoko/README.md) - For building Motoko canisters
149149
- [Pre-built Recipe](../prebuilt/README.md) - For using pre-compiled WASM files
150-
- [Assets Recipe](../assets/README.md) - For frontend assets canister
150+
- [Asset Canister Recipe](../asset-canister/README.md) - For frontend assets canister
151151

152152
Use this recipe when developing IC canisters in Rust, which provides performance benefits and access to the rich Rust ecosystem.
153153

154-
## Version History
154+
## Release History
155155

156-
- v1.0.0 - Initial release with Rust compilation support
156+
See the [release history](https://github.com/dfinity/icp-cli-recipes/releases?q=rust&expanded=true) for changelogs, version updates, and breaking changes.

0 commit comments

Comments
 (0)