summaryrefslogtreecommitdiff
path: root/js/videojs/.github/actions/pr-titles.mjs
diff options
context:
space:
mode:
authorLester Caine <lester@lsces.co.uk>2026-05-15 11:33:30 +0100
committerLester Caine <lester@lsces.co.uk>2026-05-15 11:33:30 +0100
commit8bf31bcde496852f35a00b847bb50ba05f5386c9 (patch)
tree97e8f59e767207d673c3a3381b4e69fa6040a966 /js/videojs/.github/actions/pr-titles.mjs
parentdcb7dd852a63d0a84056d3b84e2f05f0b5967900 (diff)
downloadthemes-8bf31bcde496852f35a00b847bb50ba05f5386c9.tar.gz
themes-8bf31bcde496852f35a00b847bb50ba05f5386c9.tar.bz2
themes-8bf31bcde496852f35a00b847bb50ba05f5386c9.zip
Add videojs package to javascript library
Diffstat (limited to 'js/videojs/.github/actions/pr-titles.mjs')
-rw-r--r--js/videojs/.github/actions/pr-titles.mjs13
1 files changed, 13 insertions, 0 deletions
diff --git a/js/videojs/.github/actions/pr-titles.mjs b/js/videojs/.github/actions/pr-titles.mjs
new file mode 100644
index 0000000..6712d48
--- /dev/null
+++ b/js/videojs/.github/actions/pr-titles.mjs
@@ -0,0 +1,13 @@
+import * as core from '@actions/core';
+import * as github from '@actions/github';
+
+(async function run() {
+ const title = github.context.payload.pull_request?.title;
+ const titleRegex = /^(chore|ci|docs|feat|fix|refactor|revert|test)(\(.+\))?!?: (.+)/;
+
+ if (!!title.match(titleRegex)) {
+ core.info('Pull request title is OK');
+ } else {
+ core.setFailed('Please use conventional commit style for the PR title so the merged change appears in the changelog. See https://www.conventionalcommits.org/.');
+ }
+})();