@adea-ai/app-framework-release-tools 0.11.0 → 0.11.1
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/README.md +1 -1
- package/dist/cli.js +58 -32
- package/dist/index.js +39 -15
- package/dist/release-tools-source.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -37,7 +37,7 @@ The framework's `release-*` bins run the same commands.
|
|
|
37
37
|
|
|
38
38
|
The caller must obtain the expected repository, source, run and attempt from a protected authority. Local `origin/main` ancestry is advisory: it does not authenticate the remote, rule out local grafts, or establish approval. Pin and independently qualify the builder image and its system tools, then complete the native lifecycle and batch gates before any publication. Historical releases without the tracked manifest need a separately authenticated policy-to-baseline binding; this command does not supply one.
|
|
39
39
|
|
|
40
|
-
`package-channels <policy.json> <manifest.json> <new-output-dir> [channel ...]` is a dry run. It reads a `framework/package-channels/v1` policy and one exact manifest (a `framework/daily-batch/v1` batch or a published `release.json`) and renders Homebrew, WinGet, APT, pacman, RPM and Flatpak files under `<out>/<channel>/`, with `package-channels.json` listing each channel's asset, install command and the release-page downloads. Channels are planned independently; the command exits 1 when any requested channel failed, after writing the others. It signs, uploads and qualifies nothing. Daily releases get `<token>@daily` casks and `<Id>.Daily` WinGet manifests, and only Stable releases are eligible for public catalogs. A direct `.exe` WinGet installer is the framework's standalone Setup.exe: its manifest passes `--package-manager=winget` (the policy gives no silent flags), and after a successful install the Setup writes `.package-manager` in `%LOCALAPPDATA%\<appId>\stable\app`, so the in-app updater leaves the install to WinGet. A `.zip` installer (Electrobun's Setup) gets the policy's flags and is not marked.
|
|
40
|
+
`package-channels <policy.json> <manifest.json> <new-output-dir> [channel ...]` is a dry run. It reads a `framework/package-channels/v1` policy and one exact manifest (a `framework/daily-batch/v1` batch or a published `release.json`) and renders Homebrew, WinGet, APT, pacman, RPM and Flatpak files under `<out>/<channel>/`, with `package-channels.json` listing each channel's asset, install command and the release-page downloads. Channels are planned independently; the command exits 1 when any requested channel failed, after writing the others. It signs, uploads and qualifies nothing. Daily releases get `<token>@daily` casks and `<Id>.Daily` WinGet manifests, and only Stable releases are eligible for public catalogs. Casks (here and from `prepare-stable-catalog`) follow `brew style`'s stanza order and declare `depends_on macos: ">= :sonoma"`, the oldest macOS Electrobun binaries run on; a `homebrew.minimumMacos` of `ventura`, `sonoma`, `sequoia` or `tahoe` overrides it. A direct `.exe` WinGet installer is the framework's standalone Setup.exe: its manifest passes `--package-manager=winget` (the policy gives no silent flags), and after a successful install the Setup writes `.package-manager` in `%LOCALAPPDATA%\<appId>\stable\app`, so the in-app updater leaves the install to WinGet. A `.zip` installer (Electrobun's Setup) gets the policy's flags and is not marked.
|
|
41
41
|
|
|
42
42
|
`publish-packages --local <packages-dir> <release-config.json> <out>`, with `RELEASE_TAG` and `SOURCE_SHA` set and the checkout at the tag, stages a tag's Linux packages like `publish --local`: the directory holds only `<archive base>.deb` and `<archive base>.AppImage` files for Linux archives the feed already lists for the tag from the same commit. They are added to release.json and the channel pointers as raw, unsigned files; no descriptor names them and nothing already published is replaced.
|
|
43
43
|
|
package/dist/cli.js
CHANGED
|
@@ -10777,6 +10777,26 @@ async function buildStandaloneWindowsExe(options) {
|
|
|
10777
10777
|
await rm13(work, { recursive: true, force: true });
|
|
10778
10778
|
}
|
|
10779
10779
|
}
|
|
10780
|
+
// src/library/homebrew-cask.ts
|
|
10781
|
+
var ruby = (value) => JSON.stringify(value).replace(/#(?=[{@$])/g, "\\#");
|
|
10782
|
+
var DEFAULT_HOMEBREW_MINIMUM_MACOS = "sonoma";
|
|
10783
|
+
var MACOS_CODENAMES = ["ventura", "sonoma", "sequoia", "tahoe"];
|
|
10784
|
+
function homebrewMinimumMacos(value) {
|
|
10785
|
+
if (value === undefined)
|
|
10786
|
+
return DEFAULT_HOMEBREW_MINIMUM_MACOS;
|
|
10787
|
+
if (typeof value !== "string" || !MACOS_CODENAMES.includes(value))
|
|
10788
|
+
throw new Error(`Invalid Homebrew minimum macOS (one of ${MACOS_CODENAMES.join(", ")})`);
|
|
10789
|
+
return value;
|
|
10790
|
+
}
|
|
10791
|
+
function homebrewRequirements(options) {
|
|
10792
|
+
return [
|
|
10793
|
+
...options.conflictsWith ? [` conflicts_with cask: ${ruby(options.conflictsWith)}`] : [],
|
|
10794
|
+
...options.arm64Only ? [" depends_on arch: :arm64"] : [],
|
|
10795
|
+
` depends_on macos: ">= :${options.minimumMacos}"`
|
|
10796
|
+
].join(`
|
|
10797
|
+
`);
|
|
10798
|
+
}
|
|
10799
|
+
|
|
10780
10800
|
// src/library/package-channels.ts
|
|
10781
10801
|
var packageChannelNames = [
|
|
10782
10802
|
"homebrew",
|
|
@@ -10820,7 +10840,7 @@ var packagePattern = /^[a-z0-9][a-z0-9+.-]{0,62}$/;
|
|
|
10820
10840
|
var reverseDns = /^[A-Za-z_][A-Za-z0-9_-]*(\.[A-Za-z_][A-Za-z0-9_-]*){2,}$/;
|
|
10821
10841
|
var relativePath2 = /^[A-Za-z0-9][A-Za-z0-9._-]*(\/[A-Za-z0-9][A-Za-z0-9._-]*)*$/;
|
|
10822
10842
|
var quoted = JSON.stringify;
|
|
10823
|
-
var
|
|
10843
|
+
var ruby2 = (value) => JSON.stringify(value).replace(/#(?=[{@$])/g, "\\#");
|
|
10824
10844
|
var shell = (value) => `'${value.replaceAll("'", "'\\''")}'`;
|
|
10825
10845
|
function parseAsset(value) {
|
|
10826
10846
|
const row = object(value, "manifest asset");
|
|
@@ -10893,7 +10913,8 @@ function stageInput(context, asset) {
|
|
|
10893
10913
|
};
|
|
10894
10914
|
}
|
|
10895
10915
|
function homebrew(context, row) {
|
|
10896
|
-
keys2(row, "homebrew", ["tap", "token", "bundle", "artifact"]);
|
|
10916
|
+
keys2(row, "homebrew", ["tap", "token", "bundle", "artifact"], ["minimumMacos"]);
|
|
10917
|
+
const minimumMacos = homebrewMinimumMacos(row.minimumMacos);
|
|
10897
10918
|
const tap = text3(row.tap, "Homebrew tap", /^[A-Za-z0-9][A-Za-z0-9-]*\/homebrew-[a-z0-9][a-z0-9-]*$/);
|
|
10898
10919
|
const stableToken = text3(row.token, "cask token", /^[a-z0-9]+(?:-[a-z0-9]+)*$/);
|
|
10899
10920
|
const bundle = text3(row.bundle, "app bundle", /^[A-Za-z0-9][A-Za-z0-9 ._-]*\.app$/);
|
|
@@ -10910,19 +10931,22 @@ function homebrew(context, row) {
|
|
|
10910
10931
|
files: [
|
|
10911
10932
|
{
|
|
10912
10933
|
path: `Casks/${token}.rb`,
|
|
10913
|
-
contents: `cask ${
|
|
10914
|
-
version ${
|
|
10915
|
-
sha256 ${
|
|
10934
|
+
contents: `cask ${ruby2(token)} do
|
|
10935
|
+
version ${ruby2(context.version)}
|
|
10936
|
+
sha256 ${ruby2(asset.sha256)}
|
|
10916
10937
|
|
|
10917
|
-
url ${
|
|
10918
|
-
name ${
|
|
10919
|
-
desc ${
|
|
10920
|
-
homepage ${
|
|
10938
|
+
url ${ruby2(asset.url)}
|
|
10939
|
+
name ${ruby2(stable ? name : `${name} Daily`)}
|
|
10940
|
+
desc ${ruby2(description)}
|
|
10941
|
+
homepage ${ruby2(homepage)}
|
|
10921
10942
|
|
|
10922
|
-
|
|
10923
|
-
|
|
10943
|
+
${homebrewRequirements({
|
|
10944
|
+
conflictsWith: stable ? `${stableToken}@daily` : stableToken,
|
|
10945
|
+
arm64Only: true,
|
|
10946
|
+
minimumMacos
|
|
10947
|
+
})}
|
|
10924
10948
|
|
|
10925
|
-
app ${
|
|
10949
|
+
app ${ruby2(bundle)}
|
|
10926
10950
|
end
|
|
10927
10951
|
`
|
|
10928
10952
|
}
|
|
@@ -11797,7 +11821,7 @@ var sha = (value) => requireText(value, "SHA-256", /^[a-f0-9]{64}$/);
|
|
|
11797
11821
|
var source = (value) => requireText(value, "source SHA", /^[a-f0-9]{40}$/);
|
|
11798
11822
|
var file = (value) => requireText(value, "asset name", /^[a-zA-Z0-9][a-zA-Z0-9._-]*$/);
|
|
11799
11823
|
var quoted2 = JSON.stringify;
|
|
11800
|
-
var
|
|
11824
|
+
var ruby3 = (value) => JSON.stringify(value).replace(/#(?=[{@$])/g, "\\#");
|
|
11801
11825
|
function asset(value) {
|
|
11802
11826
|
const row = object2(value);
|
|
11803
11827
|
const size = row.size;
|
|
@@ -11875,24 +11899,26 @@ function prepareStableCatalog(input) {
|
|
|
11875
11899
|
return [
|
|
11876
11900
|
{
|
|
11877
11901
|
path: `Casks/${token}.rb`,
|
|
11878
|
-
contents: `cask ${
|
|
11879
|
-
version ${
|
|
11902
|
+
contents: `cask ${ruby3(token)} do
|
|
11903
|
+
version ${ruby3(arm.tag.slice(1))}
|
|
11880
11904
|
|
|
11881
11905
|
on_arm do
|
|
11882
|
-
sha256 ${
|
|
11883
|
-
url ${
|
|
11906
|
+
sha256 ${ruby3(arm.staged.sha256)}
|
|
11907
|
+
url ${ruby3(arm.url)}
|
|
11884
11908
|
end
|
|
11885
11909
|
|
|
11886
11910
|
on_intel do
|
|
11887
|
-
sha256 ${
|
|
11888
|
-
url ${
|
|
11911
|
+
sha256 ${ruby3(intel.staged.sha256)}
|
|
11912
|
+
url ${ruby3(intel.url)}
|
|
11889
11913
|
end
|
|
11890
11914
|
|
|
11891
|
-
name ${
|
|
11892
|
-
desc ${
|
|
11893
|
-
homepage ${
|
|
11915
|
+
name ${ruby3(name)}
|
|
11916
|
+
desc ${ruby3(desc)}
|
|
11917
|
+
homepage ${ruby3(homepage)}
|
|
11894
11918
|
|
|
11895
|
-
|
|
11919
|
+
${homebrewRequirements({ arm64Only: false, minimumMacos: homebrewMinimumMacos(channelConfig.minimumMacos) })}
|
|
11920
|
+
|
|
11921
|
+
app ${ruby3(bundle)}
|
|
11896
11922
|
end
|
|
11897
11923
|
`
|
|
11898
11924
|
}
|
|
@@ -11934,18 +11960,18 @@ end
|
|
|
11934
11960
|
return [
|
|
11935
11961
|
{
|
|
11936
11962
|
path: `Casks/${token}.rb`,
|
|
11937
|
-
contents: `cask ${
|
|
11938
|
-
version ${
|
|
11939
|
-
sha256 ${
|
|
11963
|
+
contents: `cask ${ruby3(token)} do
|
|
11964
|
+
version ${ruby3(version)}
|
|
11965
|
+
sha256 ${ruby3(staged.sha256)}
|
|
11940
11966
|
|
|
11941
|
-
url ${
|
|
11942
|
-
name ${
|
|
11943
|
-
desc ${
|
|
11944
|
-
homepage ${
|
|
11967
|
+
url ${ruby3(url)}
|
|
11968
|
+
name ${ruby3(name)}
|
|
11969
|
+
desc ${ruby3(desc)}
|
|
11970
|
+
homepage ${ruby3(homepage)}
|
|
11945
11971
|
|
|
11946
|
-
|
|
11972
|
+
${homebrewRequirements({ arm64Only: true, minimumMacos: homebrewMinimumMacos(channelConfig.minimumMacos) })}
|
|
11947
11973
|
|
|
11948
|
-
app ${
|
|
11974
|
+
app ${ruby3(bundle)}
|
|
11949
11975
|
end
|
|
11950
11976
|
`
|
|
11951
11977
|
}
|
package/dist/index.js
CHANGED
|
@@ -10667,6 +10667,26 @@ async function buildStandaloneWindowsExe(options) {
|
|
|
10667
10667
|
await rm13(work, { recursive: true, force: true });
|
|
10668
10668
|
}
|
|
10669
10669
|
}
|
|
10670
|
+
// src/library/homebrew-cask.ts
|
|
10671
|
+
var ruby = (value) => JSON.stringify(value).replace(/#(?=[{@$])/g, "\\#");
|
|
10672
|
+
var DEFAULT_HOMEBREW_MINIMUM_MACOS = "sonoma";
|
|
10673
|
+
var MACOS_CODENAMES = ["ventura", "sonoma", "sequoia", "tahoe"];
|
|
10674
|
+
function homebrewMinimumMacos(value) {
|
|
10675
|
+
if (value === undefined)
|
|
10676
|
+
return DEFAULT_HOMEBREW_MINIMUM_MACOS;
|
|
10677
|
+
if (typeof value !== "string" || !MACOS_CODENAMES.includes(value))
|
|
10678
|
+
throw new Error(`Invalid Homebrew minimum macOS (one of ${MACOS_CODENAMES.join(", ")})`);
|
|
10679
|
+
return value;
|
|
10680
|
+
}
|
|
10681
|
+
function homebrewRequirements(options) {
|
|
10682
|
+
return [
|
|
10683
|
+
...options.conflictsWith ? [` conflicts_with cask: ${ruby(options.conflictsWith)}`] : [],
|
|
10684
|
+
...options.arm64Only ? [" depends_on arch: :arm64"] : [],
|
|
10685
|
+
` depends_on macos: ">= :${options.minimumMacos}"`
|
|
10686
|
+
].join(`
|
|
10687
|
+
`);
|
|
10688
|
+
}
|
|
10689
|
+
|
|
10670
10690
|
// src/library/package-channels.ts
|
|
10671
10691
|
var packageChannelNames = [
|
|
10672
10692
|
"homebrew",
|
|
@@ -10710,7 +10730,7 @@ var packagePattern = /^[a-z0-9][a-z0-9+.-]{0,62}$/;
|
|
|
10710
10730
|
var reverseDns = /^[A-Za-z_][A-Za-z0-9_-]*(\.[A-Za-z_][A-Za-z0-9_-]*){2,}$/;
|
|
10711
10731
|
var relativePath2 = /^[A-Za-z0-9][A-Za-z0-9._-]*(\/[A-Za-z0-9][A-Za-z0-9._-]*)*$/;
|
|
10712
10732
|
var quoted = JSON.stringify;
|
|
10713
|
-
var
|
|
10733
|
+
var ruby2 = (value) => JSON.stringify(value).replace(/#(?=[{@$])/g, "\\#");
|
|
10714
10734
|
var shell = (value) => `'${value.replaceAll("'", "'\\''")}'`;
|
|
10715
10735
|
function parseAsset(value) {
|
|
10716
10736
|
const row = object(value, "manifest asset");
|
|
@@ -10783,7 +10803,8 @@ function stageInput(context, asset) {
|
|
|
10783
10803
|
};
|
|
10784
10804
|
}
|
|
10785
10805
|
function homebrew(context, row) {
|
|
10786
|
-
keys2(row, "homebrew", ["tap", "token", "bundle", "artifact"]);
|
|
10806
|
+
keys2(row, "homebrew", ["tap", "token", "bundle", "artifact"], ["minimumMacos"]);
|
|
10807
|
+
const minimumMacos = homebrewMinimumMacos(row.minimumMacos);
|
|
10787
10808
|
const tap = text3(row.tap, "Homebrew tap", /^[A-Za-z0-9][A-Za-z0-9-]*\/homebrew-[a-z0-9][a-z0-9-]*$/);
|
|
10788
10809
|
const stableToken = text3(row.token, "cask token", /^[a-z0-9]+(?:-[a-z0-9]+)*$/);
|
|
10789
10810
|
const bundle = text3(row.bundle, "app bundle", /^[A-Za-z0-9][A-Za-z0-9 ._-]*\.app$/);
|
|
@@ -10800,19 +10821,22 @@ function homebrew(context, row) {
|
|
|
10800
10821
|
files: [
|
|
10801
10822
|
{
|
|
10802
10823
|
path: `Casks/${token}.rb`,
|
|
10803
|
-
contents: `cask ${
|
|
10804
|
-
version ${
|
|
10805
|
-
sha256 ${
|
|
10806
|
-
|
|
10807
|
-
url ${
|
|
10808
|
-
name ${
|
|
10809
|
-
desc ${
|
|
10810
|
-
homepage ${
|
|
10811
|
-
|
|
10812
|
-
|
|
10813
|
-
|
|
10814
|
-
|
|
10815
|
-
|
|
10824
|
+
contents: `cask ${ruby2(token)} do
|
|
10825
|
+
version ${ruby2(context.version)}
|
|
10826
|
+
sha256 ${ruby2(asset.sha256)}
|
|
10827
|
+
|
|
10828
|
+
url ${ruby2(asset.url)}
|
|
10829
|
+
name ${ruby2(stable ? name : `${name} Daily`)}
|
|
10830
|
+
desc ${ruby2(description)}
|
|
10831
|
+
homepage ${ruby2(homepage)}
|
|
10832
|
+
|
|
10833
|
+
${homebrewRequirements({
|
|
10834
|
+
conflictsWith: stable ? `${stableToken}@daily` : stableToken,
|
|
10835
|
+
arm64Only: true,
|
|
10836
|
+
minimumMacos
|
|
10837
|
+
})}
|
|
10838
|
+
|
|
10839
|
+
app ${ruby2(bundle)}
|
|
10816
10840
|
end
|
|
10817
10841
|
`
|
|
10818
10842
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":"0.11.
|
|
1
|
+
{"version":"0.11.1","commit":"9b687fbf274c05670c32f4e928d89ddac0a5aa65"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@adea-ai/app-framework-release-tools",
|
|
3
|
-
"version": "0.11.
|
|
3
|
+
"version": "0.11.1",
|
|
4
4
|
"description": "Host-side release tooling for @adea-ai/app-framework apps, on Effect: the release CLIs and the framework package publish. Installing it never adds Effect to the framework itself.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|