@ondrejbelza/semantic-release-jira 1.6.0 → 1.7.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 CHANGED
@@ -1,3 +1,88 @@
1
- # semantic-release-jira
1
+ # semantic-release-jira plugin
2
+
3
+ Semantic release jira plugin hooks to semantic release and automatically creates releases in jira and links issues to this release.
4
+
5
+ ## Used hooks
6
+
7
+ | Hook | Description |
8
+ | ---------------- | -------------------------------------------------------------------------------------- |
9
+ | verifyConditions | Tries to get project info, throws an exception, when plugin is not configured properly |
10
+ | sucess | creates new jira release and link issue to it |
11
+
12
+ ## Install step
13
+
14
+ ```bash
15
+ $ npm install --save-dev @ondrejbelza/semantic-release-jira
16
+ $ yarn add --dev @ondrejbelza/semantic-release-jira
17
+ ```
18
+
19
+ ## Configuration
20
+
21
+ ### Required CI env variables
22
+
23
+ | Value | Description |
24
+ | ---------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
25
+ | JIRA_TOKEN | user token that is used for all jira API calls. [Guide How to generate token](https://support.atlassian.com/atlassian-account/docs/manage-api-tokens-for-your-atlassian-account/). |
26
+ | JIRA_EMAIL | email of user which generated the token |
27
+
28
+ #### Required jira permissions
29
+
30
+ user must have following permissions, otherwise this plugin will not work properly
31
+
32
+ - get project
33
+ - get issue
34
+ - modify issue
35
+ - create release
36
+
37
+ ### Plugin Configuration
38
+
39
+ ```json
40
+ {
41
+ "plugins": [
42
+ "@semantic-release/commit-analyzer",
43
+ "@semantic-release/release-notes-generator",
44
+ "@semantic-release/git",
45
+ [
46
+ "ondrejbelza/semantic-release-jira",
47
+ {
48
+ "projectId": "MAWI",
49
+ "releaseNameTemplate": "Test v${version}",
50
+ "jiraHost": "maisltep.atlassian.net",
51
+ "ticketPrefixe": "MAWI"
52
+ }
53
+ ]
54
+ ]
55
+ }
56
+ ```
57
+
58
+ ```ts
59
+ interface Config {
60
+ /**
61
+ * A domain of a jira instance ie: `mailstep.atlasian.net`
62
+ */
63
+ jiraHost: string;
64
+
65
+ /**
66
+ * A prefixe to match when looking for tickets in commits.
67
+ *
68
+ * ie. 'TEST' would match `TEST-123` and `TEST-456`
69
+ */
70
+ ticketPrefix: string;
71
+
72
+ /**
73
+ * The id or key for the project releases will be created in
74
+ */
75
+ projectId: string;
76
+
77
+ /**
78
+ * A lodash template with a single `version` variable
79
+ * defaults to `v${version}` which results in a version that is named like `v1.0.0`
80
+ * ex: `Semantic Release v${version}` results in `Semantic Release v1.0.0`
81
+ *
82
+ * @default `v${version}`
83
+ */
84
+ releaseNameTemplate?: string;
85
+ }
86
+ ```
2
87
 
3
88
  semantic release jira releases plugin.
package/dist/consts.d.ts CHANGED
@@ -1,2 +1,2 @@
1
1
  export declare const DEFAULT_VERSION_TEMPLATE = "v${version}";
2
- export declare const DEFAULT_RELEASE_DESCRIPTION_TEMPLATE = "# Release notes - {{version}}\n## Issues\n{{#each issues}}\n - [{{type}}] [{{ key }}]({{ link }}) {{ title }}\n - Short description: {{ description }}\n - Assigned to: {{ assignee }}\n\n{{/each}}\n\nRelease notes were automatically generated";
2
+ export declare const DEFAULT_RELEASE_DESCRIPTION_TEMPLATE = "# Release notes - {{version}}\n\n## Issues\n{{#each issues}}\n - [{{type}}] [{{ key }}]({{ link }}) {{ title }}\n - Short description: {{ description }}\n - Assigned to: {{ assignee }}\n\n{{/each}}\n\nRelease notes were automatically generated";
package/dist/consts.js CHANGED
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.DEFAULT_RELEASE_DESCRIPTION_TEMPLATE = exports.DEFAULT_VERSION_TEMPLATE = void 0;
4
4
  exports.DEFAULT_VERSION_TEMPLATE = "v${version}";
5
5
  exports.DEFAULT_RELEASE_DESCRIPTION_TEMPLATE = `# Release notes - {{version}}
6
+
6
7
  ## Issues
7
8
  {{#each issues}}
8
9
  - [{{type}}] [{{ key }}]({{ link }}) {{ title }}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ondrejbelza/semantic-release-jira",
3
- "version": "1.6.0",
3
+ "version": "1.7.1",
4
4
  "description": "semantic release jira releases plugin",
5
5
  "homepage": "https://github.com/mailstepcz/semantic-release-jira#readme",
6
6
  "bugs": {
@@ -44,6 +44,7 @@
44
44
  "@types/node": "^25.0.3",
45
45
  "@types/semantic-release__error": "^3.0.3",
46
46
  "@types/signale": "^1.4.7",
47
+ "conventional-changelog-conventionalcommits": "^9.1.0",
47
48
  "dotenv": "^17.2.3",
48
49
  "dotenv-safe": "^9.1.0",
49
50
  "typescript": "^5.9.3"