-
Notifications
You must be signed in to change notification settings - Fork 460
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
Update sortpom plugin to newest version #1675
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great! I'm happy to merge this as-is, but this is probably a good time to make the version configurable. If you want to do that, I'd be happy to wait for the version parameter to get added.
If you don't care about a configurable version parameter then I'm happy to merge as-is. Just means that in the future you'll have to wait for a new Spotless even if all you want is a new sortpom.
plugin-maven/CHANGES.md
Outdated
@@ -3,6 +3,7 @@ | |||
We adhere to the [keepachangelog](https://keepachangelog.com/en/1.0.0/) format (starting after version `1.27.0`). | |||
|
|||
## [Unreleased] | |||
* Update sortpom plugin to the newest version |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
## [Unreleased]
### Changes
* Bump default sortpom version to latest `3.0.0` -> `3.2.1`. ([#1675](https://github.com/diffplug/spotless/pull/1675))
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use default
if the version becomes configurable, remove
default` if the version stays fixed.
I'll gladly make it configurable. Do you have a different plugin you can point me at that does that already? And I'll push a fix for that changelog real quick too. |
I think almost every other step has a configurable version. Some examples |
Ah, I was looking at the GoogleJavaFormatStep, but it seemed to work quite differently than the SortPomStep. Ktfmt looks much closer. And I actually use that one so that's good to read over anyway. |
Is there an architecture guide for how to build steps and tests? It seems like they are all built quite differently (which makes sense, if they were built at different times), but I don't want to build the 'old' way if there is such a thing. |
@nedtwigg ok, updated! Hopefully I did that right. I tested locally on my own projects and it seems to work correctly, though I don't really know what I'm doing. 🤷🏼 The other Steps seem to complicate stuff with default versions, etc. I just stuck that on the Cfg object because it seemed like other defaults were there already. If that's not appropriate just let me know! |
@nedtwigg Do I need to do anything else to get this merged? I don't want to miss anything. |
@nedtwigg agh. I just realized I pushed with my work email. Your contribution guidelines say to not force push. Is it ok if I force push to rewrite my commit email? |
Go for it! |
7e72de9
to
401f28d
Compare
@nedtwigg done! |
Update the sortpom plugin to add sortDependencyManagement element. Remove dependency on IOUtils
Add test for version config Update SortPomTest to use ResourceHarness
401f28d
to
e686e4f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the great PR, sorry I was so slow to merge.
No worries! Thank you very much! |
@nedtwigg when do releases usually go out? is it a monthly thing? |
I'll cut a release tonight or tomorrow. It's not a fixed schedule - I try to get new features published right away, and I usually let minor things sit around until there's a bigger feature that needs to get published. Sorry for the big delay this time, had a tough month so Spotless got neglected a bit. |
Absolutely no worries dude. I built it locally and deployed it to our nexus repo so we haven't been blocked on it. Take your time! And thank you for the hard work! |
Released (finally!!) in |
Thank you so much! |
This MR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [com.diffplug.spotless:spotless-maven-plugin](https://github.com/diffplug/spotless) | build | minor | `2.38.0` -> `2.39.0` | | [io.quarkus:quarkus-maven-plugin](https://github.com/quarkusio/quarkus) | build | patch | `3.3.0` -> `3.3.1` | | [io.quarkus:quarkus-universe-bom](https://github.com/quarkusio/quarkus-platform) | import | patch | `3.3.0` -> `3.3.1` | --- ### Release Notes <details> <summary>diffplug/spotless</summary> ### [`v2.39.0`](https://github.com/diffplug/spotless/blob/HEAD/CHANGES.md#​2390---2023-05-24) ##### Added - `Jvm.Support` now accepts `-SNAPSHOT` versions, treated as the non`-SNAPSHOT`. ([#​1583](diffplug/spotless#1583)) - Support Rome as a formatter for JavaScript and TypeScript code. Adds a new `rome` step to `javascript` and `typescript` formatter configurations. ([#​1663](diffplug/spotless#1663)) - Add semantics-aware Java import ordering (i.e. sort by package, then class, then member). ([#​522](diffplug/spotless#522)) ##### Fixed - Fixed a regression which changed the import sorting order in `googleJavaFormat` introduced in `2.38.0`. ([#​1680](diffplug/spotless#1680)) - Equo-based formatters now work on platforms unsupported by Eclipse such as PowerPC (fixes [durian-swt#​20](diffplug/durian-swt#20)) - When P2 download fails, indicate the responsible formatter. ([#​1698](diffplug/spotless#1698)) ##### Changes - Equo-based formatters now download metadata to `~/.m2/repository/dev/equo/p2-data` rather than `~/.equo`, and for CI machines without a home directory the p2 data goes to `$GRADLE_USER_HOME/caches/p2-data`. ([#​1714](diffplug/spotless#1714)) - Bump default `googleJavaFormat` version to latest `1.16.0` -> `1.17.0`. ([#​1710](diffplug/spotless#1710)) - Bump default `ktfmt` version to latest `0.43` -> `0.44`. ([#​1691](diffplug/spotless#1691)) - Bump default `ktlint` version to latest `0.48.2` -> `0.49.1`. ([#​1696](diffplug/spotless#1696)) - Dropped support for `ktlint 0.46.x` following our policy of supporting two breaking changes at a time. - Bump default `sortpom` version to latest `3.0.0` -> `3.2.1`. ([#​1675](diffplug/spotless#1675)) </details> <details> <summary>quarkusio/quarkus</summary> ### [`v3.3.1`](quarkusio/quarkus@3.3.0...3.3.1) [Compare Source](quarkusio/quarkus@3.3.0...3.3.1) </details> <details> <summary>quarkusio/quarkus-platform</summary> ### [`v3.3.1`](quarkusio/quarkus-platform@3.3.0...3.3.1) [Compare Source](quarkusio/quarkus-platform@3.3.0...3.3.1) </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever MR is behind base branch, or you tick the rebase/retry checkbox. 👻 **Immortal**: This MR will be recreated if closed unmerged. Get [config help](https://github.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this MR, check this box --- This MR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNC4yNC4wIiwidXBkYXRlZEluVmVyIjoiMzQuMjQuMCJ9-->
Update the sortpom plugin to add sortDependencyManagement element.
Remove dependency on IOUtils
Please DO NOT FORCE PUSH. Don't worry about messy history, it's easier to do code review if we can tell what happened after the review, and force pushing breaks that.
Please make sure that your PR allows edits from maintainers. Sometimes its faster for us to just fix something than it is to describe how to fix it.
After creating the PR, please add a commit that adds a bullet-point under the
[Unreleased]
section of CHANGES.md, plugin-gradle/CHANGES.md, and plugin-maven/CHANGES.md which includes:If your change only affects a build plugin, and not the lib, then you only need to update the
plugin-foo/CHANGES.md
for that plugin.If your change affects lib in an end-user-visible way (fixing a bug, updating a version) then you need to update
CHANGES.md
for both the lib and all build plugins. Users of a build plugin shouldn't have to refer to lib to see changes that affect them.This makes it easier for the maintainers to quickly release your changes :)