Skip to content

Commit b124559

Browse files
committed
Make sure to mark the file check wizard as seen
1 parent 2b04af3 commit b124559

File tree

4 files changed

+18
-0
lines changed

4 files changed

+18
-0
lines changed

scripts/01-add-yq

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
set -x
2+
set -e
3+
4+
export LC_ALL=C
5+
6+
source /common.sh
7+
install_cleanup_trap
8+
9+
# if pb is there, we don't need to do anything
10+
[ -f /usr/local/bin/yq ] && exit 0
11+
12+
curl -L -o /usr/local/bin/yq https://github.com/mikefarah/yq/releases/download/v4.43.1/yq_linux_arm
13+
chmod +x /usr/local/bin/yq

scripts/01-update-octoprint renamed to scripts/02-update-octoprint

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,8 @@ if [ -n "$OCTOPRINT_VERSION" ]; then
1414
else
1515
sudo -u pi /home/pi/oprint/bin/pip install -U OctoPrint $BUNDLED
1616
fi
17+
18+
# make sure to mark the file check wizard as seen
19+
if [ $(/usr/local/bin/yq '.server.seenWizards.file_check' /home/pi/.octoprint/config.yaml) == "null" ]; then
20+
sudo -u pi FILECHECK_WIZARD=$(sudo -u pi /home/pi/oprint/bin/python -c "import octoprint_file_check; print(octoprint_file_check.WIZARD_VERSION)") /usr/local/bin/yq -i '.server.seenWizards.file_check = env(FILECHECK_WIZARD)' /home/pi/.octoprint/config.yaml
21+
fi
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)