semantic-release-gha-output 1.0.0 → 1.1.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.
Files changed (4) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +4 -1
  3. package/index.js +10 -0
  4. package/package.json +1 -1
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2024 Zachary Spar
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -6,7 +6,9 @@ A semantic-release plugin to output values from a GitHub Action.
6
6
 
7
7
  | Step | Description |
8
8
  | ------------------ | -------------------------------------------------------------------------------------------- |
9
- | `verifyRelease` | Sets GitHub Action output variables. |
9
+ | `verifyConditions` | Sets GitHub Action output variable `published` to false |
10
+ | `verifyRelease` | Sets GitHub Action output variables `tag` & `version` |
11
+ | `success` | Sets GitHub Action output variable `published` to true |
10
12
 
11
13
  ## Install
12
14
 
@@ -20,6 +22,7 @@ $ npm install semantic-release-gha-output
20
22
  | ------------------ | -------------------------------------------------------------------------------------------- |
21
23
  | `tag` | Next release git tag. |
22
24
  | `version` | Next release version. |
25
+ | `published` | Boolean string to indicate whether a new release was published. |
23
26
 
24
27
 
25
28
  ## Usage
package/index.js CHANGED
@@ -1,10 +1,20 @@
1
1
  import { setOutput } from '@actions/core';
2
2
 
3
+ function verifyConditions() {
4
+ setOutput("published", "false");
5
+ }
6
+
3
7
  function verifyRelease(_pluginConfig, { nextRelease }) {
4
8
  setOutput("tag", nextRelease.gitTag);
5
9
  setOutput("version", nextRelease.version);
6
10
  }
7
11
 
12
+ function success() {
13
+ setOutput("published", "true");
14
+ }
15
+
8
16
  export default {
17
+ verifyConditions,
9
18
  verifyRelease,
19
+ success,
10
20
  };
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "name": "Zachary Spar",
5
5
  "email": "zachspar@gmail.com"
6
6
  },
7
- "version": "1.0.0",
7
+ "version": "1.1.0",
8
8
  "type": "module",
9
9
  "homepage": "https://github.com/zachspar/semantic-release-gha-output",
10
10
  "repository": "git@github.com:zachspar/semantic-release-gha-output.git",