Skip to content

Instantly share code, notes, and snippets.

View ravens's full-sized avatar
🏠
Working from home

Yan Grunenberger ravens

🏠
Working from home
View GitHub Profile
@ravens
ravens / madrid_opendata_no2.txt
Last active April 15, 2018 22:53
Madrid API Air quality
Maps : http://www.mambiente.munimadrid.es/sica/scripts/index.php
Raw data : http://www.mambiente.munimadrid.es/opendata/horario.txt
Code using those URL :
https://github.com/superzen/desktop-air-mad/blob/96e290c7661e4e89162e3bad2c440d4368edc60d/datasource/ayuntamientoMadridRepository.js
https://github.com/allancalderon/checkapp_webserver_pollution/blob/53e9249af3e76b668d2c228dc63ce88fc36762fe/pollution/geocode.php
https://github.com/blayhem/airmon/blob/494e0cd1ab0270095a303ffd568d89047f22557b/air.js#L45
Example of station (Mendez Alvaro, id = 47) : http://www.mambiente.munimadrid.es/opencms/opencms/calaire/SistemaIntegral/SistVigilancia/Estaciones/E47.html
http://www.mambiente.munimadrid.es/opencms/opencms/calaire/SistemaIntegral/SistVigilancia/Estaciones/E47.html -> codigo 28079047
to be converted into : 28079047 -> 28,079,047
@ravens
ravens / Dockerfile
Created August 2, 2017 06:33
OpenLTE in a Docker
# Build : docker build -t openlte --rm .
# Run : docker run -it --privileged --rm -v /dev/bus/usb:/dev/bus/usb --network=host openlte
# then inside the terminal : source /pybombs/setup_env.sh && LTE_fdd_enodeb
# from the main PC, open a new terminal and run : telnet 0 30000
# need to change band, configure Ki/IMSI and start the radio....
FROM pybombs/pybombs-prefix
MAINTAINER Yan Grunenberger <yan@grunenberger.net>
RUN apt-get -qy update
RUN pybombs install openlte
RUN /pybombs/lib/uhd/utils/uhd_images_downloader.py
@ravens
ravens / gist:b65fe139cd0d51f43814fc1b8a55c4de
Created April 12, 2017 06:53
Geoloc of mastodon instances
curl https://instances.mastodon.xyz/instances.json | jq '.[].name'| xargs -I '{}' geoiplookup '{}' | grep "GeoIP Country Edition:" | wc -l
523
curl https://instances.mastodon.xyz/instances.json | jq '.[].name'| xargs -I '{}' geoiplookup '{}' | grep "GeoIP Country Edition: FR" | wc -l
209
curl https://instances.mastodon.xyz/instances.json | jq '.[].name'| xargs -I '{}' geoiplookup '{}' | grep "GeoIP Country Edition: US" | wc -l
172
@ravens
ravens / gist:4056fff9330798787b70c4c393423edf
Last active December 6, 2016 09:09
oneliner shell pour km de bouchon sous sytadin
curl -s http://www.sytadin.fr/sys/barometre_courbe_cumul.jsp.html | xmllint --html --xpath '//*[@id="main_content"]/p[1]/strong/text()' --format - 2>/dev/null | grep -E -o "[0-9]+"
Avec timestamp :
echo `date +'%s'`","`curl -s http://www.sytadin.fr/sys/barometre_courbe_cumul.jsp.html | xmllint --html --xpath '//*[@id="main_content"]/p[1]/strong/text()' --format - 2>/dev/null | grep -E -o "[0-9]+"`
@ravens
ravens / keybase.md
Created July 22, 2015 07:08
keybase.md

Keybase proof

I hereby claim:

  • I am ravens on github.
  • I am yangrunenberger (https://keybase.io/yangrunenberger) on keybase.
  • I have a public key whose fingerprint is 6C48 D00E 7D21 691B F6E3 E534 A31B A19F D370 7427

To claim this, I am signing this object: