Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(github-action): retain spaces in extracted values #32730

Merged

Conversation

JP-Ellis
Copy link
Contributor

Changes

This update ensures that Renovate retains the number of whitespaces already present in the GitHub Action YAML file.

If there are no existing comments indicating the version number (e.g., when initially pinning a dependency), Renovate's behaviour remains unchanged (that is, it will insert a single space between the commit hash and the #).

Context

Documentation (please check one with an [x])

  • I have updated the documentation, or
  • No documentation update is required

Note

I do not believe this requires a documentation update as it is a rather transparent feature, but please let me know otherwise.

The GitHub Actions docs do contain a link to the above ticket that will be closed.

How I've tested my work (please select one)

I have verified these changes via:

  • Code inspection only, or
  • Newly added/modified unit tests, or
  • No unit tests but ran on a real repository, or
  • Both unit tests + ran on a real repository

This update ensures that Renovate retains the
number of whitespaces already present in the
GitHub Action YAML file.

If there are no existing comments indicating the
version number (e.g., when initially pinning a
dependency), Renovate's behaviour remains
unchanged (that is, it will insert a single space
between the commit hash and the `#`).

Signed-off-by: JP-Ellis <josh@jpellis.me>
Copy link
Member

@viceice viceice left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

otherwise LGTM

lib/modules/manager/github-actions/extract.spec.ts Outdated Show resolved Hide resolved
Co-authored-by: Michael Kriese <michael.kriese@gmx.de>
@JP-Ellis
Copy link
Contributor Author

Awesome thanks! All changes incorporated 🚀

@rarkins rarkins requested a review from viceice November 28, 2024 06:06
viceice
viceice previously approved these changes Nov 28, 2024
@viceice viceice enabled auto-merge November 28, 2024 18:50
@JP-Ellis
Copy link
Contributor Author

I see there's a lint issue in CI about a missing comma in the extract.spec.ts file, but I can't seem to replicate the issue locally. In fact, manually inserting the trailing comma causes the linter to complain locally.

@viceice viceice added this pull request to the merge queue Nov 28, 2024
@rarkins
Copy link
Collaborator

rarkins commented Nov 28, 2024

I see there's a lint issue in CI about a missing comma in the extract.spec.ts file, but I can't seem to replicate the issue locally. In fact, manually inserting the trailing comma causes the linter to complain locally.

Interestingly it needed a } in that place and not a ,

@JP-Ellis
Copy link
Contributor Author

Oh wow, I'm surprised vscode didn't highlight the issue 🤔

Thanks though!

Merged via the queue into renovatebot:main with commit 66f1ef5 Nov 28, 2024
39 checks passed
@JP-Ellis JP-Ellis deleted the feat/github-action/retain-spaces/31360 branch November 28, 2024 21:15
@renovate-release
Copy link
Collaborator

🎉 This PR is included in version 39.38.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

ssams pushed a commit to ssams/renovate that referenced this pull request Dec 2, 2024
…2730)

Signed-off-by: JP-Ellis <josh@jpellis.me>
Co-authored-by: Michael Kriese <michael.kriese@gmx.de>
Co-authored-by: Rhys Arkins <rhys@arkins.net>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Retain two spaces between content and comment in yaml files
4 participants