-
Notifications
You must be signed in to change notification settings - Fork 7
/
upload-override-jars
executable file
·24 lines (18 loc) · 862 Bytes
/
upload-override-jars
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/usr/bin/env bash
set -eu
cd "$(dirname "$(realpath "${BASH_SOURCE[0]}")")"
# if [[ -n "$(git status --porcelain)" ]]; then
# echo "You have uncommitted changes! Refusing to run."
# exit 1
# fi
branch_name="$(git rev-parse --abbrev-ref HEAD)"
encoded_branch_name="$(curl -Gso /dev/null -w %{url_effective} --data-urlencode $branch_name "" | cut -c 3-)"
commit_hash="$(git rev-parse HEAD)"
# If your username on the your development machine doesn't match your username
# on foundry, put a block in ~/.ssh/config like the following:
#
# Host foundry.remexre.xyz
# User nathan
rsync -Pa jars/ foundry.remexre.xyz:/export/scratch/melt-jenkins/${commit_hash}-jars/
echo "Now go to https://foundry.remexre.xyz/jenkins/job/melt-umn/job/silver/job/$encoded_branch_name/build and"
echo "pass /export/scratch/melt-jenkins/${commit_hash}-jars as OVERRIDE_JARS"