Skip to content

Instantly share code, notes, and snippets.

@pdp7
Last active June 14, 2020 11:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pdp7/7062b569ef5f927d8ac0c5a5f7e74da0 to your computer and use it in GitHub Desktop.
Save pdp7/7062b569ef5f927d8ac0c5a5f7e74da0 to your computer and use it in GitHub Desktop.
# adebian@beaglebone:~$ cat run.sh
sudo /home/debian/extract.sh
ls -ltar /lib/modules/5.7*
ls -ltar /boot/dtbs/5.7*
echo sudo reboot
# debian@beaglebone:~$ cat extract.sh
sudo date -s "9 JUL 2020 11:14:00"
sudo tar -C / -xvf 5.7.0-rc6-omap2plus-r0-modules.tar.gz
sudo tar -C /boot/dtbs/5.7.0-rc6-omap2plus-r0/ -xvf 5.7.0-rc6-omap2plus-r0-dtbs.tar.gz
sudo cp 5.7.0-rc6-omap2plus-r0.zImage /boot/vmlinuz-5.7.0-rc6-omap2plus-r0
##############################
# refresh.sh
###############################
#!/bin/bash
SLEEP="$1"
if [ -z "$1" ]; then
SLEEP=0
fi
echo SLEEP=$SLEEP
while [ /bin/true ]; do
dhclient -r enx9884e391a556
dhclient enx9884e391a556
ifconfig enx9884e391a556
dhclient -r enx1cba8ca2ed6c
dhclient enx1cba8ca2ed6c
ifconfig enx1cba8ca2ed6c
dhclient -r eth0
dhclient eth0
ifconfig eth0
dhclient -r eth1
dhclient eth1
ifconfig eth1
if [ "$SLEEP" = "0" ]; then
exit 0
fi
sleep $SLEEP
done
# sudo ~/bin/refresh.sh && ./tools/rebuild.sh && scp deploy/*.* debian@192.168.7.2:. && ssh debian@192.168.7.2 'sudo ~/run.sh' && sudo ~/bin/refresh.sh 30
@pdp7
Copy link
Author

pdp7 commented Jun 14, 2020

sudo ~/bin/refresh.sh && ./tools/rebuild.sh && scp deploy/*.* debian@192.168.7.2:. && ssh debian@192.168.7.2 'sudo ~/run.sh'; sudo ~/bin/refresh.sh 15

@pdp7
Copy link
Author

pdp7 commented Jun 14, 2020

#!/bin/sh
stty cols 100 
stty rows 40

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment