forked from orogene/orogene
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.toml
102 lines (86 loc) · 2.73 KB
/
Makefile.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
[tasks.changelog]
workspace = false
install_crate = "git-cliff"
command = "git-cliff"
args = ["--prepend", "CHANGELOG.md", "-u", "--tag", "${@}"]
[tasks.prerelease]
workspace = false
dependencies = ["changelog", "readmes"]
[tasks.release]
workspace = false
dependencies = ["cargo-release", "wasm-publish"]
[tasks.cargo-release]
workspace = false
install_crate = "cargo-release"
command = "cargo"
args = ["release", "--workspace", "${@}"]
[tasks.wasm-publish]
workspace = false
dependencies = ["publish-npm-nassun", "publish-npm-node-maintainer"]
[tasks.publish-npm-nassun]
env = { "npm_config_registry" = "https://registry.npmjs.org/" }
workspace = false
dependencies = ["wasm-build-nassun"]
command = "wasm-pack"
args = ["publish", "crates/nassun", "--target", "web"]
[tasks.publish-npm-node-maintainer]
env = { "npm_config_registry" = "https://registry.npmjs.org/" }
workspace = false
dependencies = ["wasm-build-node-maintainer"]
command = "wasm-pack"
args = ["publish", "crates/node-maintainer", "--target", "web"]
[tasks.wasm-build-nassun]
workspace = false
dependencies = ["wasm-build-nassun-base"]
command = "node"
args = ["-e", """
const jsonPath = './crates/nassun/pkg/package.json';
const fs = require('node:fs');
const pkg = require(jsonPath);
pkg["files"].push("nassun_bg.wasm.d.ts");
fs.writeFileSync(jsonPath, JSON.stringify(pkg, null, 2));
"""]
[tasks.wasm-build-node-maintainer]
workspace = false
dependencies = ["wasm-build-node-maintainer-base"]
command = "node"
args = ["-e", """
const jsonPath = './crates/node-maintainer/pkg/package.json';
const fs = require('node:fs');
const pkg = require(jsonPath);
pkg["files"].push("node_maintainer_bg.wasm.d.ts");
fs.writeFileSync(jsonPath, JSON.stringify(pkg, null, 2));
"""]
[tasks.wasm-build-nassun-base]
workspace = false
command = "wasm-pack"
args = ["build", "crates/nassun", "--target", "web"]
[tasks.wasm-build-node-maintainer-base]
workspace = false
command = "wasm-pack"
args = ["build", "crates/node-maintainer", "--target", "web"]
[tasks.readmes]
workspace = false
dependencies = ["workspace-readmes", "root-readme"]
[tasks.workspace-readmes]
workspace = false
env = { CARGO_MAKE_WORKSPACE_SKIP_MEMBERS = ["."] }
command = "cargo"
args = ["make", "workspace-readmes-inner"]
[tasks.workspace-readmes-inner]
install_crate = "cargo-readme"
command = "cargo"
args = ["readme", "-t", "../../WORKSPACE_README.tpl", "-o", "README.md"]
[tasks.root-readme]
workspace = false
install_crate = "cargo-readme"
command = "cargo"
args = ["readme", "-o", "README.md"]
# NOTE: This is meant to be run on *nix systems only.
[tasks.benchmark-graphs]
workspace = false
install_crate = "hyperfine"
command = "cargo"
args = ["run", "--release", "--example", "render-benchmarks"]
[env]
CARGO_MAKE_EXTEND_WORKSPACE_MAKEFILE = true