Content-addressed version deploy system for Diffuse
elements.diffuse.sh
1{
2 "imports": {
3 "@atikayda/kjson": "jsr:@atikayda/kjson@^1.2.2",
4 "@ipld/dag-json": "npm:@ipld/dag-json@^10.2.5",
5 "@ipld/dag-pb": "npm:@ipld/dag-pb@^4.1.5",
6 "@std/cli": "jsr:@std/cli@^1.0.24",
7 "@std/dotenv": "jsr:@std/dotenv@^0.225.5",
8 "@std/fs": "jsr:@std/fs@^1.0.19",
9 "@std/path": "jsr:@std/path@^1.1.2",
10 "blockstore-core": "npm:blockstore-core@^6.1.1",
11 "ipfs-car": "npm:ipfs-car@^3.1.0",
12 "ipfs-unixfs-importer": "npm:ipfs-unixfs-importer@^16.0.1",
13 "lume/": "https://cdn.jsdelivr.net/gh/lumeland/lume@3.1.4/",
14 "lume/jsx-runtime": "https://cdn.jsdelivr.net/gh/oscarotero/ssx@0.1.14/jsx-runtime.ts",
15 "multiformats": "npm:multiformats@^13.4.1",
16 },
17 "tasks": {
18 "add-artifact": "deno run -A tasks/add-artifact.ts",
19 "build:with-symlink-redirects": "deno run add-artifact && deno run de-duplicate && deno run generate-redirects --symlinks",
20 "build:without-symlink-redirects": "deno run add-artifact && deno run de-duplicate && deno run generate-redirects",
21 "copy-artifacts": "cp -r ./artifacts/* ./dist",
22 "de-duplicate": "cd ./artifacts/ && ls -t | fclones group --stdin --hidden | fclones link --soft --priority=newest && symlinks -cr .",
23 "generate-redirects": "deno run --allow-read --allow-write=artifacts/ ./tasks/generate-redirects.ts",
24 "sync-diffuse": "git submodule update --init --recursive --remote",
25 "deploy:netlify": "deno run build:with-symlink-redirects && deno run index:build && deno run copy-artifacts && npx --yes netlify deploy --prod && rm -rf dist/",
26 "deploy:ipfs": "deno run build:without-symlink-redirects && deno run index:build && deno run -A tasks/deploy/ipfs.ts",
27 "index:build": "deno task lume",
28 "index:serve": "deno task lume -s",
29 "lume": {
30 "description": "Run Lume command",
31 "command": "deno run -P=lume lume/cli.ts",
32 },
33 },
34 "compilerOptions": {
35 "checkJs": true,
36 "types": ["lume/types.ts"],
37 "jsx": "react-jsx",
38 "jsxImportSource": "lume",
39 },
40 "permissions": {
41 "lume": {
42 "read": true,
43 "write": ["./"],
44 "import": ["cdn.jsdelivr.net:443", "jsr.io:443", "deno.land:443", "esm.sh:443"],
45 "net": [
46 "0.0.0.0",
47 "cdn.jsdelivr.net:443",
48 "data.jsdelivr.com:443",
49 "jsr.io:443",
50 "deno.land:443",
51 "esm.sh:443",
52 "registry.npmjs.org:443",
53 ],
54 "env": true,
55 "run": true,
56 "ffi": true,
57 "sys": true,
58 },
59 },
60 "unstable": ["temporal", "fmt-component"],
61 "lint": {
62 "plugins": ["https://cdn.jsdelivr.net/gh/lumeland/lume@3.1.4/lint.ts"],
63 "rules": {
64 "exclude": ["no-import-prefix"],
65 },
66 },
67 "lock": false,
68}