@sifr-dev/loom 0.0.0-stage → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/CHANGELOG.md +112 -0
  2. package/LICENSE +21 -0
  3. package/README.ar.md +253 -0
  4. package/README.md +262 -2
  5. package/dist/browser.js +2717 -0
  6. package/dist/cli.js +15 -0
  7. package/dist/index.js +4854 -0
  8. package/dist/types/args.d.ts +14 -0
  9. package/dist/types/base64.d.ts +9 -0
  10. package/dist/types/browser.d.ts +57 -0
  11. package/dist/types/canonical.d.ts +20 -0
  12. package/dist/types/cli.d.ts +12 -0
  13. package/dist/types/commands/context.d.ts +30 -0
  14. package/dist/types/commands/diff.d.ts +18 -0
  15. package/dist/types/commands/doctor.d.ts +19 -0
  16. package/dist/types/commands/export.d.ts +30 -0
  17. package/dist/types/commands/migrate.d.ts +9 -0
  18. package/dist/types/commands/serve.d.ts +18 -0
  19. package/dist/types/commands/snapshot.d.ts +15 -0
  20. package/dist/types/commands/sync.d.ts +17 -0
  21. package/dist/types/commands/verify.d.ts +9 -0
  22. package/dist/types/commands/watch.d.ts +25 -0
  23. package/dist/types/compute.d.ts +49 -0
  24. package/dist/types/concurrency.d.ts +31 -0
  25. package/dist/types/config.d.ts +132 -0
  26. package/dist/types/diff.d.ts +57 -0
  27. package/dist/types/digest.d.ts +11 -0
  28. package/dist/types/entities.d.ts +27 -0
  29. package/dist/types/errors.d.ts +37 -0
  30. package/dist/types/fs.d.ts +23 -0
  31. package/dist/types/github/cache.d.ts +44 -0
  32. package/dist/types/github/client.d.ts +91 -0
  33. package/dist/types/github/collect.d.ts +36 -0
  34. package/dist/types/github/discovery.d.ts +39 -0
  35. package/dist/types/github/fixture.d.ts +26 -0
  36. package/dist/types/github/guard.d.ts +14 -0
  37. package/dist/types/github/memory-cache.d.ts +34 -0
  38. package/dist/types/index.d.ts +44 -0
  39. package/dist/types/log.d.ts +16 -0
  40. package/dist/types/metrics.d.ts +21 -0
  41. package/dist/types/migrate.d.ts +24 -0
  42. package/dist/types/pipeline.d.ts +73 -0
  43. package/dist/types/queue.d.ts +33 -0
  44. package/dist/types/sdk.d.ts +165 -0
  45. package/dist/types/secrets.d.ts +28 -0
  46. package/dist/types/serve-handler.d.ts +46 -0
  47. package/dist/types/sha256.d.ts +13 -0
  48. package/dist/types/site-module.d.ts +23 -0
  49. package/dist/types/site.d.ts +135 -0
  50. package/dist/types/snapshot.d.ts +16 -0
  51. package/dist/types/store.d.ts +119 -0
  52. package/dist/types/triggers.d.ts +67 -0
  53. package/dist/types/types.d.ts +176 -0
  54. package/dist/types/version.d.ts +7 -0
  55. package/dist/types/webhook/delivery.d.ts +45 -0
  56. package/dist/types/webhook/receiver.d.ts +46 -0
  57. package/dist/types/webhook/signature.d.ts +43 -0
  58. package/docs/CONFIGURATION.md +213 -0
  59. package/docs/DEPLOYMENT.md +316 -0
  60. package/docs/SDK.md +351 -0
  61. package/docs/SITE_CONTRACT.md +318 -0
  62. package/docs/VERIFICATION.md +130 -0
  63. package/package.json +83 -4
  64. package/schema/site@1.json +188 -0
