Skip to content

Commit

Permalink
chore: Remove jq from javadoc script (googleapis#8316)
Browse files Browse the repository at this point in the history
  • Loading branch information
lqiu96 authored Sep 8, 2022
1 parent 8499860 commit e5b9ee7
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions .kokoro/release/publish_javadoc11.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,8 @@ pushd $(dirname "$0")/../../
# install docuploader package
python3 -m pip install gcp-docuploader

apt-get update
# install jq to extract field from json file
apt-get install -y jq

doclet_name="java-docfx-doclet-1.7.0.jar"

# compile all packages
#mvn clean install -B -q -DskipTests -Dcheckstyle.skip -Denforcer.skip=true -T 1C

# Retrieve list of modules from aggregator pom
modules=$(mvn help:evaluate -Dexpression=project.modules | grep '<.*>.*</.*>' | sed -e 's/<.*>\(.*\)<\/.*>/\1/g')
excluded_modules=('CoverageAggregator' 'google-cloud-gapic-bom')
Expand All @@ -48,8 +41,8 @@ do
# Proceed if module is not excluded
if [[ ! "${excluded_modules[*]}" =~ $module ]]; then
pushd $module
# Extract Cloud RAD module name
NAME=$(jq -r '.distribution_name' .repo-metadata.json | cut -d ':' -f 2)
# Extract Cloud RAD module name from `distribution_name` in .repo-metadata.json
NAME=$(grep -o '"distribution_name": "[^"]*' .repo-metadata.json | grep -o '[^"]*$' | cut -d ':' -f 2)
# Extract (current) version from versions.txt and remove `-SNAPSHOT`
VERSION=$(grep ${NAME}: versions.txt | cut -d: -f3 | sed -e 's/-SNAPSHOT//g')
echo "Running for ${NAME}-${VERSION}"
Expand Down

0 comments on commit e5b9ee7

Please sign in to comment.