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(hostRules/matchHost): massage and validate #29487

Merged

Conversation

RahulGautamSingh
Copy link
Collaborator

@RahulGautamSingh RahulGautamSingh commented Jun 6, 2024

Changes

  • Prefix matchHost url which contain : or / with htps:// (migrated as well)

  • Validate matchHost urls

    1. if its an empty string
    2. check is it is a valid url if the url includes :// (ie. only check for valid if url has scheme)

Context

Closes: #29425

Documentation (please check one with an [x])

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

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

@RahulGautamSingh RahulGautamSingh changed the title massage and validate hostRules.matchHost feat(hostRules/matchHost): massage and validate Jun 6, 2024
lib/config/validation.ts Outdated Show resolved Hide resolved
@rarkins
Copy link
Collaborator

rarkins commented Jun 6, 2024

Please test for both global and repo config

@RahulGautamSingh
Copy link
Collaborator Author

Please test for both global and repo config

Done ☑️

rarkins
rarkins previously approved these changes Jun 7, 2024
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/config/validation.ts Outdated Show resolved Hide resolved
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/config/migrations/custom/host-rules-migration.ts Outdated Show resolved Hide resolved
@RahulGautamSingh RahulGautamSingh marked this pull request as draft June 23, 2024 20:53
@RahulGautamSingh RahulGautamSingh marked this pull request as ready for review June 23, 2024 21:02
@viceice viceice added this pull request to the merge queue Jun 28, 2024
Merged via the queue into renovatebot:main with commit b8b7607 Jun 28, 2024
37 checks passed
@renovate-release
Copy link
Collaborator

🎉 This PR is included in version 37.421.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

bryannaegele pushed a commit to bryannaegele/renovate that referenced this pull request Jul 8, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 30, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

hostRules: improve matchHost validation and parsing
4 participants