Skip to content

Commit 3441f06

Browse files
authored
chore: cleanup release scripts to prepare for migration to internal (#3718)
* chore: cleanup release scripts to prepare for migration to internal b/308610909 * missed one * fix promote.sh * Maven Super POM already includes attach-sources It's under the release-profile activated by -DperformRelease. See: https://maven.apache.org/ref/3.9.9/maven-model-builder/super-pom.html
1 parent cabb7a5 commit 3441f06

File tree

8 files changed

+14
-25
lines changed

8 files changed

+14
-25
lines changed

.github/workflows/unitTests.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ jobs:
117117
./mvnw \
118118
--batch-mode \
119119
--no-transfer-progress \
120-
-Drelease=true \
120+
-DperformRelease=true \
121121
-DskipTests \
122122
-Dgpg.skip \
123123
-Dcheckstyle.skip \

.kokoro/drop.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,6 @@ create_settings_xml_file $MAVEN_SETTINGS_FILE
3838
--batch-mode \
3939
--settings ${MAVEN_SETTINGS_FILE} \
4040
-DstagingRepositoryId=${STAGING_REPOSITORY_ID} \
41-
-Drelease=true
41+
-DperformRelease=true
4242

4343
popd

.kokoro/promote.sh

+1-2
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ create_settings_xml_file $MAVEN_SETTINGS_FILE
3838
--batch-mode \
3939
--settings ${MAVEN_SETTINGS_FILE} \
4040
-DstagingRepositoryId=${STAGING_REPOSITORY_ID} \
41-
-Drelease=true \
42-
--activate-profiles skip-unreleased-modules
41+
-DperformRelease=true \
4342

4443
popd

.kokoro/publish_javadoc.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ PROJECT_VERSION=$(grep "^spring-cloud-gcp:" "./versions.txt" | cut -d: -f3)
1616
python3 -m pip install --require-hashes -r .kokoro/requirements.txt
1717

1818
# Build the javadocs
19-
mvn clean javadoc:aggregate -Drelease=true
19+
mvn clean javadoc:aggregate -DperformRelease=true
2020

2121
# Move into generated docs directory
2222
pushd target/reports/apidocs/

.kokoro/stage.sh

+2-4
Original file line numberDiff line numberDiff line change
@@ -43,17 +43,15 @@ export MAVEN_OPTS="--add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.
4343
-Dgpg.executable=gpg \
4444
-Dgpg.passphrase=${GPG_PASSPHRASE} \
4545
-Dgpg.homedir=${GPG_HOMEDIR} \
46-
-Drelease=true \
47-
--activate-profiles skip-unreleased-modules
46+
-DperformRelease=true \
4847

4948
# promote release
5049
if [[ -n "${AUTORELEASE_PR}" ]]
5150
then
5251
./mvnw nexus-staging:release \
5352
--batch-mode \
5453
--settings ${MAVEN_SETTINGS_FILE} \
55-
-Drelease=true \
56-
--activate-profiles skip-unreleased-modules
54+
-DperformRelease=true \
5755
fi
5856

5957
popd

pom.xml

+2-15
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,7 @@
448448
<id>default</id>
449449
<activation>
450450
<property>
451-
<name>!release</name>
451+
<name>!performRelease</name>
452452
</property>
453453
</activation>
454454
<modules>
@@ -703,7 +703,7 @@
703703
<id>release</id>
704704
<activation>
705705
<property>
706-
<name>release</name>
706+
<name>performRelease</name>
707707
</property>
708708
</activation>
709709
<modules>
@@ -815,19 +815,6 @@
815815
</excludePackageNames>
816816
</configuration>
817817
</plugin>
818-
<plugin>
819-
<groupId>org.apache.maven.plugins</groupId>
820-
<artifactId>maven-source-plugin</artifactId>
821-
<executions>
822-
<execution>
823-
<id>attach-sources</id>
824-
<goals>
825-
<goal>jar</goal>
826-
</goals>
827-
<phase>package</phase>
828-
</execution>
829-
</executions>
830-
</plugin>
831818
<plugin>
832819
<groupId>org.codehaus.mojo</groupId>
833820
<artifactId>flatten-maven-plugin</artifactId>

spring-cloud-gcp-dependencies/pom.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@
318318
<id>release</id>
319319
<activation>
320320
<property>
321-
<name>release</name>
321+
<name>performRelease</name>
322322
</property>
323323
</activation>
324324
<build>

spring-cloud-gcp-starters/spring-cloud-gcp-starter-config/pom.xml

+5
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,11 @@
3636
<!-- skip for GA releases to Maven Central -->
3737
<profile>
3838
<id>skip-unreleased-modules</id>
39+
<activation>
40+
<property>
41+
<name>performRelease</name>
42+
</property>
43+
</activation>
3944
<build>
4045
<plugins>
4146
<plugin>

0 commit comments

Comments
 (0)