From 3fd592e64b81238947282bafaae796a8599a277a Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Sun, 5 Jun 2022 20:25:58 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=94=20Update=20Marlin=20actions=20for?= =?UTF-8?q?=202.1.x?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- buildroot/bin/use_example_configs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/buildroot/bin/use_example_configs b/buildroot/bin/use_example_configs index d6b479e040..48e23b1695 100755 --- a/buildroot/bin/use_example_configs +++ b/buildroot/bin/use_example_configs @@ -1,8 +1,10 @@ #!/usr/bin/env bash +BRANCH=$(git branch 2>/dev/null | grep ^* | sed 's/\* //g') + IFS=: read -r PART1 PART2 <<< "$@" [ -n "${PART2}" ] && { REPO="$PART1" ; RDIR="${PART2// /%20}" ; } \ - || { REPO=bugfix-2.1.x ; RDIR="${PART1// /%20}" ; } + || { REPO=$BRANCH ; RDIR="${PART1// /%20}" ; } EXAMPLES="https://raw.githubusercontent.com/MarlinFirmware/Configurations/$REPO/config/examples" which curl >/dev/null && TOOL='curl -L -s -S -f -o wgot'