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

Use jgitver to manage versions #1075

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
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
8 changes: 8 additions & 0 deletions .mvn/extensions.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<extensions xmlns="http://maven.apache.org/EXTENSIONS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/EXTENSIONS/1.0.0 http://maven.apache.org/xsd/core-extensions-1.0.0.xsd">
<extension>
<groupId>fr.brouillard.oss</groupId>
<artifactId>jgitver-maven-plugin</artifactId>
<version>1.9.0</version>
</extension>
</extensions>
8 changes: 8 additions & 0 deletions .mvn/jgitver.config.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<configuration xmlns="http://jgitver.github.io/maven/configuration/1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://jgitver.github.io/maven/configuration/1.1.0 https://jgitver.github.io/maven/configuration/jgitver-configuration-v1_1_0.xsd">

<useDirty>true</useDirty>
<nonQualifierBranches>main</nonQualifierBranches>
<regexVersionTag>pushy-(.+)</regexVersionTag>
</configuration>
22 changes: 22 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,28 @@ To build a mock server, callers should use a [`MockApnsServerBuilder`](https://p

Callers may also provide a [`MockApnsServerListener`](https://pushy-apns.org/apidocs/0.15/com/eatthepath/pushy/apns/server/MockApnsServerListener.html) when building a mock server; listeners are notified whenever the mock server accepts or rejects a notification from a client.

## Building Pushy

Pushy uses [Maven](https://maven.apache.org/) as its build system. To build Pushy from source:

```shell
./mvnw clean package
```

…or to run tests:

```shell
./mvnw clean test
```

### For IntelliJ IDEA users

Note that IntelliJ IDEA struggles with multi-module projects that set their versions on the fly (like Pushy). Please see [IDEA-187928](https://youtrack.jetbrains.com/issue/IDEA-187928/Jgitver-not-working-at-all-for-a-multimodule-project) for background and discussion, but in short, IntelliJ users are likely to encounter an error something like:

> Could not find artifact com.eatthepath:pushy:jar:tests:0.15.5-SNAPSHOT

To work around the issue, IntelliJ users can navigate to Settings → Build, Execution, Deployment → Build Tools → Maven → Importing and add `-Djgitver.skip=true` to "VM options for importer."

## License and status

Pushy is available under the [MIT License](https://github.com/jchambers/pushy/blob/master/LICENSE.md).
Expand Down
3 changes: 1 addition & 2 deletions benchmark/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,10 @@
<parent>
<artifactId>pushy-parent</artifactId>
<groupId>com.eatthepath</groupId>
<version>0.15.5-SNAPSHOT</version>
<version>JGITVER</version>
</parent>

<artifactId>pushy-benchmark</artifactId>
<version>0.15.5-SNAPSHOT</version>
<packaging>jar</packaging>

<name>Pushy benchmarks</name>
Expand Down
3 changes: 1 addition & 2 deletions dropwizard-metrics-listener/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,13 @@
<modelVersion>4.0.0</modelVersion>

<artifactId>pushy-dropwizard-metrics-listener</artifactId>
<version>0.15.5-SNAPSHOT</version>
<name>Dropwizard Metrics listener for Pushy</name>
<description>A metrics listener for Pushy that uses the Dropwizard Metrics library for gathering and reporting metrics.</description>

<parent>
<groupId>com.eatthepath</groupId>
<artifactId>pushy-parent</artifactId>
<version>0.15.5-SNAPSHOT</version>
<version>JGITVER</version>
</parent>

<dependencies>
Expand Down
3 changes: 1 addition & 2 deletions gson-payload-builder/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,13 @@
<modelVersion>4.0.0</modelVersion>

<artifactId>pushy-gson-payload-builder</artifactId>
<version>0.15.5-SNAPSHOT</version>
<name>Gson APNs payload builder for Pushy</name>
<description>A payload builder for Pushy that uses Gson to serialize payloads.</description>

<parent>
<artifactId>pushy-parent</artifactId>
<groupId>com.eatthepath</groupId>
<version>0.15.5-SNAPSHOT</version>
<version>JGITVER</version>
</parent>

<dependencies>
Expand Down
3 changes: 1 addition & 2 deletions jackson-payload-builder/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,13 @@
<modelVersion>4.0.0</modelVersion>

<artifactId>pushy-jackson-payload-builder</artifactId>
<version>0.15.5-SNAPSHOT</version>
<name>Jackson APNs payload builder for Pushy</name>
<description>A payload builder for Pushy that uses Jackson to serialize payloads.</description>

<parent>
<artifactId>pushy-parent</artifactId>
<groupId>com.eatthepath</groupId>
<version>0.15.5-SNAPSHOT</version>
<version>JGITVER</version>
</parent>

<dependencies>
Expand Down
2 changes: 1 addition & 1 deletion micrometer-metrics-listener/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
<parent>
<artifactId>pushy-parent</artifactId>
<groupId>com.eatthepath</groupId>
<version>0.15.5-SNAPSHOT</version>
<version>JGITVER</version>
</parent>

<dependencies>
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
<groupId>com.eatthepath</groupId>
<artifactId>pushy-parent</artifactId>
<packaging>pom</packaging>
<version>0.15.5-SNAPSHOT</version>
<version>JGITVER</version>

<name>Pushy parent</name>
<description>A Java library for sending APNs (iOS/macOS/Safari) push notifications</description>
Expand Down
3 changes: 1 addition & 2 deletions pushy/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,13 @@
<modelVersion>4.0.0</modelVersion>

<artifactId>pushy</artifactId>
<version>0.15.5-SNAPSHOT</version>
<packaging>bundle</packaging>
<name>Pushy</name>

<parent>
<groupId>com.eatthepath</groupId>
<artifactId>pushy-parent</artifactId>
<version>0.15.5-SNAPSHOT</version>
<version>JGITVER</version>
</parent>

<dependencies>
Expand Down