adds an update script to make updating to new versions easier
This commit is contained in:
parent
5dddeb2ff5
commit
191dc3aaec
|
|
@ -4,10 +4,11 @@ This is the very minimalistic Backlog for further development of this project.
|
|||
|
||||
## Soon
|
||||
|
||||
* add an update script to simplify the migration to new versions
|
||||
* add a configuration option to change the FMTS device name
|
||||
* add support for ANT+ heart rate monitors with USB dongles
|
||||
* add an option to the installation script to directly attach a touchscreen to the Raspberry Pi and automatically show WebUI on this in kiosk mode
|
||||
* validate FTMS with more training applications and harden implementation (i.e. Holofit and Coxswain)
|
||||
* record a longer rowing session and analyze two encountered problems: 1) rarely the stroke rate doubles for a short duration (might be a problem with stroke detection when measurements are imprecise), 2) in one occasion the measured power jumped to a very high value after a break (40000 watts)
|
||||
* add support for ANT+ heart rate monitors with USB dongles
|
||||
* add an option to automatically feed the measured damping constant back into the rowing engine
|
||||
|
||||
## Later
|
||||
|
|
@ -24,4 +25,3 @@ This is the very minimalistic Backlog for further development of this project.
|
|||
* add video playback in background of Web UI
|
||||
* implement or integrate some rowing games
|
||||
* add possibility to define workouts (i.e. training intervals with goals)
|
||||
* directly attach a touchscreen to the Raspberry Pi and automatically show WebUI on this in kiosk mode
|
||||
|
|
|
|||
|
|
@ -27,6 +27,14 @@ Connect to the device with SSH and initiate the following command to set up all
|
|||
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/laberning/openrowingmonitor/HEAD/install/install.sh)"
|
||||
```
|
||||
|
||||
### Updating to a new version
|
||||
|
||||
Open Rowing Monitor does not provide proper releases (yet), but you can update to the latest development version with this command:
|
||||
|
||||
```zsh
|
||||
sudo /opt/openrowingmonitor/install/update.sh
|
||||
```
|
||||
|
||||
### If you want to run Bluetooth Low Energy and the Web-Server on port 80 without root
|
||||
|
||||
```zsh
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ sudo npm config set user 0
|
|||
|
||||
print
|
||||
print "Downloading and compiling Runtime dependencies..."
|
||||
sudo npm install
|
||||
sudo npm ci
|
||||
sudo npm run build
|
||||
if ! [[ -f "config/config.js" ]]; then
|
||||
cp install/config.js config/
|
||||
|
|
|
|||
|
|
@ -0,0 +1,61 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# Open Rowing Monitor, https://github.com/laberning/openrowingmonitor
|
||||
#
|
||||
# Update script for Open Rowing Monitor, use at your own risk!
|
||||
#
|
||||
|
||||
# treat unset variables as an error when substituting
|
||||
set -u
|
||||
# exit when a command fails
|
||||
set -e
|
||||
|
||||
print() {
|
||||
printf "%s\n" "$@"
|
||||
}
|
||||
|
||||
cancel() {
|
||||
print "$@"
|
||||
exit 1
|
||||
}
|
||||
|
||||
CURRENT_DIR=$(pwd)
|
||||
INSTALL_DIR="/opt/openrowingmonitor"
|
||||
GIT_REMOTE="https://github.com/laberning/openrowingmonitor.git"
|
||||
|
||||
print "Update script for Open Rowing Monitor"
|
||||
print
|
||||
print "Checking for new version..."
|
||||
|
||||
cd $INSTALL_DIR
|
||||
|
||||
LOCAL_VERSION=$(git rev-parse HEAD)
|
||||
REMOTE_VERSION=$(git ls-remote $GIT_REMOTE HEAD | awk '{print $1;}')
|
||||
|
||||
if [ "$LOCAL_VERSION" = "$REMOTE_VERSION" ]; then
|
||||
print "You are using the latest version of Open Rowing Monitor."
|
||||
else
|
||||
print "A new version of Open Rowing Monitor is available. Do you want to update?"
|
||||
print
|
||||
read -p "Press RETURN to continue or CTRL + C to abort"
|
||||
print "Stopping Open Rowing Monitor..."
|
||||
sudo systemctl stop openrowingmonitor
|
||||
|
||||
print "Fetching new version of Open Rowing Monitor..."
|
||||
sudo git fetch --force origin
|
||||
sudo git fetch --force --tags origin
|
||||
sudo git reset --hard origin/main
|
||||
|
||||
print "Updating Runtime dependencies..."
|
||||
sudo npm ci
|
||||
sudo npm run build
|
||||
|
||||
print "Starting Open Rowing Monitor..."
|
||||
sudo systemctl start openrowingmonitor
|
||||
|
||||
print
|
||||
print "Update complete, Open Rowing Monitor now has the following exciting new features:"
|
||||
git log --reverse --pretty=format:"- %s" $LOCAL_VERSION..HEAD
|
||||
fi
|
||||
|
||||
cd $CURRENT_DIR
|
||||
Loading…
Reference in New Issue