Skip to content

Commit

Permalink
chore(deps): bump typescript from 5.4.5 to 5.5.3 (#147)
Browse files Browse the repository at this point in the history
  • Loading branch information
dependabot[bot] authored Jul 9, 2024
1 parent 841cadd commit a73031b
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion __tests__/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ describe("index", () => {
const regex = getRegex();
const defaultRegex =
// eslint-disable-next-line no-useless-escape
/(?<=^|[a-z]-|[\s\p{Punct}&[^\-]])([A-Z][A-Z0-9_]*-\d+)(?![^\W_])(\s)+(.)+/;
/(?<=^|[a-z]-|[\s\p{P}&[^\-])([A-Z][A-Z0-9_]*-\d+)(?![^\W_])(\s)+(.)+/u;
expect(regex.length).toEqual(1);
expect(regex[0]).toEqual(defaultRegex);
expect(regex[0].test("PR-4 this is valid")).toBe(true);
Expand Down
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
"js-yaml": "^4.1.0",
"prettier": "^3.3.2",
"ts-jest": "^29.1.5",
"typescript": "^5.4.5"
"typescript": "^5.5.3"
},
"devDependencies": {
"@typescript-eslint/eslint-plugin": "^7.15.0",
Expand Down
5 changes: 3 additions & 2 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,11 +94,12 @@ export const getPullRequestTitle = () => {

const getDefaultJiraIssueRegex = () =>
new RegExp(
"(?<=^|[a-z]-|[\\s\\p{Punct}&[^\\-]])([A-Z][A-Z0-9_]*-\\d+)(?![^\\W_])(\\s)+(.)+",
"(?<=^|[a-z]-|[\\s\\p{P}&[^\\-])([A-Z][A-Z0-9_]*-\\d+)(?![^\\W_])(\\s)+(.)+",
"u"
);

const isValidProjectKey = (projectKey: string) =>
/(?<=^|[a-z]-|[\s\p{Punct}&[^-]])([A-Z][A-Z0-9_]*)/.test(projectKey);
/(?<=^|[a-z]-|[\s\p{P}&[^-])([A-Z][A-Z0-9_]*)/u.test(projectKey);

const getRegexWithProjectKeyAndKeyAnywhereInTitle = (
projectKey: string,
Expand Down

0 comments on commit a73031b

Please sign in to comment.