@norskvideo/ctl-dev-kit 0.1.62 → 0.1.63
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.
- package/conventions/checks.yml +25 -0
- package/package.json +9 -8
package/conventions/checks.yml
CHANGED
|
@@ -78,6 +78,31 @@ jobs:
|
|
|
78
78
|
bun run docs:check
|
|
79
79
|
'
|
|
80
80
|
|
|
81
|
+
# Does this repo's licence template still describe this repo? A template
|
|
82
|
+
# naming the wrong product, or an imageRef the build never produces, mints
|
|
83
|
+
# a licence that entitles nothing -- and the first sign of that is a
|
|
84
|
+
# 60-second readiness timeout at launch, indistinguishable from a product
|
|
85
|
+
# that failed to start. Cheap, no secrets, every PR.
|
|
86
|
+
#
|
|
87
|
+
# The image name is CI's own rule: PUBLISH_IMAGE when set, else the build
|
|
88
|
+
# script's IMAGE_TAG default, tag stripped -- a licence matches the repo
|
|
89
|
+
# part alone, never the tag.
|
|
90
|
+
- name: Check the licence template matches this repo
|
|
91
|
+
run: |
|
|
92
|
+
set -euo pipefail
|
|
93
|
+
product="$(sed -nE 's/.*PRODUCT_NAME[[:space:]]*=[[:space:]]*"([^"]+)".*/\1/p' shared/src/version.ts | head -1)"
|
|
94
|
+
[ -n "$product" ] || { echo "::error::could not read PRODUCT_NAME from shared/src/version.ts"; exit 1; }
|
|
95
|
+
pub="$(sed -nE 's/^[[:space:]]*PUBLISH_IMAGE:[[:space:]]*"?([^" ]*)"?[[:space:]]*$/\1/p' .github/workflows/build-image.yml | head -1)"
|
|
96
|
+
def="$(sed -nE 's/.*IMAGE_TAG:-([^}]+)\}.*/\1/p' deployment/build-image.sh | head -1)"
|
|
97
|
+
ref="${pub:-$def}"
|
|
98
|
+
# A colon is a tag only after the last slash (a registry host may carry a port).
|
|
99
|
+
image="${ref%:*}"
|
|
100
|
+
case "${ref##*/}" in *:*) ;; *) image="$ref" ;; esac
|
|
101
|
+
[ -n "$image" ] || { echo "::error::could not determine the image this repo builds"; exit 1; }
|
|
102
|
+
nix develop .#build --command bun \
|
|
103
|
+
node_modules/@norskvideo/ctl-dev-kit/licence/check-template.ts \
|
|
104
|
+
licenseTemplate.json "$product" "$image"
|
|
105
|
+
|
|
81
106
|
# Report this pipeline's result to the aggregated product CI dashboard
|
|
82
107
|
# (id3as/ci-workflows) instead of posting its own pony — the dashboard renders
|
|
83
108
|
# the pony/emoji from the dispatched result. !cancelled() so a real pass/fail
|
package/package.json
CHANGED
|
@@ -1,21 +1,22 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@norskvideo/ctl-dev-kit",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.63",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"exports": {
|
|
6
|
-
"./package.json": "./package.json",
|
|
7
|
-
"./testing/invariants": "./testing/invariants.ts",
|
|
8
|
-
"./testing/byte-snapshot": "./testing/byte-snapshot.ts",
|
|
9
6
|
"./create-product": "./create-product/create-product.ts",
|
|
10
|
-
"./docs/path-existence": "./docs/path-existence.ts",
|
|
11
|
-
"./docs/splice-generated": "./docs/splice-generated.ts",
|
|
12
7
|
"./doc-guide": "./doc-guide/doc-guide.js",
|
|
13
8
|
"./doc-guide/build-manual": "./doc-guide/build-manual.js",
|
|
14
9
|
"./doc-guide/bundle": "./doc-guide/bundle.js",
|
|
15
|
-
"./doc-guide/prose-bundle": "./doc-guide/prose-bundle.js",
|
|
16
10
|
"./doc-guide/guides-config": "./doc-guide/guides-config.js",
|
|
17
11
|
"./doc-guide/instance-proxy": "./doc-guide/instance-proxy.js",
|
|
18
|
-
"./doc-guide/live-browser": "./doc-guide/live-browser.js"
|
|
12
|
+
"./doc-guide/live-browser": "./doc-guide/live-browser.js",
|
|
13
|
+
"./doc-guide/prose-bundle": "./doc-guide/prose-bundle.js",
|
|
14
|
+
"./docs/path-existence": "./docs/path-existence.ts",
|
|
15
|
+
"./docs/splice-generated": "./docs/splice-generated.ts",
|
|
16
|
+
"./licence/check-template": "./licence/check-template.ts",
|
|
17
|
+
"./package.json": "./package.json",
|
|
18
|
+
"./testing/byte-snapshot": "./testing/byte-snapshot.ts",
|
|
19
|
+
"./testing/invariants": "./testing/invariants.ts"
|
|
19
20
|
},
|
|
20
21
|
"bin": {
|
|
21
22
|
"ctl-dev-kit": "./create-product/cli.ts"
|