Thank you https://gist.github.com/shuichinet/8159878
This is how I install on my mac
brew reinstall python
brew install libav
sudo pip install gmusicapi
pip install urllib3
| # Download fitbit weight as JSON and put in weight.json | |
| # Download it by accessing page in the web https://www.fitbit.com/weight?end-date=2018-03-20&period=all&start-date=2018-02-20 | |
| # and then find the content in the web traffic. Note that the API restricts to 30 days. | |
| cat fitbit-weight.json | python -m json.tool | grep 'dateTime\|weight' | awk 'ORS=/,$/?" ":"\n"' | awk '{print $1 $4}' > weight.csv | |
| # Then you can import this into where ever you want ... |
| #!/bin/bash | |
| # Set static routing tables to route some external IP addresses to a different gateway, for example if tend | |
| # to connect on a VPN and you want to route some traffic to avoid the VPN. | |
| # | |
| # I use this on a Mac - if you're lucky it might work on other operating systems. This script does update | |
| # your /etc/hosts files AND route table. Take appropriate due care. | |
| # | |
| # Usage | |
| # ----- |
| # If syslog is big then you can rotate log and then clear up | |
| savelog -g adm -m 640 -u root -c 7 /var/log/syslog |
| #!/bin/bash | |
| # Set static routing tables to route some external IP addresses | |
| # direct instead of via VPN | |
| action=${1:-create} | |
| gateway=${2:-192.168.1.254} | |
| nonVpnHosts=${3:-$NON_VPN_HOSTS} | |
| if [ -z "$nonVpnHosts" ] ; then |
Thank you https://gist.github.com/shuichinet/8159878
This is how I install on my mac
brew reinstall python
brew install libav
sudo pip install gmusicapi
pip install urllib3
| # curl not smart enough for ipv6, so force ipv4 | |
| # on my mac I started to get localhost connect failure | |
| # | |
| # curl: (7) Failed to connect to localhost port 9031: Connection refused | |
| echo '--ipv4' >> ~/.curlrc |
| # -c => Continue after error | |
| ldapadd -c -x -W -D "cn=admin,dc=id,dc=sdl,dc=com" -f id_test_data.ldif |
| ack needle |
| find . -name "*.jar" -exec unzip -p {} META-INF/MANIFEST.MF \; | grep Implementation |
| # Add to /etc/bashrc to customise command prompt | |
| [ "$PS1" = "\\s-\\v\\\$ " ] && PS1="(production) - \u@\[\e[1;31m\]myhost.com\[\e[0m\]:\w \\$ " |