Skip to content

Commit

Permalink
scripts + scrapers
Browse files Browse the repository at this point in the history
  • Loading branch information
lukas-h committed Apr 15, 2017
1 parent 2766b98 commit c394f0e
Show file tree
Hide file tree
Showing 33 changed files with 45 additions and 542 deletions.
3 changes: 1 addition & 2 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,4 @@ url: https://opendata-heilbronn.github.io
markdown: kramdown
permalink: pretty
exclude:
- _data/test.json
- _data/data.json
- scripts/
193 changes: 0 additions & 193 deletions _data/data.json

This file was deleted.

347 changes: 0 additions & 347 deletions _data/test.json

This file was deleted.

Binary file added audio/allee-9.mp3
Binary file not shown.
Binary file added audio/bahnhofstrasse-11.mp3
Binary file not shown.
Binary file added audio/bahnhofstrasse-5.mp3
Binary file not shown.
Binary file added audio/bismarckstrasse-15.mp3
Binary file not shown.
Binary file added audio/boeckingen-klingenberger-strasse-74.mp3
Binary file not shown.
Binary file added audio/boeckingen-teichstrasse-8.mp3
Binary file not shown.
Binary file added audio/gartenstrasse-50.mp3
Binary file not shown.
Binary file added audio/gymnasiumstrasse-31.mp3
Binary file not shown.
Binary file added audio/gymnasiumstrasse-32.mp3
Binary file not shown.
Binary file added audio/herbststrasse-30.mp3
Binary file not shown.
Binary file added audio/innsbrucker-strasse-31.mp3
Binary file not shown.
Binary file added audio/kaiserstrasse-34.mp3
Binary file not shown.
Binary file added audio/karlstrasse-13.mp3
Binary file not shown.
Binary file added audio/moenchseestrasse-82.mp3
Binary file not shown.
Binary file added audio/oststrasse-42.mp3
Binary file not shown.
Binary file added audio/paulinenstrasse-31.mp3
Binary file not shown.
Binary file added audio/pestalozzistrasse-31.mp3
Binary file not shown.
Binary file added audio/schaefergasse-15.mp3
Binary file not shown.
Binary file added audio/schillerstrasse-18.mp3
Binary file not shown.
Binary file added audio/schillerstrasse-48.mp3
Binary file not shown.
Binary file added audio/sichererstrasse-22.mp3
Binary file not shown.
Binary file added audio/sichererstrasse-9.mp3
Binary file not shown.
Binary file added audio/sontheim-deinenbachstrasse-5.mp3
Binary file not shown.
Binary file added audio/sontheim-hauptstrasse-25.mp3
Binary file not shown.
Binary file added audio/sontheim-parkstrasse-33.mp3
Binary file not shown.
Binary file added audio/waldweg-koepfertal.mp3
Binary file not shown.
Binary file added audio/weststrasse-45.mp3
Binary file not shown.
Binary file added audio/wollhausstrasse-40.mp3
Binary file not shown.
21 changes: 21 additions & 0 deletions scripts/scrape-audios.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/usr/bin/nodejs
var exec = require('child_process').exec;

exec('jekyll build ..', function (error, stdout, stderr) {
console.log(stdout);
require('fs').readFile('../_site/stolpersteine.json', function (err, data) {
if (err) {
console.log('OH NO');
throw err;
} else {
data;
json = JSON.parse(data);
json.forEach(function(item, index){
if(item.audio){
console.log(item.audio);
exec('wget ' + item.audio + ' -P ../audio/');
}
});
}
});
});
23 changes: 23 additions & 0 deletions scripts/scrape-images.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
#!/usr/bin/nodejs
var exec = require('child_process').exec;

exec('jekyll build ..', function (error, stdout, stderr) {
console.log(stdout);
require('fs').readFile('../_site/stolpersteine.json', function (err, data) {
if (err) {
console.log('OH NO');
throw err;
} else {
data;
json = JSON.parse(data);
json.forEach(function(item, index){
if(item.images){
item.images.forEach(function(url, i){
console.log(url);
exec('wget ' + url + ' -P ../_uploads/');
})
}
});
}
});
});

0 comments on commit c394f0e

Please sign in to comment.