@shell-shock/plugin-changelog 0.1.4 → 0.1.6
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/dist/components/changelog-command.cjs +3 -3
- package/dist/components/changelog-command.mjs +3 -3
- package/dist/components/changelog-command.mjs.map +1 -1
- package/dist/helpers/resolve-changelog.cjs +51 -0
- package/dist/helpers/resolve-changelog.mjs +51 -0
- package/dist/helpers/resolve-changelog.mjs.map +1 -0
- package/dist/index.cjs +31 -19
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +31 -19
- package/dist/index.mjs.map +1 -1
- package/dist/types/plugin.d.cts +48 -0
- package/dist/types/plugin.d.cts.map +1 -1
- package/dist/types/plugin.d.mts +48 -0
- package/dist/types/plugin.d.mts.map +1 -1
- package/package.json +10 -10
|
@@ -104,18 +104,18 @@ function ChangelogCommand() {
|
|
|
104
104
|
return !!result.error;
|
|
105
105
|
},
|
|
106
106
|
get children() {
|
|
107
|
-
return _alloy_js_core.code` return error(\`Failed to load changelog: ${result.error.message.replaceAll(
|
|
107
|
+
return _alloy_js_core.code` return error(\`Failed to load changelog: ${result.error.message.replaceAll("\\", "\\\\").replaceAll("`", "\\`").replaceAll("${", "\\${").replaceAll("\n", "\\n").replaceAll("\r", "\\r").replaceAll(" ", "\\t")}\`); `;
|
|
108
108
|
}
|
|
109
109
|
});
|
|
110
110
|
},
|
|
111
111
|
get children() {
|
|
112
112
|
return (0, _alloy_js_core_jsx_runtime.createComponent)(_alloy_js_core.Show, {
|
|
113
113
|
get when() {
|
|
114
|
-
return !!result.data
|
|
114
|
+
return !!result.data;
|
|
115
115
|
},
|
|
116
116
|
fallback: _alloy_js_core.code` return warn("There is no changelog available for display."); `,
|
|
117
117
|
get children() {
|
|
118
|
-
return result.data
|
|
118
|
+
return result.data;
|
|
119
119
|
}
|
|
120
120
|
});
|
|
121
121
|
}
|
|
@@ -102,18 +102,18 @@ function ChangelogCommand() {
|
|
|
102
102
|
return !!result.error;
|
|
103
103
|
},
|
|
104
104
|
get children() {
|
|
105
|
-
return code` return error(\`Failed to load changelog: ${result.error.message.replaceAll(
|
|
105
|
+
return code` return error(\`Failed to load changelog: ${result.error.message.replaceAll("\\", "\\\\").replaceAll("`", "\\`").replaceAll("${", "\\${").replaceAll("\n", "\\n").replaceAll("\r", "\\r").replaceAll(" ", "\\t")}\`); `;
|
|
106
106
|
}
|
|
107
107
|
});
|
|
108
108
|
},
|
|
109
109
|
get children() {
|
|
110
110
|
return createComponent(Show, {
|
|
111
111
|
get when() {
|
|
112
|
-
return !!result.data
|
|
112
|
+
return !!result.data;
|
|
113
113
|
},
|
|
114
114
|
fallback: code` return warn("There is no changelog available for display."); `,
|
|
115
115
|
get children() {
|
|
116
|
-
return result.data
|
|
116
|
+
return result.data;
|
|
117
117
|
}
|
|
118
118
|
});
|
|
119
119
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"changelog-command.mjs","names":[],"sources":["../../src/components/changelog-command.tsx"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Shell Shock\n\n This code was released as part of the Shell Shock project. Shell Shock\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/shell-shock.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/shell-shock\n Documentation: https://docs.stormsoftware.com/projects/shell-shock\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { code, createResource, Show } from \"@alloy-js/core\";\nimport {\n FunctionDeclaration,\n InterfaceDeclaration\n} from \"@alloy-js/typescript\";\nimport { ReflectionKind } from \"@powerlines/deepkit/vendor/type\";\nimport { Spacing } from \"@powerlines/plugin-alloy/core\";\nimport { usePowerlines } from \"@powerlines/plugin-alloy/core/contexts/context\";\nimport {\n InterfaceMember,\n TypescriptFile\n} from \"@powerlines/plugin-alloy/typescript\";\nimport {\n TSDoc,\n TSDocDefaultValue,\n TSDocParam\n} from \"@powerlines/plugin-alloy/typescript/components/tsdoc\";\nimport { getAppTitle } from \"@shell-shock/core/plugin-utils\";\nimport { renderMarkdown } from \"@shell-shock/unified/markdown\";\nimport { joinPaths } from \"@stryke/path\";\nimport type { ChangelogPluginContext } from \"../types/plugin\";\n\n/**\n * The Changelog command's handler wrapper for the Shell Shock project.\n */\nexport function ChangelogCommand() {\n const context = usePowerlines<ChangelogPluginContext>();\n\n const result = createResource(async () => {\n const content = await context.fs.read(context.config.changelog.file);\n if (!content) {\n return null;\n }\n\n return renderMarkdown(content);\n });\n\n return (\n <TypescriptFile\n path={joinPaths(context.entryPath, \"changelog\", \"command.ts\")}\n imports={{\n \"node:os\": \"os\",\n \"node:fs/promises\": [\"readFile\", \"writeFile\"]\n }}\n builtinImports={{\n console: [\"textColors\", \"bold\", \"writeLine\", \"error\", \"warn\"]\n }}>\n <TSDoc heading=\"Options for the Changelog command.\" />\n <InterfaceDeclaration export name=\"ChangelogOptions\">\n <TSDoc heading=\"An optional starting version for the changelog. The command will attempt to display changes starting from the specified version. The version should be a valid semantic version string. If not specified, the changelog will start from the earliest version available.\" />\n <InterfaceMember name=\"start\" optional type=\"string\" />\n <Spacing />\n <TSDoc heading=\"An optional ending version for the changelog. The command will attempt to display changes up to the specified version. The version should be a valid semantic version string. If not specified, the changelog will display changes up to the latest version available.\">\n <TSDocDefaultValue\n type={ReflectionKind.string}\n defaultValue=\"latest\"\n />\n </TSDoc>\n <InterfaceMember name=\"end\" optional type=\"string\" />\n </InterfaceDeclaration>\n <Spacing />\n <TSDoc heading={`Display the ${getAppTitle(context)} changelog.`}>\n <TSDocParam name=\"options\">\n {code`An object containing options for displaying the changelog.`}\n </TSDocParam>\n </TSDoc>\n <FunctionDeclaration\n export\n default\n async\n name=\"handler\"\n parameters={[{ name: \"options\", type: \"ChangelogOptions\" }]}>\n <Show\n when={!result.loading && !result.error}\n fallback={\n <Show when={!!result.error}>\n {code` return error(\\`Failed to load changelog: ${result.error!.message.replaceAll(\n
|
|
1
|
+
{"version":3,"file":"changelog-command.mjs","names":[],"sources":["../../src/components/changelog-command.tsx"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Shell Shock\n\n This code was released as part of the Shell Shock project. Shell Shock\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/shell-shock.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/shell-shock\n Documentation: https://docs.stormsoftware.com/projects/shell-shock\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { code, createResource, Show } from \"@alloy-js/core\";\nimport {\n FunctionDeclaration,\n InterfaceDeclaration\n} from \"@alloy-js/typescript\";\nimport { ReflectionKind } from \"@powerlines/deepkit/vendor/type\";\nimport { Spacing } from \"@powerlines/plugin-alloy/core\";\nimport { usePowerlines } from \"@powerlines/plugin-alloy/core/contexts/context\";\nimport {\n InterfaceMember,\n TypescriptFile\n} from \"@powerlines/plugin-alloy/typescript\";\nimport {\n TSDoc,\n TSDocDefaultValue,\n TSDocParam\n} from \"@powerlines/plugin-alloy/typescript/components/tsdoc\";\nimport { getAppTitle } from \"@shell-shock/core/plugin-utils\";\nimport { renderMarkdown } from \"@shell-shock/unified/markdown\";\nimport { joinPaths } from \"@stryke/path\";\nimport type { ChangelogPluginContext } from \"../types/plugin\";\n\n/**\n * The Changelog command's handler wrapper for the Shell Shock project.\n */\nexport function ChangelogCommand() {\n const context = usePowerlines<ChangelogPluginContext>();\n\n const result = createResource(async () => {\n const content = await context.fs.read(context.config.changelog.file);\n if (!content) {\n return null;\n }\n\n return renderMarkdown(content);\n });\n\n return (\n <TypescriptFile\n path={joinPaths(context.entryPath, \"changelog\", \"command.ts\")}\n imports={{\n \"node:os\": \"os\",\n \"node:fs/promises\": [\"readFile\", \"writeFile\"]\n }}\n builtinImports={{\n console: [\"textColors\", \"bold\", \"writeLine\", \"error\", \"warn\"]\n }}>\n <TSDoc heading=\"Options for the Changelog command.\" />\n <InterfaceDeclaration export name=\"ChangelogOptions\">\n <TSDoc heading=\"An optional starting version for the changelog. The command will attempt to display changes starting from the specified version. The version should be a valid semantic version string. If not specified, the changelog will start from the earliest version available.\" />\n <InterfaceMember name=\"start\" optional type=\"string\" />\n <Spacing />\n <TSDoc heading=\"An optional ending version for the changelog. The command will attempt to display changes up to the specified version. The version should be a valid semantic version string. If not specified, the changelog will display changes up to the latest version available.\">\n <TSDocDefaultValue\n type={ReflectionKind.string}\n defaultValue=\"latest\"\n />\n </TSDoc>\n <InterfaceMember name=\"end\" optional type=\"string\" />\n </InterfaceDeclaration>\n <Spacing />\n <TSDoc heading={`Display the ${getAppTitle(context)} changelog.`}>\n <TSDocParam name=\"options\">\n {code`An object containing options for displaying the changelog.`}\n </TSDocParam>\n </TSDoc>\n <FunctionDeclaration\n export\n default\n async\n name=\"handler\"\n parameters={[{ name: \"options\", type: \"ChangelogOptions\" }]}>\n <Show\n when={!result.loading && !result.error}\n fallback={\n <Show when={!!result.error}>\n {code` return error(\\`Failed to load changelog: ${result\n .error!.message.replaceAll(\"\\\\\", \"\\\\\\\\\")\n .replaceAll(\"`\", \"\\\\`\")\n .replaceAll(\"${\", \"\\\\${\")\n .replaceAll(\"\\n\", \"\\\\n\")\n .replaceAll(\"\\r\", \"\\\\r\")\n .replaceAll(\"\\t\", \"\\\\t\")}\\`); `}\n </Show>\n }>\n <Show\n when={!!result.data}\n fallback={code` return warn(\"There is no changelog available for display.\"); `}>\n {result.data}\n </Show>\n </Show>\n </FunctionDeclaration>\n </TypescriptFile>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAkCA,SAAS,mBAAwB;CACjC,MAAQ,UAAC,eAA6C;CACtD,MAAQ,SAAC,eAAuB,YAAY;EAC5C,MAAS,UAAW,MAAM,QAAQ,GAAC,KAAK,QAAA,OAAA,UAAA,KAAA;AACxC,MAAO,CAAA;AAGJ,SAAI,eAAmB,QAAQ;GAChC;AACF,QAAO,gBAAS,gBAAmB;EACjC,IAAM,OAAO;;;EAGX,SAAM;GACJ,WAAW;GACX,oBAAW,CAAA,YAAA,YAAA;GACb;oBAEA,SAAO;GAAA;GAAe;GAAQ;GAAA;GAAA;GAAA,EAC9B;;AAEF,UAAO;IAAA,gBAAA,OAAA,EACJ,SAAA,sCACC,CAAA;IAAI,gBAAY,sBAAoB;KACpC,UAAS;KACP,MAAM;KACN,IAAC,WAAQ;AACV,aAAA;OAAA,gBAAA,OAAA,EACD,SAAe,2QACb,CAAA;OAAA,gBAAwB,iBAAS;QACjC,MAAA;QACI,UAAU;QACf,MAAA;QACE,CAAA;OAAK,gBAAa,SAAS,EAAA,CAAQ;OAAC,gBAAgB,OAAU;QAC9D,SAAA;QACA,IAAO,WAAE;AACJ,gBAAC,gBAAqB,mBAAsB;UAC/C,IAAA,OAAA;AACO,kBAAA,eAAqB;;UAE5B,cAAA;UACI,CAAA;;QAEP,CAAA;OAAA,gBAAoB,iBAAA;QACrB,MAAS;QACJ,UAAU;QACb,MAAA;QACE,CAAA;OAAA;;KAEJ,CAAC;IAAA,gBAAK,SAAA,EAAA,CAAA;IAAA,gBAAA,OAAA;KACN,IAAA,UAAA;AACC,aAAA,eAAA,YAAA,QAAA,CAAA;;KAEA,IAAA,WAAA;AACA,aAAM,gBAAO,YAAA;OACb,MAAU;OACT,UAAA,IAAA;OACC,CAAA;;KAEH,CAAC;IAAE,gBAAgB,qBAAa;KAC/B,UAAO;KACP,WAAS;KACT,OAAO;KACP,MAAM;KACN,YAAS,CAAA;MACP,MAAM;MACN,MAAM;MACP,CAAC;KACF,IAAG,WAAA;AACD,aAAC,gBAAA,MAAA;OACC,IAAI,OAAI;AACR,eAAS,CAAC,OAAM,WAAY,CAAC,OAAM;;OAEnC,IAAI,WAAA;AACF,eAAA,gBAAA,MAAA;SACN,IAAA,OAAmB;AACrB,iBAAc,CAAA,CAAA,OAAA;;SAEpB,IAAA,WAAA"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
|
|
2
|
+
let _stryke_path_join = require("@stryke/path/join");
|
|
3
|
+
let powerlines_plugin_utils = require("powerlines/plugin-utils");
|
|
4
|
+
let _stryke_path = require("@stryke/path");
|
|
5
|
+
let node_fs = require("node:fs");
|
|
6
|
+
|
|
7
|
+
//#region src/helpers/resolve-changelog.ts
|
|
8
|
+
const CHANGELOG_FILE_EXTENSIONS = [
|
|
9
|
+
"md",
|
|
10
|
+
"markdown",
|
|
11
|
+
"txt"
|
|
12
|
+
];
|
|
13
|
+
const CHANGELOG_FILE_NAMES = [
|
|
14
|
+
"CHANGELOG",
|
|
15
|
+
"changelog",
|
|
16
|
+
"Changelog",
|
|
17
|
+
"RELEASE-NOTES",
|
|
18
|
+
"release-notes",
|
|
19
|
+
"Release-Notes",
|
|
20
|
+
"RELEASE_NOTES",
|
|
21
|
+
"release_notes",
|
|
22
|
+
"Release_Notes",
|
|
23
|
+
"RELEASES",
|
|
24
|
+
"releases",
|
|
25
|
+
"Releases",
|
|
26
|
+
"HISTORY",
|
|
27
|
+
"history",
|
|
28
|
+
"History"
|
|
29
|
+
];
|
|
30
|
+
function resolveChangelogFile(context, fileName) {
|
|
31
|
+
for (const ext of CHANGELOG_FILE_EXTENSIONS) if (fileName && (0, node_fs.existsSync)((0, powerlines_plugin_utils.replacePathTokens)(context, (0, _stryke_path_join.joinPaths)("{root}", (0, _stryke_path.appendExtension)(fileName, ext))))) return (0, _stryke_path_join.joinPaths)("{root}", (0, _stryke_path.appendExtension)(fileName, ext));
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Resolves the path to the changelog file based on the provided options and context. If a specific file is provided in the options, it will attempt to resolve that file first. If not, it will look for common changelog file names in the application's root directory.
|
|
35
|
+
*
|
|
36
|
+
* @param context - The unresolved context of the plugin, which includes information about the application's root directory and other relevant data for resolving paths.
|
|
37
|
+
* @param options - The options provided for the changelog plugin, which may include a specific file name to look for.
|
|
38
|
+
* @returns The resolved path to the changelog file if found, or undefined if no valid changelog file could be resolved.
|
|
39
|
+
*/
|
|
40
|
+
function resolveChangelog(context, options) {
|
|
41
|
+
let changelogFile = resolveChangelogFile(context, options.file);
|
|
42
|
+
if (changelogFile) return changelogFile;
|
|
43
|
+
for (const name of CHANGELOG_FILE_NAMES) {
|
|
44
|
+
changelogFile = resolveChangelogFile(context, name);
|
|
45
|
+
if (changelogFile) return changelogFile;
|
|
46
|
+
}
|
|
47
|
+
return changelogFile;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
//#endregion
|
|
51
|
+
exports.resolveChangelog = resolveChangelog;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { joinPaths } from "@stryke/path/join";
|
|
2
|
+
import { replacePathTokens } from "powerlines/plugin-utils";
|
|
3
|
+
import { appendExtension } from "@stryke/path";
|
|
4
|
+
import { existsSync } from "node:fs";
|
|
5
|
+
|
|
6
|
+
//#region src/helpers/resolve-changelog.ts
|
|
7
|
+
const CHANGELOG_FILE_EXTENSIONS = [
|
|
8
|
+
"md",
|
|
9
|
+
"markdown",
|
|
10
|
+
"txt"
|
|
11
|
+
];
|
|
12
|
+
const CHANGELOG_FILE_NAMES = [
|
|
13
|
+
"CHANGELOG",
|
|
14
|
+
"changelog",
|
|
15
|
+
"Changelog",
|
|
16
|
+
"RELEASE-NOTES",
|
|
17
|
+
"release-notes",
|
|
18
|
+
"Release-Notes",
|
|
19
|
+
"RELEASE_NOTES",
|
|
20
|
+
"release_notes",
|
|
21
|
+
"Release_Notes",
|
|
22
|
+
"RELEASES",
|
|
23
|
+
"releases",
|
|
24
|
+
"Releases",
|
|
25
|
+
"HISTORY",
|
|
26
|
+
"history",
|
|
27
|
+
"History"
|
|
28
|
+
];
|
|
29
|
+
function resolveChangelogFile(context, fileName) {
|
|
30
|
+
for (const ext of CHANGELOG_FILE_EXTENSIONS) if (fileName && existsSync(replacePathTokens(context, joinPaths("{root}", appendExtension(fileName, ext))))) return joinPaths("{root}", appendExtension(fileName, ext));
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Resolves the path to the changelog file based on the provided options and context. If a specific file is provided in the options, it will attempt to resolve that file first. If not, it will look for common changelog file names in the application's root directory.
|
|
34
|
+
*
|
|
35
|
+
* @param context - The unresolved context of the plugin, which includes information about the application's root directory and other relevant data for resolving paths.
|
|
36
|
+
* @param options - The options provided for the changelog plugin, which may include a specific file name to look for.
|
|
37
|
+
* @returns The resolved path to the changelog file if found, or undefined if no valid changelog file could be resolved.
|
|
38
|
+
*/
|
|
39
|
+
function resolveChangelog(context, options) {
|
|
40
|
+
let changelogFile = resolveChangelogFile(context, options.file);
|
|
41
|
+
if (changelogFile) return changelogFile;
|
|
42
|
+
for (const name of CHANGELOG_FILE_NAMES) {
|
|
43
|
+
changelogFile = resolveChangelogFile(context, name);
|
|
44
|
+
if (changelogFile) return changelogFile;
|
|
45
|
+
}
|
|
46
|
+
return changelogFile;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
//#endregion
|
|
50
|
+
export { resolveChangelog };
|
|
51
|
+
//# sourceMappingURL=resolve-changelog.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resolve-changelog.mjs","names":[],"sources":["../../src/helpers/resolve-changelog.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Shell Shock\n\n This code was released as part of the Shell Shock project. Shell Shock\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/shell-shock.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/shell-shock\n Documentation: https://docs.stormsoftware.com/projects/shell-shock\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport type { UnresolvedContext } from \"@shell-shock/core\";\nimport { appendExtension } from \"@stryke/path\";\nimport { joinPaths } from \"@stryke/path/join\";\nimport { existsSync } from \"node:fs\";\nimport { replacePathTokens } from \"powerlines/plugin-utils\";\nimport type { ChangelogPluginOptions } from \"../types/plugin\";\n\nconst CHANGELOG_FILE_EXTENSIONS = [\"md\", \"markdown\", \"txt\"] as const;\n\nconst CHANGELOG_FILE_NAMES = [\n \"CHANGELOG\",\n \"changelog\",\n \"Changelog\",\n \"RELEASE-NOTES\",\n \"release-notes\",\n \"Release-Notes\",\n \"RELEASE_NOTES\",\n \"release_notes\",\n \"Release_Notes\",\n \"RELEASES\",\n \"releases\",\n \"Releases\",\n \"HISTORY\",\n \"history\",\n \"History\"\n] as const;\n\nfunction resolveChangelogFile(\n context: UnresolvedContext,\n fileName?: string\n): string | undefined {\n for (const ext of CHANGELOG_FILE_EXTENSIONS) {\n if (\n fileName &&\n existsSync(\n replacePathTokens(\n context,\n joinPaths(\"{root}\", appendExtension(fileName, ext))\n )\n )\n ) {\n return joinPaths(\"{root}\", appendExtension(fileName, ext));\n }\n }\n\n return undefined;\n}\n\n/**\n * Resolves the path to the changelog file based on the provided options and context. If a specific file is provided in the options, it will attempt to resolve that file first. If not, it will look for common changelog file names in the application's root directory.\n *\n * @param context - The unresolved context of the plugin, which includes information about the application's root directory and other relevant data for resolving paths.\n * @param options - The options provided for the changelog plugin, which may include a specific file name to look for.\n * @returns The resolved path to the changelog file if found, or undefined if no valid changelog file could be resolved.\n */\nexport function resolveChangelog(\n context: UnresolvedContext,\n options: ChangelogPluginOptions\n): string | undefined {\n let changelogFile = resolveChangelogFile(context, options.file);\n if (changelogFile) {\n return changelogFile;\n }\n\n for (const name of CHANGELOG_FILE_NAMES) {\n changelogFile = resolveChangelogFile(context, name);\n if (changelogFile) {\n return changelogFile;\n }\n }\n\n return changelogFile;\n}\n"],"mappings":";;;;;;AAyBA,MAAM,4BAA4B;CAAC;CAAM;CAAY;CAAM;AAE3D,MAAM,uBAAuB;CAC3B;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACD;AAED,SAAS,qBACP,SACA,UACoB;AACpB,MAAK,MAAM,OAAO,0BAChB,KACE,YACA,WACE,kBACE,SACA,UAAU,UAAU,gBAAgB,UAAU,IAAI,CAAC,CACpD,CACF,CAED,QAAO,UAAU,UAAU,gBAAgB,UAAU,IAAI,CAAC;;;;;;;;;AAchE,SAAgB,iBACd,SACA,SACoB;CACpB,IAAI,gBAAgB,qBAAqB,SAAS,QAAQ,KAAK;AAC/D,KAAI,cACF,QAAO;AAGT,MAAK,MAAM,QAAQ,sBAAsB;AACvC,kBAAgB,qBAAqB,SAAS,KAAK;AACnD,MAAI,cACF,QAAO;;AAIX,QAAO"}
|
package/dist/index.cjs
CHANGED
|
@@ -2,6 +2,7 @@ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toString
|
|
|
2
2
|
const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
|
|
3
3
|
const require_components_changelog_command = require('./components/changelog-command.cjs');
|
|
4
4
|
require('./components/index.cjs');
|
|
5
|
+
const require_resolve_changelog = require('./helpers/resolve-changelog.cjs');
|
|
5
6
|
let _alloy_js_core_jsx_runtime = require("@alloy-js/core/jsx-runtime");
|
|
6
7
|
let _powerlines_plugin_alloy_render = require("@powerlines/plugin-alloy/render");
|
|
7
8
|
let _shell_shock_core_plugin_utils = require("@shell-shock/core/plugin-utils");
|
|
@@ -20,30 +21,41 @@ const plugin = (options = {}) => {
|
|
|
20
21
|
name: "shell-shock:changelog",
|
|
21
22
|
config() {
|
|
22
23
|
this.debug("Providing default configuration for the Shell Shock `changelog` plugin.");
|
|
23
|
-
return { changelog: (0, defu.default)({
|
|
24
|
+
return { changelog: (0, defu.default)({
|
|
25
|
+
file: require_resolve_changelog.resolveChangelog(this, options),
|
|
26
|
+
command: { name: (0, _stryke_type_checks_is_set_string.isSetString)(options.command) ? options.command : "changelog" }
|
|
27
|
+
}, options) };
|
|
24
28
|
},
|
|
25
29
|
configResolved() {
|
|
26
30
|
this.debug("Adding the CLI changelog commands to the application context.");
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
31
|
+
if ((0, _stryke_type_checks_is_set_string.isSetString)(this.config.changelog.file)) {
|
|
32
|
+
this.config.changelog.file = (0, powerlines_plugin_utils.replacePathTokens)(this, this.config.changelog.file);
|
|
33
|
+
if (!this.fs.existsSync(this.config.changelog.file)) {
|
|
34
|
+
this.warn(`The changelog file could not be found at the resolved path: ${this.config.changelog.file}. The \`${this.config.changelog.command.name}\` command will not be added to the application. Please ensure that the changelog file exists at the specified path or adjust the \`changelog.file\` option to point to the correct location.`);
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
this.inputs ??= [];
|
|
38
|
+
if (this.inputs.some((input) => input.id === this.config.changelog.command.name)) this.info("The `changelog` command already exists in the commands list. If you would like the changelog command to be managed by the `@shell-shock/plugin-changelog` package, please remove or rename the command.");
|
|
39
|
+
else this.inputs.push({
|
|
40
|
+
id: this.config.changelog.command.name,
|
|
41
|
+
path: this.config.changelog.command.name,
|
|
42
|
+
segments: [this.config.changelog.command.name],
|
|
43
|
+
title: "Changelog",
|
|
44
|
+
icon: "🗃",
|
|
45
|
+
tags: ["Utility"],
|
|
46
|
+
description: `Display the ${(0, _shell_shock_core_plugin_utils.getAppTitle)(this)} changelog.`,
|
|
47
|
+
entry: {
|
|
48
|
+
file: (0, _stryke_path_join.joinPaths)(this.entryPath, "changelog", "index.ts"),
|
|
49
|
+
input: { file: (0, _stryke_path_join.joinPaths)(this.entryPath, "changelog", "command.ts") }
|
|
50
|
+
},
|
|
51
|
+
isVirtual: false,
|
|
52
|
+
source: "changelog-plugin",
|
|
53
|
+
...this.config.changelog.command
|
|
54
|
+
});
|
|
55
|
+
}
|
|
45
56
|
},
|
|
46
57
|
async prepare() {
|
|
58
|
+
if ((0, _stryke_type_checks_is_set_string.isSetString)(this.config.changelog.file) && !this.fs.existsSync(this.config.changelog.file)) return;
|
|
47
59
|
this.debug("Rendering changelog command module for the Shell Shock `changelog` plugin.");
|
|
48
60
|
return (0, _powerlines_plugin_alloy_render.render)(this, (0, _alloy_js_core_jsx_runtime.createComponent)(require_components_changelog_command.ChangelogCommand, {}));
|
|
49
61
|
}
|
package/dist/index.d.cts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.tsx"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.tsx"],"mappings":";;;;;;AAqCA;cAAa,MAAA,oBACM,sBAAA,GAAyB,sBAAA,EAE1C,OAAA,GAAS,sBAAA,KACR,MAAA,CAAO,QAAA"}
|
package/dist/index.d.mts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.tsx"],"mappings":";;;;;;
|
|
1
|
+
{"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.tsx"],"mappings":";;;;;;AAqCA;cAAa,MAAA,oBACM,sBAAA,GAAyB,sBAAA,EAE1C,OAAA,GAAS,sBAAA,KACR,MAAA,CAAO,QAAA"}
|
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ChangelogCommand } from "./components/changelog-command.mjs";
|
|
2
2
|
import "./components/index.mjs";
|
|
3
|
+
import { resolveChangelog } from "./helpers/resolve-changelog.mjs";
|
|
3
4
|
import { createComponent } from "@alloy-js/core/jsx-runtime";
|
|
4
5
|
import { render } from "@powerlines/plugin-alloy/render";
|
|
5
6
|
import { getAppTitle } from "@shell-shock/core/plugin-utils";
|
|
@@ -17,30 +18,41 @@ const plugin = (options = {}) => {
|
|
|
17
18
|
name: "shell-shock:changelog",
|
|
18
19
|
config() {
|
|
19
20
|
this.debug("Providing default configuration for the Shell Shock `changelog` plugin.");
|
|
20
|
-
return { changelog: defu({
|
|
21
|
+
return { changelog: defu({
|
|
22
|
+
file: resolveChangelog(this, options),
|
|
23
|
+
command: { name: isSetString(options.command) ? options.command : "changelog" }
|
|
24
|
+
}, options) };
|
|
21
25
|
},
|
|
22
26
|
configResolved() {
|
|
23
27
|
this.debug("Adding the CLI changelog commands to the application context.");
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
28
|
+
if (isSetString(this.config.changelog.file)) {
|
|
29
|
+
this.config.changelog.file = replacePathTokens(this, this.config.changelog.file);
|
|
30
|
+
if (!this.fs.existsSync(this.config.changelog.file)) {
|
|
31
|
+
this.warn(`The changelog file could not be found at the resolved path: ${this.config.changelog.file}. The \`${this.config.changelog.command.name}\` command will not be added to the application. Please ensure that the changelog file exists at the specified path or adjust the \`changelog.file\` option to point to the correct location.`);
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
this.inputs ??= [];
|
|
35
|
+
if (this.inputs.some((input) => input.id === this.config.changelog.command.name)) this.info("The `changelog` command already exists in the commands list. If you would like the changelog command to be managed by the `@shell-shock/plugin-changelog` package, please remove or rename the command.");
|
|
36
|
+
else this.inputs.push({
|
|
37
|
+
id: this.config.changelog.command.name,
|
|
38
|
+
path: this.config.changelog.command.name,
|
|
39
|
+
segments: [this.config.changelog.command.name],
|
|
40
|
+
title: "Changelog",
|
|
41
|
+
icon: "🗃",
|
|
42
|
+
tags: ["Utility"],
|
|
43
|
+
description: `Display the ${getAppTitle(this)} changelog.`,
|
|
44
|
+
entry: {
|
|
45
|
+
file: joinPaths(this.entryPath, "changelog", "index.ts"),
|
|
46
|
+
input: { file: joinPaths(this.entryPath, "changelog", "command.ts") }
|
|
47
|
+
},
|
|
48
|
+
isVirtual: false,
|
|
49
|
+
source: "changelog-plugin",
|
|
50
|
+
...this.config.changelog.command
|
|
51
|
+
});
|
|
52
|
+
}
|
|
42
53
|
},
|
|
43
54
|
async prepare() {
|
|
55
|
+
if (isSetString(this.config.changelog.file) && !this.fs.existsSync(this.config.changelog.file)) return;
|
|
44
56
|
this.debug("Rendering changelog command module for the Shell Shock `changelog` plugin.");
|
|
45
57
|
return render(this, createComponent(ChangelogCommand, {}));
|
|
46
58
|
}
|
package/dist/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","names":[],"sources":["../src/index.tsx"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Shell Shock\n\n This code was released as part of the Shell Shock project. Shell Shock\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/shell-shock.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/shell-shock\n Documentation: https://docs.stormsoftware.com/projects/shell-shock\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { render } from \"@powerlines/plugin-alloy/render\";\nimport { getAppTitle } from \"@shell-shock/core/plugin-utils\";\nimport { joinPaths } from \"@stryke/path/join\";\nimport { isSetString } from \"@stryke/type-checks/is-set-string\";\nimport defu from \"defu\";\nimport type { Plugin } from \"powerlines\";\nimport { replacePathTokens } from \"powerlines/plugin-utils\";\nimport { ChangelogCommand } from \"./components\";\nimport type {\n ChangelogPluginContext,\n ChangelogPluginOptions\n} from \"./types/plugin\";\n\nexport type * from \"./types\";\n\n/**\n * The Changelog - Shell Shock plugin to add version check functionality and changelog commands to a Shell Shock application.\n */\nexport const plugin = <\n TContext extends ChangelogPluginContext = ChangelogPluginContext\n>(\n options: ChangelogPluginOptions = {}\n): Plugin<TContext> => {\n return {\n name: \"shell-shock:changelog\",\n config() {\n this.debug(\n \"Providing default configuration for the Shell Shock `changelog` plugin.\"\n );\n\n return {\n changelog: defu(\n {\n command: {\n name: isSetString(options.command) ? options.command : \"changelog\"\n }\n },\n options
|
|
1
|
+
{"version":3,"file":"index.mjs","names":[],"sources":["../src/index.tsx"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Shell Shock\n\n This code was released as part of the Shell Shock project. Shell Shock\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/shell-shock.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/shell-shock\n Documentation: https://docs.stormsoftware.com/projects/shell-shock\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { render } from \"@powerlines/plugin-alloy/render\";\nimport { getAppTitle } from \"@shell-shock/core/plugin-utils\";\nimport { joinPaths } from \"@stryke/path/join\";\nimport { isSetString } from \"@stryke/type-checks/is-set-string\";\nimport defu from \"defu\";\nimport type { Plugin } from \"powerlines\";\nimport { replacePathTokens } from \"powerlines/plugin-utils\";\nimport { ChangelogCommand } from \"./components\";\nimport { resolveChangelog } from \"./helpers/resolve-changelog\";\nimport type {\n ChangelogPluginContext,\n ChangelogPluginOptions\n} from \"./types/plugin\";\n\nexport type * from \"./types\";\n\n/**\n * The Changelog - Shell Shock plugin to add version check functionality and changelog commands to a Shell Shock application.\n */\nexport const plugin = <\n TContext extends ChangelogPluginContext = ChangelogPluginContext\n>(\n options: ChangelogPluginOptions = {}\n): Plugin<TContext> => {\n return {\n name: \"shell-shock:changelog\",\n config() {\n this.debug(\n \"Providing default configuration for the Shell Shock `changelog` plugin.\"\n );\n\n return {\n changelog: defu(\n {\n file: resolveChangelog(this, options),\n command: {\n name: isSetString(options.command) ? options.command : \"changelog\"\n }\n },\n options\n )\n };\n },\n configResolved() {\n this.debug(\n \"Adding the CLI changelog commands to the application context.\"\n );\n\n if (isSetString(this.config.changelog.file)) {\n this.config.changelog.file = replacePathTokens(\n this,\n this.config.changelog.file\n );\n\n if (!this.fs.existsSync(this.config.changelog.file)) {\n this.warn(\n `The changelog file could not be found at the resolved path: ${\n this.config.changelog.file\n }. The \\`${\n this.config.changelog.command.name\n }\\` command will not be added to the application. Please ensure that the changelog file exists at the specified path or adjust the \\`changelog.file\\` option to point to the correct location.`\n );\n return;\n }\n\n this.inputs ??= [];\n if (\n this.inputs.some(\n input => input.id === this.config.changelog.command.name\n )\n ) {\n this.info(\n \"The `changelog` command already exists in the commands list. If you would like the changelog command to be managed by the `@shell-shock/plugin-changelog` package, please remove or rename the command.\"\n );\n } else {\n this.inputs.push({\n id: this.config.changelog.command.name,\n path: this.config.changelog.command.name,\n segments: [this.config.changelog.command.name],\n title: \"Changelog\",\n icon: \"🗃\",\n tags: [\"Utility\"],\n description: `Display the ${getAppTitle(this)} changelog.`,\n entry: {\n file: joinPaths(this.entryPath, \"changelog\", \"index.ts\"),\n input: {\n file: joinPaths(this.entryPath, \"changelog\", \"command.ts\")\n }\n },\n isVirtual: false,\n source: \"changelog-plugin\",\n ...this.config.changelog.command\n });\n }\n }\n },\n async prepare() {\n if (\n isSetString(this.config.changelog.file) &&\n !this.fs.existsSync(this.config.changelog.file)\n ) {\n return;\n }\n\n this.debug(\n \"Rendering changelog command module for the Shell Shock `changelog` plugin.\"\n );\n\n return render(this, <ChangelogCommand />);\n }\n };\n};\n\nexport default plugin;\n"],"mappings":";;;;;;;;;;;;;;;AAkCA,MAAE,UAAA,UAAA,EAAA,KAAA;AACA,QAAK;EACL,MAAA;EACF,SAAa;AACX,QAAS,MAAA,0EAAiC;AAC3C,UAAA,EACC,WAAS,KAAA;IACD,MAAA,iBAAa,MAAA,QAAA;IACd,SAAA,EACE,MAAM,YAAM,QAAU,QAAA,GAAA,QAAA,UAAA,aACtB;IACL,EAAK,QAAK,EACT;;;AAGD,QAAA,MAAO,gEAAA;AACP,OAAE,YAAW,KAAI,OAAA,UAAA,KAAA,EAAA;AACf,SAAE,OAAA,UAAA,OAAA,kBAAA,MAAA,KAAA,OAAA,UAAA,KAAA;AACF,QAAI,CAAA,KAAM,GAAA,WAAA,KAAiB,OAAM,UAAQ,KAAA,EAAA;AACvC,UAAE,KAAQ,+DAAC,KAAA,OAAA,UAAA,KAAA,UAAA,KAAA,OAAA,UAAA,QAAA,KAAA,+LAAA;AACX;;AAEF,SAAG,WAAA,EAAA;AACH,QAAE,KAAA,OAAA,MAAA,UAAA,MAAA,OAAA,KAAA,OAAA,UAAA,QAAA,KAAA,CACF,MAAA,KAAA,0MAAA;QAEH,MAAA,OAAA,KAAA;KACD,IAAA,KAAiB,OAAA,UAAA,QAAA;KACV,MAAK,KAAA,OAAA,UAAA,QAAA;KACP,UAAW,CAAG,KAAC,OAAU,UAAW,QAAK,KAAA;KAC3C,OAAA;;KAEG,MAAA,CAAA,UAAiB;KACf,aAAQ,eAAiB,YAAA,KAAiB,CAAA;KAC5C,OAAI;MACA,MAAC,UAAO,KAAU,WAAA,aAAA,WAAA;MACvB,OAAA,8DAEI;MACH;KACE,WAAK;KACL,QAAO;KACP,GAAG,KAAK,OAAE,UAAA;KACX,CAAC;;;EAIR,MAAI,UAAA;kGAEA;AAEF,QAAI,MAAK,6EAAW;AACpB,UAAM,OAAQ,MAAM,gBAAa,kBAAiB,EAAQ,CAAA,CAAA;;EAE7D"}
|
package/dist/types/plugin.d.cts
CHANGED
|
@@ -6,6 +6,54 @@ interface ChangelogPluginOptions {
|
|
|
6
6
|
/**
|
|
7
7
|
* The path to the changelog file to read when executing the `changelog` command. This can be an absolute path or a path relative to the application's root directory.
|
|
8
8
|
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* If not provided, the plugin will attempt to resolve the changelog file by looking for common changelog file names (e.g., `CHANGELOG.md`, `RELEASE-NOTES.md`, etc.) in the application's root directory. If a specific file name is provided but cannot be found, it will fall back to looking for common changelog file names. If no valid changelog file can be resolved, the `changelog` command will not be added to the application. The following list of common changelog file names will be used for resolution:
|
|
11
|
+
* - `CHANGELOG.md`
|
|
12
|
+
* - `changelog.md`
|
|
13
|
+
* - `Changelog.md`
|
|
14
|
+
* - `CHANGELOG.markdown`
|
|
15
|
+
* - `changelog.markdown`
|
|
16
|
+
* - `Changelog.markdown`
|
|
17
|
+
* - `CHANGELOG.txt`
|
|
18
|
+
* - `changelog.txt`
|
|
19
|
+
* - `Changelog.txt`
|
|
20
|
+
* - `RELEASE-NOTES.md`
|
|
21
|
+
* - `release-notes.md`
|
|
22
|
+
* - `Release-Notes.md`
|
|
23
|
+
* - `RELEASE-NOTES.markdown`
|
|
24
|
+
* - `release-notes.markdown`
|
|
25
|
+
* - `Release-Notes.markdown`
|
|
26
|
+
* - `RELEASE-NOTES.txt`
|
|
27
|
+
* - `release-notes.txt`
|
|
28
|
+
* - `Release-Notes.txt`
|
|
29
|
+
* - `RELEASE_NOTES.md`
|
|
30
|
+
* - `release_notes.md`
|
|
31
|
+
* - `Release_Notes.md`
|
|
32
|
+
* - `RELEASE_NOTES.markdown`
|
|
33
|
+
* - `release_notes.markdown`
|
|
34
|
+
* - `Release_Notes.markdown`
|
|
35
|
+
* - `RELEASE_NOTES.txt`
|
|
36
|
+
* - `release_notes.txt`
|
|
37
|
+
* - `Release_Notes.txt`
|
|
38
|
+
* - `RELEASES.md`
|
|
39
|
+
* - `releases.md`
|
|
40
|
+
* - `Releases.md`
|
|
41
|
+
* - `RELEASES.markdown`
|
|
42
|
+
* - `releases.markdown`
|
|
43
|
+
* - `Releases.markdown`
|
|
44
|
+
* - `RELEASES.txt`
|
|
45
|
+
* - `releases.txt`
|
|
46
|
+
* - `Releases.txt`
|
|
47
|
+
* - `HISTORY.md`
|
|
48
|
+
* - `history.md`
|
|
49
|
+
* - `History.md`
|
|
50
|
+
* - `HISTORY.markdown`
|
|
51
|
+
* - `history.markdown`
|
|
52
|
+
* - `History.markdown`
|
|
53
|
+
* - `HISTORY.txt`
|
|
54
|
+
* - `history.txt`
|
|
55
|
+
* - `History.txt`
|
|
56
|
+
*
|
|
9
57
|
* @defaultValue "\{root\}/CHANGELOG.md"
|
|
10
58
|
*/
|
|
11
59
|
file?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.d.cts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":";;;;UA0BiB,sBAAA;;AAAjB
|
|
1
|
+
{"version":3,"file":"plugin.d.cts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":";;;;UA0BiB,sBAAA;;AAAjB;;;;;;;;;;AAmEA;;;;;;;;;AAOA;;;;;;;;;;;;;;;;;;;;;;;AAYA;;;;;;;;;;EAhCE,IAAA;EAkCE;;;;;;;;EAxBF,OAAA,GAAU,OAAA,CAAQ,aAAA;AAAA;AAAA,KAGR,yBAAA,GAA4B,UAAA;;;;EAItC,SAAA,EAAW,sBAAA;AAAA;AAAA,KAGD,6BAAA,GAAgC,cAAA;;;;EAI1C,SAAA,EAAW,QAAA,CAAS,IAAA,CAAK,sBAAA;;;;IAIvB,OAAA,EAAS,YAAA,CAAa,OAAA,CAAQ,aAAA;EAAA;AAAA;AAAA,KAItB,sBAAA,yBACc,6BAAA,GACtB,6BAAA,IACA,OAAA,CAAQ,eAAA"}
|
package/dist/types/plugin.d.mts
CHANGED
|
@@ -6,6 +6,54 @@ interface ChangelogPluginOptions {
|
|
|
6
6
|
/**
|
|
7
7
|
* The path to the changelog file to read when executing the `changelog` command. This can be an absolute path or a path relative to the application's root directory.
|
|
8
8
|
*
|
|
9
|
+
* @remarks
|
|
10
|
+
* If not provided, the plugin will attempt to resolve the changelog file by looking for common changelog file names (e.g., `CHANGELOG.md`, `RELEASE-NOTES.md`, etc.) in the application's root directory. If a specific file name is provided but cannot be found, it will fall back to looking for common changelog file names. If no valid changelog file can be resolved, the `changelog` command will not be added to the application. The following list of common changelog file names will be used for resolution:
|
|
11
|
+
* - `CHANGELOG.md`
|
|
12
|
+
* - `changelog.md`
|
|
13
|
+
* - `Changelog.md`
|
|
14
|
+
* - `CHANGELOG.markdown`
|
|
15
|
+
* - `changelog.markdown`
|
|
16
|
+
* - `Changelog.markdown`
|
|
17
|
+
* - `CHANGELOG.txt`
|
|
18
|
+
* - `changelog.txt`
|
|
19
|
+
* - `Changelog.txt`
|
|
20
|
+
* - `RELEASE-NOTES.md`
|
|
21
|
+
* - `release-notes.md`
|
|
22
|
+
* - `Release-Notes.md`
|
|
23
|
+
* - `RELEASE-NOTES.markdown`
|
|
24
|
+
* - `release-notes.markdown`
|
|
25
|
+
* - `Release-Notes.markdown`
|
|
26
|
+
* - `RELEASE-NOTES.txt`
|
|
27
|
+
* - `release-notes.txt`
|
|
28
|
+
* - `Release-Notes.txt`
|
|
29
|
+
* - `RELEASE_NOTES.md`
|
|
30
|
+
* - `release_notes.md`
|
|
31
|
+
* - `Release_Notes.md`
|
|
32
|
+
* - `RELEASE_NOTES.markdown`
|
|
33
|
+
* - `release_notes.markdown`
|
|
34
|
+
* - `Release_Notes.markdown`
|
|
35
|
+
* - `RELEASE_NOTES.txt`
|
|
36
|
+
* - `release_notes.txt`
|
|
37
|
+
* - `Release_Notes.txt`
|
|
38
|
+
* - `RELEASES.md`
|
|
39
|
+
* - `releases.md`
|
|
40
|
+
* - `Releases.md`
|
|
41
|
+
* - `RELEASES.markdown`
|
|
42
|
+
* - `releases.markdown`
|
|
43
|
+
* - `Releases.markdown`
|
|
44
|
+
* - `RELEASES.txt`
|
|
45
|
+
* - `releases.txt`
|
|
46
|
+
* - `Releases.txt`
|
|
47
|
+
* - `HISTORY.md`
|
|
48
|
+
* - `history.md`
|
|
49
|
+
* - `History.md`
|
|
50
|
+
* - `HISTORY.markdown`
|
|
51
|
+
* - `history.markdown`
|
|
52
|
+
* - `History.markdown`
|
|
53
|
+
* - `HISTORY.txt`
|
|
54
|
+
* - `history.txt`
|
|
55
|
+
* - `History.txt`
|
|
56
|
+
*
|
|
9
57
|
* @defaultValue "\{root\}/CHANGELOG.md"
|
|
10
58
|
*/
|
|
11
59
|
file?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.d.mts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":";;;;UA0BiB,sBAAA;;AAAjB
|
|
1
|
+
{"version":3,"file":"plugin.d.mts","names":[],"sources":["../../src/types/plugin.ts"],"mappings":";;;;UA0BiB,sBAAA;;AAAjB;;;;;;;;;;AAmEA;;;;;;;;;AAOA;;;;;;;;;;;;;;;;;;;;;;;AAYA;;;;;;;;;;EAhCE,IAAA;EAkCE;;;;;;;;EAxBF,OAAA,GAAU,OAAA,CAAQ,aAAA;AAAA;AAAA,KAGR,yBAAA,GAA4B,UAAA;;;;EAItC,SAAA,EAAW,sBAAA;AAAA;AAAA,KAGD,6BAAA,GAAgC,cAAA;;;;EAI1C,SAAA,EAAW,QAAA,CAAS,IAAA,CAAK,sBAAA;;;;IAIvB,OAAA,EAAS,YAAA,CAAa,OAAA,CAAQ,aAAA;EAAA;AAAA;AAAA,KAItB,sBAAA,yBACc,6BAAA,GACtB,6BAAA,IACA,OAAA,CAAQ,eAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shell-shock/plugin-changelog",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.6",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "A package containing a Shell Shock plugin to manage upgrading the local application's version.",
|
|
6
6
|
"keywords": [
|
|
@@ -125,20 +125,20 @@
|
|
|
125
125
|
"dependencies": {
|
|
126
126
|
"@alloy-js/core": "0.23.0-dev.8",
|
|
127
127
|
"@alloy-js/typescript": "0.23.0-dev.4",
|
|
128
|
-
"@powerlines/deepkit": "^0.
|
|
129
|
-
"@powerlines/plugin-alloy": "^0.26.
|
|
130
|
-
"@powerlines/plugin-plugin": "^0.12.
|
|
131
|
-
"@shell-shock/core": "^0.17.
|
|
132
|
-
"@shell-shock/unified": "^0.1
|
|
128
|
+
"@powerlines/deepkit": "^0.8.0",
|
|
129
|
+
"@powerlines/plugin-alloy": "^0.26.15",
|
|
130
|
+
"@powerlines/plugin-plugin": "^0.12.347",
|
|
131
|
+
"@shell-shock/core": "^0.17.3",
|
|
132
|
+
"@shell-shock/unified": "^0.2.1",
|
|
133
133
|
"@stryke/path": "^0.27.4",
|
|
134
134
|
"@stryke/type-checks": "^0.6.1",
|
|
135
135
|
"@stryke/types": "^0.11.3",
|
|
136
136
|
"defu": "^6.1.7",
|
|
137
|
-
"powerlines": "^0.42.
|
|
137
|
+
"powerlines": "^0.42.37"
|
|
138
138
|
},
|
|
139
139
|
"devDependencies": {
|
|
140
|
-
"@powerlines/plugin-deepkit": "^0.11.
|
|
141
|
-
"@types/node": "^25.
|
|
140
|
+
"@powerlines/plugin-deepkit": "^0.11.277",
|
|
141
|
+
"@types/node": "^25.6.0"
|
|
142
142
|
},
|
|
143
143
|
"publishConfig": {
|
|
144
144
|
"access": "public",
|
|
@@ -155,5 +155,5 @@
|
|
|
155
155
|
"./package.json": "./package.json"
|
|
156
156
|
}
|
|
157
157
|
},
|
|
158
|
-
"gitHead": "
|
|
158
|
+
"gitHead": "d6ec6746792a83206915332c4eb87c9da70a5148"
|
|
159
159
|
}
|