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

Improve change-version script #38983

Merged
merged 2 commits into from
Aug 21, 2023
Merged

Improve change-version script #38983

merged 2 commits into from
Aug 21, 2023

Conversation

XhmikosR
Copy link
Member

@XhmikosR XhmikosR commented Jul 31, 2023

Only replace the version in specific files instead of blindly all repo files

EDIT: let's merge this after #38984

@XhmikosR XhmikosR force-pushed the xmr/change-version branch from c036755 to 088a6b4 Compare July 31, 2023 06:54
@XhmikosR XhmikosR marked this pull request as ready for review July 31, 2023 21:50
@XhmikosR XhmikosR requested a review from a team as a code owner July 31, 2023 21:50
@XhmikosR XhmikosR force-pushed the xmr/change-version branch from e27dcff to c160cfe Compare August 1, 2023 08:21
@XhmikosR XhmikosR marked this pull request as draft August 1, 2023 08:37
@XhmikosR XhmikosR force-pushed the xmr/change-version branch from c160cfe to d0abc77 Compare August 6, 2023 04:44
build/change-version.mjs Fixed Show fixed Hide fixed
@XhmikosR XhmikosR force-pushed the xmr/change-version branch from d0abc77 to e55e441 Compare August 6, 2023 04:48
@XhmikosR XhmikosR marked this pull request as ready for review August 6, 2023 04:49
@XhmikosR XhmikosR force-pushed the xmr/change-version branch from e55e441 to 10eebe2 Compare August 6, 2023 04:50
Only replace the version in specific files instead of blindly all repo files
@GeoSot GeoSot force-pushed the xmr/change-version branch from 10eebe2 to d4792ea Compare August 14, 2023 12:48
Comment on lines +72 to +73
console.error(error)
process.exit(1)
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
console.error(error)
process.exit(1)
console.error(error)
process.exit(1)

Suppose we could use throw error here, too?

await Promise.all(
files.map(file => replaceRecursively(file, oldVersion, newVersion))
FILES.map(file => replaceRecursively(file, oldVersion, newVersion))
Copy link
Member

Choose a reason for hiding this comment

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

Do we still need the recursive replacement?

@XhmikosR
Copy link
Member Author

@GeoSot The changes are based on the script we use in bootstrap-icons: https://github.com/twbs/icons/blob/main/build/bump-version.mjs

So, the plan is to keep them in sync for now.

@GeoSot
Copy link
Member

GeoSot commented Aug 14, 2023

@GeoSot The changes are based on the script we use in bootstrap-icons: https://github.com/twbs/icons/blob/main/build/bump-version.mjs

So, the plan is to keep them in sync for now.

In this case, I think we are good to go

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants