mirror of
https://github.com/BX-Team/DivineMC.git
synced 2025-12-19 14:59:25 +00:00
Upstream has released updates that appear to apply and compile correctly Purpur Changes: PurpurMC/Purpur@7399988c Fix hover in /plugins PurpurMC/Purpur@5e5857dc [ci/skip] modify ci skip references in paper upstream commits
27 lines
702 B
Bash
Executable File
27 lines
702 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
# requires curl & jq
|
|
|
|
# upstreamCommit <old hash>
|
|
|
|
function getCommits() {
|
|
curl -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/"$1"/compare/"$2"...HEAD | jq -r '.commits[] | "'"$1"'@\(.sha[:8]) \(.commit.message | split("\r\n")[0] | split("\n")[0])" | sub("\\[ci( |-)skip]"; "[ci/skip]")'
|
|
}
|
|
|
|
(
|
|
set -e
|
|
PS1="$"
|
|
|
|
# Purpur updates
|
|
purpurHash="$1"
|
|
purpur=$(getCommits "PurpurMC/Purpur" "$purpurHash")
|
|
updated="Purpur"
|
|
logsuffix="\n\nPurpur Changes:\n$purpur"
|
|
|
|
disclaimer="Upstream has released updates that appear to apply and compile correctly"
|
|
log="Updated Upstream ($updated)\n\n${disclaimer}${logsuffix}"
|
|
|
|
echo -e "$log" | git commit -F -
|
|
|
|
) || exit 1
|