Skip to content

Commit

Permalink
CI to handle versioning
Browse files Browse the repository at this point in the history
  • Loading branch information
querwurzel committed Nov 7, 2023
1 parent d722af5 commit 034a1e7
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 10 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,20 +38,21 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
mvn deploy -DskipTests -Drevision=1.0.${{ github.run_number }} -Denv=mysql
mvn versions:set -DnewVersion=1.0.${{ github.run_number }}
mvn deploy -DskipTests -Denv=mysql --projects :backend
- uses: actions/delete-package-versions@v4
with:
package-name: 'com.github.binpastes.app'
package-type: 'maven'
min-versions-to-keep: 10
min-versions-to-keep: 3
- uses: actions/delete-package-versions@v4
with:
package-name: 'com.github.binpastes.frontend'
package-type: 'maven'
min-versions-to-keep: 10
min-versions-to-keep: 3
- uses: actions/delete-package-versions@v4
with:
package-name: 'com.github.binpastes.backend'
package-type: 'maven'
min-versions-to-keep: 10
min-versions-to-keep: 3
3 changes: 1 addition & 2 deletions backend/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>com.github.binpastes</groupId>
<artifactId>app</artifactId>
<version>${revision}</version>
<version>0.0.1-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand All @@ -17,7 +17,6 @@
<dependency>
<groupId>com.github.binpastes</groupId>
<artifactId>frontend</artifactId>
<version>${revision}</version>
</dependency>

<dependency>
Expand Down
4 changes: 2 additions & 2 deletions frontend/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>com.github.binpastes</groupId>
<artifactId>app</artifactId>
<version>${revision}</version>
<version>0.0.1-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand All @@ -19,7 +19,7 @@
<groupId>com.github.eirslett</groupId>
<artifactId>frontend-maven-plugin</artifactId>
<configuration>
<nodeVersion>v18.16.1</nodeVersion>
<nodeVersion>v18.18.2</nodeVersion>
</configuration>
<executions>
<execution>
Expand Down
3 changes: 1 addition & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

<groupId>com.github.binpastes</groupId>
<artifactId>app</artifactId>
<version>${revision}</version>
<version>0.0.1-SNAPSHOT</version>
<packaging>pom</packaging>
<name>BinPastes</name>

Expand All @@ -31,7 +31,6 @@
<properties>
<!-- maven property definition -->
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<revision>1.0.0-SNAPSHOT</revision>

<!-- java version properties -->
<maven.compiler.target>17</maven.compiler.target>
Expand Down

0 comments on commit 034a1e7

Please sign in to comment.