Skip to content

Instantly share code, notes, and snippets.

@AlexandreRio
Last active February 10, 2016 09:28
Show Gist options
  • Save AlexandreRio/697c13b31f78c37a128c to your computer and use it in GitHub Desktop.
Save AlexandreRio/697c13b31f78c37a128c to your computer and use it in GitHub Desktop.
Wrapper around ino (inotools) to build and upload arduino firmware
#!/bin/bash
# requirements: ano, picocom, dmenu...
LIB="$HOME/SINTEF/lib-arduino/"
SOURCE=`find $PWD -name '*.pde' | xargs ls -1t | dmenu -l 10`
if [ -z $SOURCE ] ; then
echo "Canceling build"
else
cd /tmp/
fold="ano`date +%s`"
mkdir $fold
cd $fold
mkdir src lib
cp $SOURCE src/
ln -s $LIB lib
ano build
ano upload
ano serial
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment