@jeromefitz/semantic 11.1.9-canary.2 → 12.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.
@@ -1 +1 @@
1
- {"version":3,"file":"getConfig-BPDDTk71.mjs","names":["releaseRules","releaseRulesDefault"],"sources":["../src/plugins/commitAnalyzer.ts","../src/plugins/git.ts","../src/plugins/github.ts","../src/plugins/npm.ts","../src/plugins/pluginOptions.ts","../src/getConfig.ts"],"sourcesContent":["import type { IReleaseRule } from '@jeromefitz/conventional-gitmoji'\n\nimport type { PluginSpec } from 'semantic-release'\n\nimport { releaseRules as releaseRulesDefault } from '@jeromefitz/conventional-gitmoji'\n\nconst commitAnalyzer = (releaseRulesPassed: IReleaseRule[] = []): PluginSpec => {\n const releaseRules = [...releaseRulesDefault, ...releaseRulesPassed]\n\n return [\n '@semantic-release/commit-analyzer',\n {\n config: '@jeromefitz/conventional-gitmoji',\n releaseRules,\n },\n ]\n}\n\nexport { commitAnalyzer }\n","import type { PluginSpec } from 'semantic-release'\n\nimport type { GitPluginOptions } from './git.types.js'\n\n/**\n * @note\n *\n * This will modify `package.json` use with caution\n * Most times you will skip this package and only use NPM publishing\n *\n */\nconst git = (options: GitPluginOptions): PluginSpec => {\n return [\n '@semantic-release/git',\n {\n assets:\n typeof options.gitAssets === 'boolean'\n ? false\n : ['package.json']\n // biome-ignore lint/complexity/noExtraBooleanCast: migrate\n .concat(!!options.gitAssets ? options.gitAssets : [])\n .filter((a) => a),\n message: options.message\n ? options.message\n : // biome-ignore lint/suspicious/noTemplateCurlyInString: migrate\n '🔖️ `${nextRelease.gitTag}` [skip ci] \\n\\n${nextRelease.notes}',\n },\n ]\n}\n\nexport { git }\n","import type { PluginSpec } from 'semantic-release'\n\nimport type { GithubPluginOptions } from './github.types.js'\n\nconst github = (options: GithubPluginOptions = {}): PluginSpec => {\n const optionsEmpty =\n options &&\n Object.values(options).filter((i) => typeof i !== 'undefined').length === 0\n\n if (!options || optionsEmpty)\n return [\n '@semantic-release/github',\n {\n // @note(github) ensure someone has to override to put these on, haha\n addReleases: false,\n labels: false,\n releasedLabels: false,\n successComment: false,\n },\n ]\n\n const { githubAssets, ...config } = options\n return [\n '@semantic-release/github',\n {\n // @note(github) ensure someone has to override to put these on, haha\n addReleases: false,\n assets: githubAssets,\n labels: false,\n releasedLabels: false,\n successComment: false,\n ...config,\n },\n ]\n}\n\nexport { github }\n","import type { PluginSpec } from 'semantic-release'\n\nimport type { NPMPluginOptions } from './npm.types.js'\n\nconst npm = (options?: NPMPluginOptions): PluginSpec => {\n if (\n !options ||\n (typeof options.pkgRoot !== 'string' &&\n typeof options.npmPublish !== 'boolean' &&\n typeof options.tarballDir === 'undefined')\n )\n return '@semantic-release/npm'\n\n return [\n '@semantic-release/npm',\n {\n // npmPublish: true,\n // tarballDir: 'release',\n // @note this may be oddly expensive\n // @ref https://prateeksurana.me/blog/why-using-object-spread-with-reduce-bad-idea/\n ...options,\n },\n ]\n}\n\nexport { npm }\n","import type { PluginSpec } from 'semantic-release'\n\nimport type { PluginOptions } from './pluginOptions.types.js'\n\nimport { parserOpts, writerOpts } from '@jeromefitz/conventional-gitmoji'\n\nimport { commitAnalyzer, git, github, npm } from './index.js'\n\nconst getPluginOptions = (optionsPassed?: PluginOptions): PluginSpec[] => {\n const optionsDefault = {\n /**\n * @note Will only load the plugin if set to true\n */\n enableGit: false,\n enableGithub: true,\n enableNpm: true,\n enableReleaseNotes: false,\n enableReleaseNotesCustom: true,\n /**\n * @note Customized defaults\n */\n pkgRoot: './dist',\n // tarballDir: 'release',\n }\n\n /**\n * @todo(types) any\n */\n const options: any | PluginOptions = {\n ...optionsDefault,\n ...optionsPassed,\n }\n\n const releaseNotesConfig = [\n '@semantic-release/release-notes-generator',\n {\n config: '@jeromefitz/conventional-gitmoji',\n parserOpts,\n writerOpts,\n },\n ]\n const releaseNotesCustomConfig = [\n '@jeromefitz/release-notes-generator',\n {\n config: '@jeromefitz/conventional-gitmoji',\n },\n ]\n\n const { npmPublish, pkgRoot, tarballDir } = options\n const npmConfig = npm({ npmPublish, pkgRoot, tarballDir })\n\n const {\n addReleases,\n assignees,\n failComment,\n failTitle,\n githubApiPathPrefix,\n githubAssets,\n githubUrl,\n labels,\n proxy,\n releasedLabels,\n } = options\n const githubConfig = github({\n addReleases,\n assignees,\n failComment,\n failTitle,\n githubApiPathPrefix,\n githubAssets,\n githubUrl,\n labels,\n proxy,\n releasedLabels,\n })\n\n const gitConfig = git(options)\n\n const _plugins: any = [\n commitAnalyzer(options.releaseRules),\n options.enableReleaseNotes ? releaseNotesConfig : '',\n options.enableReleaseNotesCustom ? releaseNotesCustomConfig : '',\n options.enableNpm ? npmConfig : '',\n options.enableGithub ? githubConfig : '',\n options.enableGit ? gitConfig : '',\n ]\n\n const plugins: PluginSpec[] = _plugins.filter((plugin) => !!plugin)\n\n return plugins\n}\n\nexport { getPluginOptions }\n","import type { Options as SemanticReleaseOptions } from 'semantic-release'\n\nimport { getPluginOptions } from './plugins/index.js'\n\n/**\n * @todo\n * - config type\n * - - merge = with defaults\n * - - override = takeover completely\n *\n */\nconst getConfig = (configPassed = {}): SemanticReleaseOptions => {\n const plugins = getPluginOptions(configPassed)\n // const configInit: SemanticReleaseOptions = {\n const configInit: any = {\n branches: [{ name: 'main' }, { name: 'canary', prerelease: 'canary' }],\n extends: ['semantic-release-commit-filter'],\n plugins,\n tagFormat: `v\\${version}`,\n }\n\n const config: SemanticReleaseOptions = {\n ...configInit,\n ...configPassed,\n }\n\n return config\n}\n\nexport { getConfig }\n"],"mappings":"gGAMA,MAAM,GAAkB,EAAqC,EAAE,GAGtD,CACL,oCACA,CACE,OAAQ,mCACR,aANiB,CAAC,GAAGC,EAAqB,GAAG,EAAmB,CAOjE,CACF,CCJG,EAAO,GACJ,CACL,wBACA,CACE,OACE,OAAO,EAAQ,WAAc,UACzB,GACA,CAAC,eAAe,CAEb,OAAS,EAAQ,UAAY,EAAQ,UAAY,EAAE,CAAC,CACpD,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Y,EAAY,GACjC,CAEsC,OAAQ,GAAW,CAAC,CAAC,EAAO,EC5E/D,GAAa,EAAe,EAAE,IAUK,CANrC,SAAU,CAAC,CAAE,KAAM,OAAQ,CAAE,CAAE,KAAM,SAAU,WAAY,SAAU,CAAC,CACtE,QAAS,CAAC,iCAAiC,CAC3C,QALc,EAAiB,EAAa,CAM5C,UAAW,cAKX,GAAG,EACJ"}
1
+ {"version":3,"file":"getConfig-BPDDTk71.mjs","names":["releaseRules","releaseRulesDefault"],"sources":["../src/plugins/commitAnalyzer.ts","../src/plugins/git.ts","../src/plugins/github.ts","../src/plugins/npm.ts","../src/plugins/pluginOptions.ts","../src/getConfig.ts"],"sourcesContent":["import type { IReleaseRule } from '@jeromefitz/conventional-gitmoji'\n\nimport type { PluginSpec } from 'semantic-release'\n\nimport { releaseRules as releaseRulesDefault } from '@jeromefitz/conventional-gitmoji'\n\nconst commitAnalyzer = (releaseRulesPassed: IReleaseRule[] = []): PluginSpec => {\n const releaseRules = [...releaseRulesDefault, ...releaseRulesPassed]\n\n return [\n '@semantic-release/commit-analyzer',\n {\n config: '@jeromefitz/conventional-gitmoji',\n releaseRules,\n },\n ]\n}\n\nexport { commitAnalyzer }\n","import type { PluginSpec } from 'semantic-release'\n\nimport type { GitPluginOptions } from './git.types'\n\n/**\n * @note\n *\n * This will modify `package.json` use with caution\n * Most times you will skip this package and only use NPM publishing\n *\n */\nconst git = (options: GitPluginOptions): PluginSpec => {\n return [\n '@semantic-release/git',\n {\n assets:\n typeof options.gitAssets === 'boolean'\n ? false\n : ['package.json']\n // biome-ignore lint/complexity/noExtraBooleanCast: migrate\n .concat(!!options.gitAssets ? options.gitAssets : [])\n .filter((a) => a),\n message: options.message\n ? options.message\n : // biome-ignore lint/suspicious/noTemplateCurlyInString: migrate\n '🔖️ `${nextRelease.gitTag}` [skip ci] \\n\\n${nextRelease.notes}',\n },\n ]\n}\n\nexport { git }\n","import type { PluginSpec } from 'semantic-release'\n\nimport type { GithubPluginOptions } from './github.types'\n\nconst github = (options: GithubPluginOptions = {}): PluginSpec => {\n const optionsEmpty =\n options &&\n Object.values(options).filter((i) => typeof i !== 'undefined').length === 0\n\n if (!options || optionsEmpty)\n return [\n '@semantic-release/github',\n {\n // @note(github) ensure someone has to override to put these on, haha\n addReleases: false,\n labels: false,\n releasedLabels: false,\n successComment: false,\n },\n ]\n\n const { githubAssets, ...config } = options\n return [\n '@semantic-release/github',\n {\n // @note(github) ensure someone has to override to put these on, haha\n addReleases: false,\n assets: githubAssets,\n labels: false,\n releasedLabels: false,\n successComment: false,\n ...config,\n },\n ]\n}\n\nexport { github }\n","import type { PluginSpec } from 'semantic-release'\n\nimport type { NPMPluginOptions } from './npm.types'\n\nconst npm = (options?: NPMPluginOptions): PluginSpec => {\n if (\n !options ||\n (typeof options.pkgRoot !== 'string' &&\n typeof options.npmPublish !== 'boolean' &&\n typeof options.tarballDir === 'undefined')\n )\n return '@semantic-release/npm'\n\n return [\n '@semantic-release/npm',\n {\n // npmPublish: true,\n // tarballDir: 'release',\n // @note this may be oddly expensive\n // @ref https://prateeksurana.me/blog/why-using-object-spread-with-reduce-bad-idea/\n ...options,\n },\n ]\n}\n\nexport { npm }\n","import type { PluginSpec } from 'semantic-release'\n\nimport type { PluginOptions } from './pluginOptions.types'\n\nimport { parserOpts, writerOpts } from '@jeromefitz/conventional-gitmoji'\n\nimport { commitAnalyzer, git, github, npm } from './index'\n\nconst getPluginOptions = (optionsPassed?: PluginOptions): PluginSpec[] => {\n const optionsDefault = {\n /**\n * @note Will only load the plugin if set to true\n */\n enableGit: false,\n enableGithub: true,\n enableNpm: true,\n enableReleaseNotes: false,\n enableReleaseNotesCustom: true,\n /**\n * @note Customized defaults\n */\n pkgRoot: './dist',\n // tarballDir: 'release',\n }\n\n /**\n * @todo(types) any\n */\n const options: any | PluginOptions = {\n ...optionsDefault,\n ...optionsPassed,\n }\n\n const releaseNotesConfig = [\n '@semantic-release/release-notes-generator',\n {\n config: '@jeromefitz/conventional-gitmoji',\n parserOpts,\n writerOpts,\n },\n ]\n const releaseNotesCustomConfig = [\n '@jeromefitz/release-notes-generator',\n {\n config: '@jeromefitz/conventional-gitmoji',\n },\n ]\n\n const { npmPublish, pkgRoot, tarballDir } = options\n const npmConfig = npm({ npmPublish, pkgRoot, tarballDir })\n\n const {\n addReleases,\n assignees,\n failComment,\n failTitle,\n githubApiPathPrefix,\n githubAssets,\n githubUrl,\n labels,\n proxy,\n releasedLabels,\n } = options\n const githubConfig = github({\n addReleases,\n assignees,\n failComment,\n failTitle,\n githubApiPathPrefix,\n githubAssets,\n githubUrl,\n labels,\n proxy,\n releasedLabels,\n })\n\n const gitConfig = git(options)\n\n const _plugins: any = [\n commitAnalyzer(options.releaseRules),\n options.enableReleaseNotes ? releaseNotesConfig : '',\n options.enableReleaseNotesCustom ? releaseNotesCustomConfig : '',\n options.enableNpm ? npmConfig : '',\n options.enableGithub ? githubConfig : '',\n options.enableGit ? gitConfig : '',\n ]\n\n const plugins: PluginSpec[] = _plugins.filter((plugin) => !!plugin)\n\n return plugins\n}\n\nexport { getPluginOptions }\n","import type { Options as SemanticReleaseOptions } from 'semantic-release'\n\nimport { getPluginOptions } from './plugins/index'\n\n/**\n * @todo\n * - config type\n * - - merge = with defaults\n * - - override = takeover completely\n *\n */\nconst getConfig = (configPassed = {}): SemanticReleaseOptions => {\n const plugins = getPluginOptions(configPassed)\n // const configInit: SemanticReleaseOptions = {\n const configInit: any = {\n branches: [{ name: 'main' }, { name: 'canary', prerelease: 'canary' }],\n extends: ['semantic-release-commit-filter'],\n plugins,\n tagFormat: `v\\${version}`,\n }\n\n const config: SemanticReleaseOptions = {\n ...configInit,\n ...configPassed,\n }\n\n return config\n}\n\nexport { getConfig }\n"],"mappings":"gGAMA,MAAM,GAAkB,EAAqC,EAAE,GAGtD,CACL,oCACA,CACE,OAAQ,mCACR,aANiB,CAAC,GAAGC,EAAqB,GAAG,EAAmB,CAOjE,CACF,CCJG,EAAO,GACJ,CACL,wBACA,CACE,O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AqB,GAClD,EAAQ,yBAA2B,EAA2B,GAC9D,EAAQ,UAAY,EAAY,GAChC,EAAQ,aAAe,EAAe,GACtC,EAAQ,UAAY,EAAY,GACjC,CAEsC,OAAQ,GAAW,CAAC,CAAC,EAAO,EC5E/D,GAAa,EAAe,EAAE,IAUK,CANrC,SAAU,CAAC,CAAE,KAAM,OAAQ,CAAE,CAAE,KAAM,SAAU,WAAY,SAAU,CAAC,CACtE,QAAS,CAAC,iCAAiC,CAC3C,QALc,EAAiB,EAAa,CAM5C,UAAW,cAKX,GAAG,EACJ"}
package/index.mjs.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","names":[],"sources":["../src/index.ts"],"sourcesContent":["import type { Options } from 'semantic-release'\n\nimport { getConfig } from './getConfig.js'\nimport { getPluginOptions } from './plugins/index.js'\n\nconst plugins: Options = getPluginOptions()\nconst config = getConfig()\n\nexport { config, getConfig, getPluginOptions, plugins }\n"],"mappings":"4EAKA,MAAM,EAAmB,GAAkB,CACrC,EAAS,GAAW"}
1
+ {"version":3,"file":"index.mjs","names":[],"sources":["../src/index.ts"],"sourcesContent":["import type { Options } from 'semantic-release'\n\nimport { getConfig } from './getConfig'\nimport { getPluginOptions } from './plugins/index'\n\nconst plugins: Options = getPluginOptions()\nconst config = getConfig()\n\nexport { config, getConfig, getPluginOptions, plugins }\n"],"mappings":"4EAKA,MAAM,EAAmB,GAAkB,CACrC,EAAS,GAAW"}
package/package.json CHANGED
@@ -1,9 +1,10 @@
1
1
  {
2
2
  "name": "@jeromefitz/semantic",
3
- "version": "11.1.9-canary.2",
3
+ "version": "12.0.0",
4
4
  "type": "module",
5
5
  "description": "Semantic Versioning, Conventional Commits with CI/CD for GitHub Actions.",
6
6
  "repository": {
7
+ "directory": "packages/semantic",
7
8
  "type": "git",
8
9
  "url": "git+https://github.com/JeromeFitz/packages.git"
9
10
  },
@@ -1 +1 @@
1
- {"version":3,"file":"release.config.mjs","names":[],"sources":["../src/release.config.ts"],"sourcesContent":["import { getConfig } from './getConfig.js'\n\nconst config = getConfig()\n\nexport default config\n"],"mappings":"0EAEA,MAAM,EAAS,GAAW"}
1
+ {"version":3,"file":"release.config.mjs","names":[],"sources":["../src/release.config.ts"],"sourcesContent":["import { getConfig } from './getConfig'\n\nconst config = getConfig()\n\nexport default config\n"],"mappings":"0EAEA,MAAM,EAAS,GAAW"}