Skip to content

Commit 3144383

Browse files
committed
remove unused vars and cleanup debugging prints
1 parent 9f6f727 commit 3144383

File tree

2 files changed

+3
-11
lines changed

2 files changed

+3
-11
lines changed

.evergreen/scripts/create-pr.sh

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,8 @@
22

33
tools="../drivers-evergreen-tools"
44
git clone https://github.com/mongodb-labs/drivers-evergreen-tools.git $tools
5-
body="$(cat "$1")"
65

7-
pushd $tools/.evergreen/github_app
6+
pushd $tools/.evergreen/github_app || exit
87

98
owner="mongodb"
109
repo="mongo-python-driver"
@@ -23,11 +22,11 @@ echo "Getting github token..."
2322
token=$(bash ./get-access-token.sh $repo $owner)
2423
if [ -z "${token}" ]; then
2524
echo "Failed to get github access token!"
26-
popd
25+
popd || exit
2726
exit 1
2827
fi
2928
echo "Getting github token... done."
30-
popd
29+
popd || exit
3130

3231
# Make the git checkout and create a new branch.
3332
echo "Creating the git checkout..."
@@ -40,19 +39,14 @@ git apply -R .evergreen/specs.patch
4039
git commit -am "resyncing specs test?"
4140
echo "Creating the git checkout... done."
4241

43-
echo "THIS IS THE BODY"
44-
echo "$body"
4542
git push origin $branch
46-
echo "{\"title\":\"[Spec Resync] $(date '+%m-%d-%Y')\",\"body\":\"$(cat "$1")\",\"head\":\"${branch}\",\"base\":\"master\"}"
4743
resp=$(curl -L \
4844
-X POST \
4945
-H "Accept: application/vnd.github+json" \
5046
-H "Authorization: Bearer $token" \
5147
-H "X-GitHub-Api-Version: 2022-11-28" \
5248
-d "{\"title\":\"[Spec Resync] $(date '+%m-%d-%Y')\",\"body\":\"$(cat "$1")\",\"head\":\"${branch}\",\"base\":\"master\"}" \
5349
--url https://api.github.com/repos/$owner/$repo/pulls)
54-
echo $resp
55-
echo $resp | jq '.html_url'
5650
echo "Creating the PR... done."
5751

5852
rm -rf $tools

.evergreen/scripts/resync-all-specs.sh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,10 @@
22
# Run spec syncing script and create PR
33

44
# SETUP
5-
SPEC_DEST="$(realpath -s "./test")"
65
SRC_URL="https://github.com/mongodb/specifications.git"
76
# needs to be set for resunc-specs.sh
87
SPEC_SRC="$(realpath -s "../specifications")"
98
SCRIPT="$(realpath -s "./.evergreen/resync-specs.sh")"
10-
BRANCH_NAME="spec-resync-"$(date '+%m-%d-%Y')
119

1210
# Clone the spec repo if the directory does not exist
1311
if [[ ! -d $SPEC_SRC ]]; then

0 commit comments

Comments
 (0)