Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
olemorud committed Mar 15, 2023
1 parent e413405 commit 31f5585
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion dist/gcc_matcher.jsontemplate
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"owner": "gcc-problem-matcher",
"pattern": [
{
"regexp": "^(${{ BASE }})(.*?):(\\d+):(\\d*):?\\s+(?:fatal\\s+)?(warning|error):\\s+(.*)$",
"regexp": "^(${{ BASE }}\\/?)(.*?):(\\d+):(\\d*):?\\s+(?:fatal\\s+)?(warning|error):\\s+(.*)$",
"fromPath": 1,
"file": 2,
"line": 3,
Expand Down
4 changes: 2 additions & 2 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2848,7 +2848,7 @@ const core = __nccwpck_require__(127);
// escapeRegExp :: string => string
// escape all characters with special meanings in regexp
const escapeRegExp = (s) =>
s.replace(/[/\-^$*+?.()|[\]{}]/g, "\\$&");
s.replace(/[/\-^$*+?.()|[\]{}]/g, "\\\\$&");

// variable :: string => RegExp
// create regex to match ${{ key }}
Expand All @@ -2859,7 +2859,7 @@ const variable = (key) =>
const templatePath = __nccwpck_require__.ab + "gcc_matcher.jsontemplate";

// matcherPath :: string
const matcherPath = __nccwpck_require__.ab + "gcc_matcher.json";
const outputPath = __nccwpck_require__.ab + "gcc_matcher.json";

// rootdir :: string
const rootdir = core.getInput('build-directory', {required: false});
Expand Down
2 changes: 1 addition & 1 deletion src/gcc_matcher.jsontemplate
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"owner": "gcc-problem-matcher",
"pattern": [
{
"regexp": "^(${{ BASE }})(.*?):(\\d+):(\\d*):?\\s+(?:fatal\\s+)?(warning|error):\\s+(.*)$",
"regexp": "^(${{ BASE }}\\/?)(.*?):(\\d+):(\\d*):?\\s+(?:fatal\\s+)?(warning|error):\\s+(.*)$",
"fromPath": 1,
"file": 2,
"line": 3,
Expand Down
6 changes: 3 additions & 3 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const core = require('@actions/core');
// escapeRegExp :: string => string
// escape all characters with special meanings in regexp
const escapeRegExp = (s) =>
s.replace(/[/\-^$*+?.()|[\]{}]/g, "\\$&");
s.replace(/[/\-^$*+?.()|[\]{}]/g, "\\\\$&");

// variable :: string => RegExp
// create regex to match ${{ key }}
Expand All @@ -16,7 +16,7 @@ const variable = (key) =>
const templatePath = path.join(__dirname, "gcc_matcher.jsontemplate");

// matcherPath :: string
const matcherPath = path.join(__dirname, "gcc_matcher.json");
const outputPath = path.join(__dirname, "gcc_matcher.json");

// rootdir :: string
const rootdir = core.getInput('build-directory', {required: false});
Expand All @@ -34,7 +34,7 @@ const parse = (templatePath) => (matcherPath) => {

// main:
try {
parse(templatePath)(matcherPath);
parse(templatePath)(outputPath);
} catch (err) {
core.setFailed(`Action failed with error ${err}`)
}
Expand Down

0 comments on commit 31f5585

Please sign in to comment.