refactor: changelog ci scripts - #47
Open
yCodeTech wants to merge 7 commits into
Open
Conversation
- Added `context` and `github` params to:
- The main `updateChangelog` function passing them from it's call in the CI step.
- `buildEntry` function
- `formatPRDescription` function.
- The corresponding docblocks.
- Refactored `buildEntry` function so the return statement isn't one long string. Split multiple sections into variables for ease.
- Changed `formatPRDescription` and `buildEntry` functions to be `async`, and their function calls now `await` them.
- Remove the `-` in the params description because it's rendered as a bullet point in vscode intellisense. - Updated the return type of `findOrCreateUnreleased` function.
…ulti-lines. - Added the `prettier-plugin-multiline-arrays` dev dependency to force prettier to wrap arrays onto muliple lines. - Added the prettier dev dependency because the prettier vscode extension only supports prettier plugins when installed locally in a project. - Specified the prettier plugin and it's `multilineArraysWrapThreshold` option in the prettierrc.json file to enable the usage of the plugin.
…pt for readability
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR refactors various things in the changelog CI scripts: updates docblocks, changes various functions to
async, adds new params derived from the workflow itself, and reorders the functions for readability as they're now in order of usage from top-bottom. It also introduces new dev dependenciesprettierandprettier-plugin-multiline-arraysto allow the vscode prettier extension to force wrapping of the arrays onto multiple lines, because prettier defaulted to auto-formatting all array elements on to 1 long single line, which is bad for readability.