Skip to content

Commit

Permalink
fix: Add shopt -s nullglob to dependencies script (#1412)
Browse files Browse the repository at this point in the history
This PR was generated using Autosynth. 🌈

Synth log will be available here:
https://source.cloud.google.com/results/invocations/5578fa0d-17b2-4f89-98ac-63f3516a90a9/targets

- [ ] To automatically regenerate this PR, check this box. (May take up to 24 hours.)

Source-Link: googleapis/synthtool@87254ac
Source-Link: googleapis/synthtool@1c0c698
Source-Link: googleapis/synthtool@8f76a88

fix: Update dependencies.sh to not break on mac
  • Loading branch information
yoshi-automation authored Jul 14, 2021
1 parent 33acb86 commit 933b0bd
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
1 change: 0 additions & 1 deletion .kokoro/coerce_logs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ job=$(basename ${KOKORO_JOB_NAME})
echo "coercing sponge logs..."
for xml in `find . -name *-sponge_log.xml`
do
echo "processing ${xml}"
class=$(basename ${xml} | cut -d- -f2)
dir=$(dirname ${xml})/${job}/${class}
text=$(dirname ${xml})/${class}-sponge_log.txt
Expand Down
5 changes: 3 additions & 2 deletions .kokoro/dependencies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
# limitations under the License.

set -eo pipefail
shopt -s nullglob

## Get the directory of the build script
scriptDir=$(realpath $(dirname "${BASH_SOURCE[0]}"))
Expand Down Expand Up @@ -46,7 +47,7 @@ function completenessCheck() {
# This is stripped from the output as it is not present in the flattened pom.
# Only dependencies with 'compile' or 'runtime' scope are included from original dependency list.
msg "Generating dependency list using original pom..."
mvn dependency:list -f pom.xml -DincludeScope=runtime -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' | sed -e s/\\s--\\smodule.*// >.org-list.txt
mvn dependency:list -f pom.xml -DincludeScope=runtime -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' | sed -e 's/ --.*//' >.org-list.txt

# Output dep list generated using the flattened pom (only 'compile' and 'runtime' scopes)
msg "Generating dependency list using flattened pom..."
Expand All @@ -70,7 +71,7 @@ function completenessCheck() {
set +e

error_count=0
for path in $(find -name ".flattened-pom.xml")
for path in **/.flattened-pom.xml
do
# Check flattened pom in each dir that contains it for completeness
dir=$(dirname "$path")
Expand Down
5 changes: 3 additions & 2 deletions synth.metadata
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@
"git": {
"name": ".",
"remote": "https://github.com/googleapis/google-http-java-client.git",
"sha": "e69275ecaa4d85372ebc253dd415a02ba63075be"
"sha": "33acb8621d6e8dc088cf3bd3324a3db25dafb185"
}
},
{
"git": {
"name": "synthtool",
"remote": "https://github.com/googleapis/synthtool.git",
"sha": "8eae0234a16b26c2ff616d305dbd9786c8b10a47"
"sha": "87254ac89a9559864c0a245d6b150406439ce3d8"
}
}
],
Expand Down Expand Up @@ -81,6 +81,7 @@
"CODE_OF_CONDUCT.md",
"CONTRIBUTING.md",
"LICENSE",
"SECURITY.md",
"codecov.yaml",
"renovate.json",
"samples/install-without-bom/pom.xml",
Expand Down

0 comments on commit 933b0bd

Please sign in to comment.