File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- name : Publish package to the JFROG Artifactory
1+ name : Publish v3 module to the JFROG Artifactory
22on :
33 push :
44 tags-ignore :
55 - ' *.*'
66 paths-ignore :
77 - " *.md"
88 branches :
9- - release/*
9+ - v3- release/*
1010
1111jobs :
12- build-and-deploy :
12+ build-and-deploy-v3 :
1313 uses : ./.github/workflows/shared-build-and-deploy.yml
1414 with :
1515 ref : ${{ github.ref_name }}
1616 server-id : central
1717 profile : jfrog
1818 tag : ' internal'
19+ module : ' v3'
1920 secrets :
2021 server-username : ${{ secrets.ARTIFACTORY_USERNAME }}
2122 server-password : ${{ secrets.ARTIFACTORY_PASSWORD }}
2223 gpg-key : ${{ secrets.JFROG_GPG_KEY }}
2324 gpg-passphrase : ${{ secrets.JFROG_GPG_PASSPHRASE }}
2425 skyflow-credentials : ${{ secrets.SKYFLOW_CREDENTIALS }} >> .env
2526 test-expired-token : ${{ secrets.TEST_EXPIRED_TOKEN }} >> .env
26- test-reusable-token : ${{ secrets.TEST_REUSABLE_TOKEN }} >> .env
27+ test-reusable-token : ${{ secrets.TEST_REUSABLE_TOKEN }} >> .env
Original file line number Diff line number Diff line change 2121 description : ' Release Tag'
2222 required : true
2323 type : string
24+
25+ module :
26+ description : ' Module to build and publish'
27+ required : false
28+ type : string
29+ default : ' '
30+
2431 secrets :
2532 server-username :
2633 required : true
99106 git checkout ${{ env.branch_name }}
100107 fi
101108
102- git add pom.xml
109+ git add v3/ pom.xml
103110 if [[ "${{ inputs.tag }}" == "internal" ]]; then
104111 git commit -m "[AUTOMATED] Private Release ${{ steps.previoustag.outputs.tag }}-dev-$(git rev-parse --short $GITHUB_SHA)"
105112 git push origin ${{ github.ref_name }} -f
@@ -125,9 +132,14 @@ jobs:
125132 json : ${{ secrets.TEST_CREDENTIALS_FILE_STRING }}
126133
127134 - name : Publish package
128- run : mvn --batch-mode deploy -P ${{ inputs.profile }}
135+ run : |
136+ if [ -n "${{ inputs.module }}" ]; then
137+ mvn --batch-mode -pl v3 -am deploy -P jfrog
138+ else
139+ mvn --batch-mode deploy -P ${{ inputs.profile }}
140+ fi
129141
130142 env :
131143 SERVER_USERNAME : ${{ secrets.server-username }}
132144 SERVER_PASSWORD : ${{ secrets.server-password }}
133- GPG_PASSPHRASE : ${{ secrets.gpg-passphrase }}
145+ GPG_PASSPHRASE : ${{ secrets.gpg-passphrase }}
Original file line number Diff line number Diff line change 55 <modelVersion >4.0.0</modelVersion >
66 <parent >
77 <groupId >com.skyflow</groupId >
8- <artifactId >skyflow-java </artifactId >
8+ <artifactId >skyflow</artifactId >
99 <version >1.0.0</version >
10+ <relativePath >../pom.xml</relativePath >
1011 </parent >
1112
1213 <artifactId >common</artifactId >
1314 <version >1.0.0</version >
1415
16+
1517 <properties >
1618 <maven .compiler.source>8</maven .compiler.source>
1719 <maven .compiler.target>8</maven .compiler.target>
Original file line number Diff line number Diff line change 55 <modelVersion >4.0.0</modelVersion >
66
77 <groupId >com.skyflow</groupId >
8- <artifactId >skyflow-java </artifactId >
8+ <artifactId >skyflow</artifactId >
99 <version >1.0.0</version >
1010 <packaging >pom</packaging >
1111
3737 </scm >
3838
3939 <properties >
40+ <maven .deploy.skip>true</maven .deploy.skip>
4041 <maven .compiler.source>8</maven .compiler.source>
4142 <maven .compiler.target>8</maven .compiler.target>
4243 <okhttp-version >4.12.0</okhttp-version >
256257 <url >https://repo.maven.apache.org/maven2/</url >
257258 </repository >
258259 </repositories >
259-
260260 <profiles >
261- <profile >
262- <id >maven-central</id >
263- <distributionManagement >
264- <repository >
265- <id >central</id >
266- <url >https://central.sonatype.com/api/v1/publisher/upload</url >
267- </repository >
268- <snapshotRepository >
269- <id >central-snapshots</id >
270- <url >https://central.sonatype.com/api/v1/publisher/upload</url >
271- </snapshotRepository >
272- </distributionManagement >
273- <build >
274- <plugins >
275- <plugin >
276- <groupId >org.sonatype.central</groupId >
277- <artifactId >central-publishing-maven-plugin</artifactId >
278- <version >0.4.0</version >
279- <extensions >true</extensions >
280- <configuration >
281- <publishingServerId >central</publishingServerId >
282- <tokenAuth >true</tokenAuth >
283- <autoPublish >true</autoPublish >
284- </configuration >
285- </plugin >
286- </plugins >
287- </build >
288- </profile >
289261 <profile >
290262 <id >jfrog</id >
291263 <distributionManagement >
302274 </distributionManagement >
303275 </profile >
304276 </profiles >
305- </project >
277+ </project >
Original file line number Diff line number Diff line change 11# Input Arguments
22Version=$1
33CommitHash=$2
4- PomFile=" $GITHUB_WORKSPACE /pom.xml"
4+ PomFile=" $GITHUB_WORKSPACE /v3/ pom.xml"
55
66if [ -z " $Version " ]; then
77 echo " Error: Version argument is required."
@@ -26,15 +26,16 @@ if [ -z "$CommitHash" ]; then
2626else
2727 echo " Bumping main project version to $Version -dev-$CommitHash "
2828
29- awk -v version=" $Version -dev.$CommitHash " '
30- BEGIN { updated = 0 }
31- /<version>/ && updated == 0 {
32- sub(/<version>.*<\/version>/, "<version>" version "</version>")
33- updated = 1
34- }
35- { print }
36- ' " $PomFile " > tempfile && cat tempfile > " $PomFile " && rm -f tempfile
29+ awk -v version=" $Version ${CommitHash: +-dev.$CommitHash } " '
30+ BEGIN { updated = 0 }
31+ /<parent>/,/<\/parent>/ { print; next }
32+ /<version>/ && updated == 0 {
33+ sub(/<version>.*<\/version>/, "<version>" version "</version>")
34+ updated = 1
35+ }
36+ { print }
37+ ' " $PomFile " > tempfile && cat tempfile > " $PomFile " && rm -f tempfile
3738
38- echo " --------------------------"
39- echo " Done. Main project version now at $Version -dev.$CommitHash "
40- fi
39+ echo " --------------------------"
40+ echo " Done. v3 module version now at $Version ${CommitHash : + -dev.$CommitHash } "
41+ fi
Original file line number Diff line number Diff line change 55 <modelVersion >4.0.0</modelVersion >
66 <parent >
77 <groupId >com.skyflow</groupId >
8- <artifactId >skyflow-java </artifactId >
8+ <artifactId >skyflow</artifactId >
99 <version >1.0.0</version >
1010 <relativePath >../pom.xml</relativePath >
1111 </parent >
1212
1313 <artifactId >skyflow-java</artifactId >
14- <version >2.0.0-beta.2 </version >
15- <packaging >jar</ packaging >
14+ <version >2.0.0-beta.3 </version >
15+ <groupId >com.skyflow</ groupId >
1616
1717 <properties >
1818 <maven .compiler.source>8</maven .compiler.source>
2626 <artifactId >common</artifactId >
2727 <version >1.0.0</version >
2828 </dependency >
29- </dependencies >
3029
31- <build >
32- <plugins >
33- <plugin >
34- <groupId >org.apache.maven.plugins</groupId >
35- <artifactId >maven-shade-plugin</artifactId >
36- <version >3.6.0</version >
37- <executions >
38- <execution >
39- <phase >package</phase >
40- <goals >
41- <goal >shade</goal >
42- </goals >
43- <configuration >
44- <artifactSet >
45- <includes >
46- <include >com.skyflow:common</include >
47- </includes >
48- </artifactSet >
49- </configuration >
50- </execution >
51- </executions >
52- </plugin >
53- </plugins >
54- </build >
30+ </dependencies >
5531</project >
Original file line number Diff line number Diff line change 55 <modelVersion >4.0.0</modelVersion >
66 <parent >
77 <groupId >com.skyflow</groupId >
8- <artifactId >skyflow-java </artifactId >
8+ <artifactId >skyflow</artifactId >
99 <version >1.0.0</version >
1010 <relativePath >../pom.xml</relativePath >
1111 </parent >
1212
1313 <artifactId >skyflow-java</artifactId >
14- <version >3 .0.0-beta.0 </version >
14+ <version >2 .0.0-beta.2-dev.7db56c6 </version >
1515 <packaging >jar</packaging >
1616
1717 <properties >
1818 <maven .compiler.source>8</maven .compiler.source>
1919 <maven .compiler.target>8</maven .compiler.target>
2020 <project .build.sourceEncoding>UTF-8</project .build.sourceEncoding>
21+ <maven .deploy.skip>false</maven .deploy.skip>
2122 </properties >
2223
24+
25+
2326 <dependencies >
2427 <dependency >
2528 <groupId >com.skyflow</groupId >
You can’t perform that action at this time.
0 commit comments