Title: Set-ShieldsIoBadge replaces whole line (until last ')') · Issue #131 · PowerShellOrg/BuildHelpers · GitHub
Open Graph Title: Set-ShieldsIoBadge replaces whole line (until last ')') · Issue #131 · PowerShellOrg/BuildHelpers
X Title: Set-ShieldsIoBadge replaces whole line (until last ')') · Issue #131 · PowerShellOrg/BuildHelpers
Description: Hello, first of all, thank you for this, this module helps A LOT - made more progress in the last two weeks learning and understanding the build process, runners, etc. than in the last two years! I want to utilize Set-ShieldsIoBadge and ...
Open Graph Description: Hello, first of all, thank you for this, this module helps A LOT - made more progress in the last two weeks learning and understanding the build process, runners, etc. than in the last two years! I...
X Description: Hello, first of all, thank you for this, this module helps A LOT - made more progress in the last two weeks learning and understanding the build process, runners, etc. than in the last two years! I...
Opengraph URL: https://github.com/PowerShellOrg/BuildHelpers/issues/131
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Set-ShieldsIoBadge replaces whole line (until last ')')","articleBody":"Hello,\r\n\r\nfirst of all, thank you for this, this module helps A LOT - made more progress in the last two weeks learning and understanding the build process, runners, etc. than in the last two years!\r\n\r\nI want to utilize `Set-ShieldsIoBadge` and I have a little table that contains the badges, looks like this:\r\n\r\n### Component Status\r\n\r\n| | |\r\n| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |\r\n| General | [](https://github.com/DEberhardt/TeamsFunctions/tree/master/docs) [](https://www.powershellgallery.com/packages/TeamsFunctions/) |\r\n| Release | [](.\\readme.md) [](.\\readme.md) |\r\n| Build | [](.\\readme.md) [](.\\readme.md) [](https://github.com/DEberhardt/TeamsFunctions/issues) |\r\n| Functions |       |\r\n| Pester |       |\r\n\r\nafter running updates against them, it looks like this:\r\n\r\n### Component Status\r\n| | |\r\n| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |\r\n| General | [](https://github.com/DEberhardt/TeamsFunctions/tree/master/docs) [](https://www.powershellgallery.com/packages/TeamsFunctions/) |\r\n| Release | [](.\\readme.md) [](.\\readme.md) |\r\n| Build | [ |\r\n| Functions |  |\r\n| Pester |  |\r\n\r\n\r\nLooking into `Set-ShieldsIoBadge`, I find that the match string is finding too much:\r\n\r\n```powershell\r\n$ReadmeContent = (Get-Content $Path)\r\n$ReadmeContent = $ReadmeContent -replace \"!\\[$($Subject)\\].+\\)\", \"\"\r\n$ReadmeContent | Set-Content -Path $Path\r\n\r\n# running this manually to see what matches\r\n❯ $RM = Get-Content Readme.md\r\n❯ $Subject = \"Public\"\r\n❯ $RM -match \"!\\[$($Subject)\\].+\\)\"\r\n| Functions |       \r\n```\r\n\r\nIt looks like it replaces the whole line until the (last?) ')' rather than the next one found.\r\nPlaying around with Regex and Lazy operators, but cannot find a suitable match that would reduce the match to the actual.\r\n\r\nIs there a way to do this please?\r\n\r\nThank you,\r\nDavid","author":{"url":"https://github.com/DEberhardt","@type":"Person","name":"DEberhardt"},"datePublished":"2022-07-02T14:25:36Z","url":"https://github.com/PowerShellOrg/BuildHelpers/issues/131"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:0d85f620-0663-13e3-8c22-a80dae84057c |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E8F4:2A2201:5D699:7BBDB:6AFD3833 |
| html-safe-nonce | c8c5838965f7ca6cadb5f5758c4e048411ffceb6a5e29491fab857b805778c8a |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFOEY0OjJBMjIwMTo1RDY5OTo3QkJEQjo2QUZEMzgzMyIsInZpc2l0b3JfaWQiOiI4MDc1NTM2MTQwMzkzNTkyODgzIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 5dae7412263c4b52eed798870a6106672843cda3acf5fa909c903ac8f89e7ac4 |
| hovercard-subject-tag | issue:1292067359 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/PowerShellOrg/BuildHelpers/131/issue_layout |
| twitter:image | https://opengraph.githubassets.com/e51ce39d82f9c480c5c689784f50a048d80245aaac02137842cbee434da28b0a/PowerShellOrg/BuildHelpers/issues/131 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/e51ce39d82f9c480c5c689784f50a048d80245aaac02137842cbee434da28b0a/PowerShellOrg/BuildHelpers/issues/131 |
| og:image:alt | Hello, first of all, thank you for this, this module helps A LOT - made more progress in the last two weeks learning and understanding the build process, runners, etc. than in the last two years! I... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | DEberhardt |
| hostname | github.com |
| expected-hostname | github.com |
| None | 065128366c233a9d57ff68ab6c96e25b99dd1b0ab70d23b70873d3dd6b5e4f19 |
| turbo-cache-control | no-preview |
| go-import | github.com/PowerShellOrg/BuildHelpers git https://github.com/PowerShellOrg/BuildHelpers.git |
| octolytics-dimension-user_id | 4895314 |
| octolytics-dimension-user_login | PowerShellOrg |
| octolytics-dimension-repository_id | 59748913 |
| octolytics-dimension-repository_nwo | PowerShellOrg/BuildHelpers |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 59748913 |
| octolytics-dimension-repository_network_root_nwo | PowerShellOrg/BuildHelpers |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 941021edf0c2ec58298f4a2c8f27ae507d129c92 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width