hi cubii,

Have a look at ~/.local/bin/copywww.sh

I have used this script during development for years to copy the pCP GUI
to various RPi's for testing. Just modify the scp line to suit.


Code:
--------------------
    #!/bin/sh
  
  # Version: 6.0.0 2019-06-30
  
  
#========================================================================================
  # This script copies www and it's sub directories from the local piCorePlayer 
to a
  # remote piCorePlayer. It also does a backup.
  #
  # You will be prompted for the remote piCorePlayer's password twice.
  
#----------------------------------------------------------------------------------------
  
  if [ x"" = x"$1" ]; then
  echo "Usage: $0 192.168.1.xxx"
  exit 1
  else
  scp -r -p /home/tc/www/* tc@$1:/home/tc/www/
  ssh tc@$1 sudo filetool.sh -b
  fi
  
  exit 0
  
--------------------


It will prompt for passwords unless you "'Setup passwordless ssh access'
(https://docs.picoreplayer.org/how-to/setup_passwordless_ssh_access/)".
Probably no worth the effort unless you do it alot.

regards
Greg


------------------------------------------------------------------------
Greg Erskine's Profile: http://forums.slimdevices.com/member.php?userid=7403
View this thread: http://forums.slimdevices.com/showthread.php?t=113438

_______________________________________________
diy mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/diy

Reply via email to