Skip to content

Instantly share code, notes, and snippets.

@alechemy
Created June 22, 2023 13:47
Show Gist options
  • Select an option

  • Save alechemy/c0851386077db797499253d8538b6e4e to your computer and use it in GitHub Desktop.

Select an option

Save alechemy/c0851386077db797499253d8538b6e4e to your computer and use it in GitHub Desktop.
Kobo Scripting - Syncthing and NickelMenu
menu_item :main :Start Syncthing :cmd_spawn :quiet :exec /mnt/onboard/.adds/stop_syncthing.sh
chain_always :nickel_setting :enable :force_wifi
chain_always :nickel_wifi :enable
chain_always :nickel_wifi :autoconnect_silent
chain_success :cmd_spawn :quiet :exec /mnt/onboard/.adds/start_syncthing.sh
menu_item :main :Stop Syncthing :cmd_spawn :quiet :exec /mnt/onboard/.adds/stop_syncthing.sh
chain_always :nickel_setting :disable :force_wifi
chain_always :nickel_wifi :disable
chain_always :nickel_misc :rescan_books
menu_item :main :Rescan :nickel_misc :rescan_books
#!/bin/sh
rm /mnt/onboard/syncthing.log
ifconfig lo | grep -q addr:127.0.0.1 || ifconfig lo 127.0.0.1
/mnt/onboard/.adds/syncthing -no-browser -home=/root/.syncthing -logfile=/mnt/onboard/syncthing.log &>/dev/null &
#!/bin/sh
killall -15 syncthing
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment