Skip to content

Commit 307351c

Browse files
committed
Do not version protobuf files + renamed packages (#170)
1 parent 93fffc4 commit 307351c

74 files changed

Lines changed: 1164 additions & 151321 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,11 @@ This project uses [Maven](https://maven.apache.org/), after installing it you ca
5454

5555
To run the newly build jar run `java -jar ./core/target/librespot-core-jar-with-dependencies.jar`.
5656

57+
## Protobuf generation
58+
The compiled Java protobuf definitions aren't versioned, therefore, if you want to open the project inside you're IDE, you'll need to run `mvn compile` first to ensure that all the necessary files are created.
59+
The `com.spotify` package is reserved for the generated files.
60+
61+
5762
## Related Projects
5863
- [librespot](https://github.com/librespot-org/librespot)
5964
- [ansible-role-librespot](https://github.com/xMordax/ansible-role-librespot/tree/master) - Ansible role that will build, install and configure librespot-java.

common/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/src/**/java/com/spotify

common/pom.xml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,56 @@
2626
<version>${gson.version}</version>
2727
</dependency>
2828
</dependencies>
29+
30+
<build>
31+
<extensions>
32+
<extension>
33+
<groupId>kr.motd.maven</groupId>
34+
<artifactId>os-maven-plugin</artifactId>
35+
<version>1.6.2</version>
36+
</extension>
37+
</extensions>
38+
<plugins>
39+
<plugin>
40+
<artifactId>maven-clean-plugin</artifactId>
41+
<version>3.0.0</version>
42+
<executions>
43+
<execution>
44+
<id>clean-generate-proto</id>
45+
<phase>clean</phase>
46+
<goals>
47+
<goal>clean</goal>
48+
</goals>
49+
<configuration>
50+
<filesets>
51+
<fileset>
52+
<directory>${basedir}/src/main/java/com/spotify</directory>
53+
<includes>**</includes>
54+
</fileset>
55+
</filesets>
56+
</configuration>
57+
</execution>
58+
</executions>
59+
</plugin>
60+
61+
<plugin>
62+
<groupId>org.xolstice.maven.plugins</groupId>
63+
<artifactId>protobuf-maven-plugin</artifactId>
64+
<version>0.6.1</version>
65+
<configuration>
66+
<protocArtifact>com.google.protobuf:protoc:3.11.0:exe:${os.detected.classifier}</protocArtifact>
67+
<outputDirectory>${basedir}/src/main/java</outputDirectory>
68+
<clearOutputDirectory>false</clearOutputDirectory>
69+
</configuration>
70+
<executions>
71+
<execution>
72+
<goals>
73+
<goal>compile</goal>
74+
<goal>test-compile</goal>
75+
</goals>
76+
</execution>
77+
</executions>
78+
</plugin>
79+
</plugins>
80+
</build>
2981
</project>

common/src/main/java/com/spotify/connectstate/model/Connect.java

Lines changed: 0 additions & 14381 deletions
This file was deleted.

common/src/main/java/com/spotify/connectstate/model/Player.java

Lines changed: 0 additions & 13674 deletions
This file was deleted.

common/src/main/java/com/spotify/metadata/proto/Metadata.java

Lines changed: 0 additions & 34612 deletions
This file was deleted.

common/src/main/java/com/spotify/playlist4/proto/Playlist4ApiProto.java

Lines changed: 0 additions & 23232 deletions
This file was deleted.

0 commit comments

Comments
 (0)