Last active
November 15, 2017 02:38
-
-
Save konpyu/9f1eab78bb19741f12f3aff4ed6dcb40 to your computer and use it in GitHub Desktop.
bus location fetcher
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| URL="http://tokyu.bus-location.jp/blsys/navi?VID=ldt&EID=nt&FID=&DSMK=2339&FDSN=0&DPMK=5801&PRM=&SCT=2" | |
| RES=`curl -L $URL | \ | |
| grep 渋谷駅 | \ | |
| sed -e 's/<[^>]*>//g' | \ | |
| sed -e 's/[[:blank:]]//g' | \ | |
| tr -d '\n' | \ | |
| sed -e 's/\ //g'` | |
| echo $RES | |
| terminal-notifier -message $RES -sound Basso -title '東急バス' -timeout 60 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment