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

Add automatic updating of README #16

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,18 @@
</archive>
</configuration>
</plugin>
<plugin>
<groupId>io.github.floverfelt</groupId>
<artifactId>find-and-replace-maven-plugin</artifactId>
<version>1.2.0</version>
<configuration>
<replacementType>file-contents</replacementType>
<fileMask>.md</fileMask>
<!-- Bit of hack as it is assuming this version is always 1.x -->
<findRegex>&lt;version&gt;1.*&lt;/version&gt;</findRegex>
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm not entirely happy with this but I think the only other way of doing it would be to remove any <version>[numeric]... from the readme that isn't for ide-config ; currently the only other instance is:

  <artifactId>spotless-maven-plugin</artifactId>
  <version>2.44.2</version>

Perhaps it would be better to move the above into a properties block so it simplifies the above regex? Thoughts?

<replaceValue>&lt;version&gt;${project.version}&lt;/version&gt;</replaceValue>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
Expand All @@ -61,6 +73,24 @@
<id>release</id>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>2.5.3</version>
<configuration>
<preparationGoals>-Prelease clean find-and-replace:find-and-replace scm:checkin verify</preparationGoals>
<completionGoals>-Prelease clean verify</completionGoals>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-scm-plugin</artifactId>
<version>2.1.0</version>
<configuration>
<message>[maven-scm-plugin] Set ${project.version} version in README.md</message>
<includes>README.md</includes>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
Expand Down
Loading