@@ -0,0 +1,188 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://raw.githubusercontent.com/Sifr-Dev/Loom/main/schema/site@1.json",
4
+ "title": "Loom site record",
5
+ "description": "Deterministic project data emitted by `loom export`. Additive optional fields are allowed within @1; removals or meaning changes require @2.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": ["schema", "snapshot", "complete", "projects", "aliases", "errors"],
9
+ "properties": {
10
+ "schema": { "const": "loom/site@1" },
11
+ "snapshot": { "type": "string", "pattern": "^sha256:[0-9a-f]{64}$" },
12
+ "complete": { "type": "boolean" },
13
+ "projects": { "type": "array", "items": { "$ref": "#/$defs/project" } },
14
+ "aliases": {
15
+ "type": "array",
16
+ "items": {
17
+ "type": "object",
18
+ "additionalProperties": false,
19
+ "required": ["from", "to"],
20
+ "properties": { "from": { "type": "string" }, "to": { "type": "string" } }
21
+ }
22
+ },
23
+ "ownerAliases": {
24
+ "type": "array",
25
+ "description": "Old owner login -> current login; additive within @1.",
26
+ "items": {
27
+ "type": "object",
28
+ "additionalProperties": false,
29
+ "required": ["from", "to"],
30
+ "properties": { "from": { "type": "string" }, "to": { "type": "string" } }
31
+ }
32
+ },
33
+ "errors": { "type": "array", "items": { "$ref": "#/$defs/error" } }
34
+ },
35
+ "$defs": {
36
+ "release": {
37
+ "type": "object",
38
+ "additionalProperties": false,
39
+ "required": ["tag", "name", "publishedAt", "prerelease", "url"],
40
+ "properties": {
41
+ "tag": { "type": "string" },
42
+ "name": { "type": ["string", "null"] },
43
+ "publishedAt": { "type": ["string", "null"] },
44
+ "prerelease": { "type": "boolean" },
45
+ "url": { "type": ["string", "null"] }
46
+ }
47
+ },
48
+ "head": {
49
+ "type": "object",
50
+ "additionalProperties": false,
51
+ "required": ["sha", "shortSha", "message", "author", "committedAt", "url"],
52
+ "properties": {
53
+ "sha": { "type": "string" },
54
+ "shortSha": { "type": "string" },
55
+ "message": { "type": "string" },
56
+ "author": { "type": ["string", "null"] },
57
+ "committedAt": { "type": ["string", "null"] },
58
+ "url": { "type": "string" }
59
+ }
60
+ },
61
+ "readme": {
62
+ "type": ["object", "null"],
63
+ "additionalProperties": false,
64
+ "required": ["path", "sha", "size", "htmlUrl", "downloadUrl", "excerpt"],
65
+ "properties": {
66
+ "path": { "type": "string" },
67
+ "sha": { "type": "string" },
68
+ "size": { "type": "integer", "minimum": 0 },
69
+ "htmlUrl": { "type": ["string", "null"] },
70
+ "downloadUrl": { "type": ["string", "null"] },
71
+ "excerpt": { "type": ["string", "null"], "maxLength": 20000 }
72
+ }
73
+ },
74
+ "branch": {
75
+ "type": "object",
76
+ "additionalProperties": false,
77
+ "required": ["name", "sha", "shortSha", "protected", "default"],
78
+ "properties": {
79
+ "name": { "type": "string" },
80
+ "sha": { "type": "string" },
81
+ "shortSha": { "type": "string" },
82
+ "protected": { "type": "boolean" },
83
+ "default": { "type": "boolean" }
84
+ }
85
+ },
86
+ "comment": {
87
+ "type": "object",
88
+ "additionalProperties": false,
89
+ "required": ["id", "body", "author", "createdAt", "url"],
90
+ "properties": {
91
+ "id": { "type": ["integer", "string"] },
92
+ "body": { "type": "string" },
93
+ "author": { "type": ["string", "null"] },
94
+ "createdAt": { "type": ["string", "null"] },
95
+ "url": { "type": ["string", "null"] }
96
+ }
97
+ },
98
+ "workflow": {
99
+ "type": "object",
100
+ "additionalProperties": false,
101
+ "required": ["id", "name", "path", "state"],
102
+ "properties": {
103
+ "id": { "type": ["integer", "string"] },
104
+ "name": { "type": "string" },
105
+ "path": { "type": "string" },
106
+ "state": { "type": "string" }
107
+ }
108
+ },
109
+ "ci": {
110
+ "type": ["object", "null"],
111
+ "additionalProperties": false,
112
+ "required": ["workflow", "runId", "status", "conclusion", "branch", "sha", "shortSha", "url", "updatedAt"],
113
+ "properties": {
114
+ "workflow": { "type": ["string", "null"] },
115
+ "runId": { "type": ["integer", "string"] },
116
+ "status": { "type": ["string", "null"] },
117
+ "conclusion": { "type": ["string", "null"] },
118
+ "branch": { "type": ["string", "null"] },
119
+ "sha": { "type": ["string", "null"] },
120
+ "shortSha": { "type": ["string", "null"] },
121
+ "url": { "type": ["string", "null"] },
122
+ "updatedAt": { "type": ["string", "null"] }
123
+ }
124
+ },
125
+ "project": {
126
+ "type": "object",
127
+ "additionalProperties": false,
128
+ "required": [
129
+ "id", "slug", "owner", "name", "fullName", "description", "homepage", "topics",
130
+ "language", "languages", "license", "stars", "forks", "watchers", "openIssues",
131
+ "archived", "fork", "defaultBranch", "htmlUrl", "createdAt", "updatedAt",
132
+ "pushedAt", "release", "releases", "head"
133
+ ],
134
+ "properties": {
135
+ "id": { "type": "string", "description": "owner/name lowercased; stable key" },
136
+ "slug": { "type": "string" },
137
+ "owner": { "type": "string" },
138
+ "name": { "type": "string" },
139
+ "fullName": { "type": "string" },
140
+ "description": { "type": ["string", "null"] },
141
+ "homepage": { "type": ["string", "null"] },
142
+ "topics": { "type": "array", "items": { "type": "string" } },
143
+ "language": { "type": ["string", "null"] },
144
+ "languages": {
145
+ "type": "array",
146
+ "items": {
147
+ "type": "object",
148
+ "additionalProperties": false,
149
+ "required": ["name", "bytes"],
150
+ "properties": { "name": { "type": "string" }, "bytes": { "type": "integer", "minimum": 0 } }
151
+ }
152
+ },
153
+ "license": { "type": ["string", "null"] },
154
+ "stars": { "type": "integer", "minimum": 0 },
155
+ "forks": { "type": "integer", "minimum": 0 },
156
+ "watchers": { "type": "integer", "minimum": 0 },
157
+ "openIssues": { "type": "integer", "minimum": 0 },
158
+ "archived": { "type": "boolean" },
159
+ "fork": { "type": "boolean" },
160
+ "defaultBranch": { "type": "string" },
161
+ "htmlUrl": { "type": "string" },
162
+ "createdAt": { "type": ["string", "null"] },
163
+ "updatedAt": { "type": ["string", "null"] },
164
+ "pushedAt": { "type": ["string", "null"] },
165
+ "release": { "oneOf": [{ "$ref": "#/$defs/release" }, { "type": "null" }] },
166
+ "releases": { "type": "array", "items": { "$ref": "#/$defs/release" } },
167
+ "head": { "oneOf": [{ "$ref": "#/$defs/head" }, { "type": "null" }] },
168
+ "readme": { "$ref": "#/$defs/readme" },
169
+ "branches": { "type": "array", "items": { "$ref": "#/$defs/branch" } },
170
+ "commitComments": { "type": "array", "items": { "$ref": "#/$defs/comment" } },
171
+ "issueComments": { "type": "array", "items": { "$ref": "#/$defs/comment" } },
172
+ "workflows": { "type": "array", "items": { "$ref": "#/$defs/workflow" } },
173
+ "ci": { "$ref": "#/$defs/ci" }
174
+ }
175
+ },
176
+ "error": {
177
+ "type": "object",
178
+ "additionalProperties": false,
179
+ "required": ["repo", "code", "message"],
180
+ "properties": {
181
+ "repo": { "type": "string" },
182
+ "code": { "type": "string" },
183
+ "message": { "type": "string" },
184
+ "retained": { "const": true }
185
+ }
186
+ }
187
+ }
188
+ }