| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
There was a problem hiding this comment.
LGTM broadly, just a couple of nits - don't need to be implemented within the PR.
Sorry, something went wrong.
| "We were unable to automatically build your code. Please provide manual build steps. " + | ||
| "For more information, see " + | ||
| "https://docs.github.com/en/code-security/code-scanning/troubleshooting-code-scanning/automatic-build-failed. " + | ||
| "See https://docs.github.com/en/code-security/code-scanning/troubleshooting-code-scanning/automatic-build-failed " + |
There was a problem hiding this comment.
I'm wondering whether it makes sense to export these into their own variables, and even better perhaps in their own file, something like src/docs-urls.ts or something similar.
Doing so would have the benefit of them being more centrally organised, so we can do a one-step global replace if anything changes by just changing the value of the constant to the new URL, and have the documentation strings be automatically updated everywhere.
Sorry, something went wrong.
There was a problem hiding this comment.
I did this in an enum, similar to the way we have EnvVar for shared environment variables 😄 it was a really good idea — from there I found other instances where we had docs links that ended with periods!
Sorry, something went wrong.
| } else { | ||
| logger.info( | ||
| `Enabling ${featureName}. This can be disabled by setting the ${envVar} environment variable to 'false' (see ${envDoc}).`, | ||
| `Enabling ${featureName}. This can be disabled by setting the ${envVar} environment variable to 'false' (see ${envDoc} for more information).`, |
There was a problem hiding this comment.
In some of these strings we have the URL reference inside of a parenthesis, whereas in others we end the sentence with a period and start a new one.
I'm curious if there are any benefits to being more consistent on that front.
Sorry, something went wrong.
There was a problem hiding this comment.
I definitely don't see any downsides to standardizing our docs links — I removed all the parenthetical URL references!
Sorry, something went wrong.
There was a problem hiding this comment.
Nice! Non-blocking, optional: This could be something we create a CodeQL query for to help make sure we follow this pattern going forward.
Sorry, something went wrong.
Always say "see $URL for more information" without parentheses.
Thanks!! I've waited too long to get back to this PR 😆 so I won't write the CodeQL query this time. I think the new DocUrl enum out should make it a lot clearer moving forward as well. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Fixes #2354.
This PR updates all log messages with links to GitHub docs so that they are not succeeded by punctuation marks, in order to make sure the links are clickable from our logs.
Merge / deployment checklist