From e245b4fa229bee1e2ab97fcb42de3831b8bdbe5b Mon Sep 17 00:00:00 2001 From: Vijay A Date: Wed, 24 May 2023 06:57:50 +0530 Subject: Upgrade npm modules --- scripts/link-readme.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'scripts/link-readme.ts') diff --git a/scripts/link-readme.ts b/scripts/link-readme.ts index d565d59bb..d80739178 100644 --- a/scripts/link-readme.ts +++ b/scripts/link-readme.ts @@ -22,7 +22,7 @@ let replacements = 0; // Regex matches strings that don't begin with a "[", i.e. are not already linked // followed by a "franz#" and digits to indicate // a GitHub issue, and not ending with a "]" -readme = readme.replace(/(? { +readme = readme.replaceAll(/(? { const issueNr = match.replace('franz#', ''); replacements += 1; return `[franz#${issueNr}](https://github.com/meetfranz/franz/issues/${issueNr})`; @@ -31,9 +31,9 @@ readme = readme.replace(/(? { // Replace external issues // Regex matches strings that don't begin with a "[", followed a repo name in the format "user/repo" // followed by a "#" and digits to indicate a GitHub issue, and not ending with a "]" -readme = readme.replace(/(? { - const issueNr = match.replace(/\D/g, ''); - const repo = match.replace(/#\d+/g, ''); +readme = readme.replaceAll(/(? { + const issueNr = match.replaceAll(/\D/g, ''); + const repo = match.replaceAll(/#\d+/g, ''); replacements += 1; return `[${repo}#${issueNr}](https://github.com/${repo}/issues/${issueNr})`; }); @@ -42,7 +42,7 @@ readme = readme.replace(/(? { // Regex matches strings that don't begin with a "[", i.e. are not already linked and // don't begin with "franz", i.e. are not Franz issues, followed by a "#" and digits to indicate // a GitHub issue, and not ending with a "]" -readme = readme.replace(/(? { +readme = readme.replaceAll(/(? { const issueNr = match.replace('#', ''); replacements += 1; return `[#${issueNr}](https://github.com/ferdium/ferdium-app/issues/${issueNr})`; @@ -51,7 +51,7 @@ readme = readme.replace(/(? { // Link GitHub users // Regex matches strings that don't begin with a "[", i.e. are not already linked // followed by a "@" and at least one word character and not ending with a "]" -readme = readme.replace(/(? { +readme = readme.replaceAll(/(? { const username = match.replace('@', ''); replacements += 1; return `[@${username}](https://github.com/${username})`; -- cgit v1.2.3-70-g09d2