8000 build(release): release v2 · shiftcode/github-action-skip@57e4115 · GitHub
[go: up one dir, main page]

Skip to content

Commit 57e4115

Browse files
build(release): release v2
1 parent 19174ec commit 57e4115

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ name: 'Skip CI'
22
description: 'Skip ci based on some input parameter'
33
author: 'Michael Wittwer <michael.wittwer@shiftcode.ch>'
44
inputs:
5-
skipOnCommitMsg: # change this
6-
description: 'will cancel the current action if the commit message contains tiven value'
5+
skipOnCommitMsg:
6+
description: 'will cancel the current action if the commit message contains given value'
77
default: ''
88
required: true
99
runs:

lib/main.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
"use strict";
22
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
34
return new (P || (P = Promise))(function (resolve, reject) {
45
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
56
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6-
function step(result) { result.done ? resolve(result.value) : new P(function (resolve) { resolve(result.value); }).then(fulfilled, rejected); }
7+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
78
step((generator = generator.apply(thisArg, _arguments || [])).next());
89
});
910
};
@@ -25,7 +26,7 @@ function run() {
2526
const skipOnCommitMsg = core.getInput(INPUT);
2627
console.log(`skip CI on commit message ${skipOnCommitMsg}`);
2728
// core.startGroup('Expand to see the github context')
28-
// console.log(JSON.stringify(git.context))
29+
console.log(JSON.stringify(git.context));
2930
// core.endGroup()
3031
const commitMessage = git.context.payload.head_commit.message;
3132
if (commitMessage.includes(skipOnCommitMsg)) {

src/main.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ async function run() {
1010
console.log(`skip CI on commit message ${skipOnCommitMsg}`)
1111

1212
// core.startGroup('Expand to see the github context')
13-
// console.log(JSON.stringify(git.context))
13+
console.log(JSON.stringify(git.context))
1414
// core.endGroup()
1515

1616
const commitMessage = git.context.payload.head_commit.message

0 commit comments

Comments
 (0)
0