- JavaScript 57.5%
- CSS 17.1%
- HTML 10.7%
- Less 9.6%
- TypeScript 2.9%
- Other 2.2%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
|
|
||
| apache | ||
| buildout | ||
| deploy | ||
| swissguesser | ||
| test | ||
| util | ||
| .editorconfig | ||
| .gitattributes | ||
| .gitignore | ||
| .jshintrc | ||
| bootstrap.py | ||
| buildout.cfg | ||
| buildout_dev.cfg | ||
| CHANGES.txt | ||
| package.json | ||
| README.md | ||
| setup.py | ||
| storymap5.cfg | ||
| storymap8.cfg | ||
| storymap9.cfg | ||
| storymap10.cfg | ||
SwissGuesser
Swissguesser multi-projects. This is a subset of storymaps. For a description of all Storymaps available, see https://github.com/geoadmin/web-storymaps/blob/master/README.md
1/ Install and deploy
If you do not update the data, you may simply clone the project from the repository, copy the images file (see subproject specific below) and deploy it:
cd /var/www/vhosts/mf-swissguesser/private
git clone git@github.com:geoadmin/mf-swissguesser.git swissguesser
cd swissguesser
python bootstrap.py --version 1.5.2 --distribute --download-base http://pypi.camptocamp.net/distribute-0.6.22_fix-issue-227/ --setup-source http://pypi.camptocamp.net/distribute-0.6.22_fix-issue-227/distribute_setup.py
buildout/bin/buildout install template
cat "Include /var/www/mf-swissguesser/private/swissguesser/apache/*.conf" > /var/www/mf-swissguesser/conf/99-swissguesser.conf
sudo apache2ctl graceful
sudo -u deploy deploy -r deploy/deploy.cfg int # or prod
2/ Updating data
To update a project, you need to install the buildout environment, update the configuration file MetadatenAufnahme.csv and translation file translation.csv, and
generate the new project JSON files
cd /var/www/vhosts/mf-swissguesser/private
git clone git@github.com:geoadmin/mf-swissguesser.git swissguesser
python bootstrap.py --version 1.5.2 --distribute --download-base http://pypi.camptocamp.net/distribute-0.6.22_fix-issue-227/ --setup-source http://pypi.camptocamp.net/distribute-0.6.22_fix-issue-227/distribute_setup.py
buildout/bin/buildout -c <project buildout>.cfg
sudo apache2ctl graceful
Subproject specific
Each subproject has two main .csv configurations files, which are used to generate the JSON files used by the application:
MetadatenAufnahme.csv, the list of images to displaytranslation.csv, obviously for internationalization of the user interface
These two files are used to generate the base.jsonfor the former, and the files in the localedirectory for the latter.
The buildout commands are, respectively with buildout install convert-csvand buildout install translate-csv.
In MetadatenAufnahme.csv, the four Legend columns may contain plain text, html entities or link to an external file. Using the convert-csv
buildout part, if you provide a downloadUrlon as an argument, the images will be linked instead of beeing downloaded.
Storymap5 (BAR)
The original one! This GeoAdmin Story Map is an interactive game to guess historical locations from the Swiss National Archive on a Swisstopo map of Switzerland.
http://storymaps.geo.admin.ch/storymaps/storymap5
-
The
MetadatenAufnahmeis derived from this [doc] (https://docs.google.com/spreadsheet/ccc?key=0Alq30s3mf7gPdDZPbWlVaFA0SmVoaWFCZ3hTbGtyaWc&usp=drive_web#gid=0) -
Images have to be copied to the
images\photosdirectory -
Generate the project with:
./buildout/bin/buildout -c storymap5.cfg install convert-csv ./buildout/bin/buildout -c storymap5.cfg install translation-csv ./buildout/bin/buildout -c storymap5.cfg install templify -
Commit your changes
Storymap8 (BAK)
Switzerland is the cable car country par excellence.
http://storymaps.geo.admin.ch/storymaps/storymap8
-
Use plain
MetadatenAufnahmei.csvandtranslation.csv -
Images have to be copied to the
images\photosdirectory (original source ?) -
Generate the project with:
./buildout/bin/buildout -c storymap8.cfg install convert-csv ./buildout/bin/buildout -c storymap8.cfg install translation-csv ./buildout/bin/buildout -c storymap8.cfg install templify -
Commit your changes
Storymap9 (KGS)
Protection of cultural property inventory
http://storymaps.geo.admin.ch/storymaps/storymap9
-
Images are linked to the dav0 server
-
Explanations text and the copyright information are scraped from map.geo.admin.ch htmlPopup and the
meta.txtfile using theutil\kgs_scraper.pyscript -
The
MetadatenAufnahme.csvhas to be generated from theMetadatenAufnahme.csv.templateusing theutil\kgs_scraper.pyscript -
Generate the project with:
./buildout/bin/python util/kgs_scrapping.py swissguesser/static/storymap9/data/MetadatenAufnahmen.csv.template ./buildout/bin/buildout -c storymap9.cfg install convert-csv ./buildout/bin/buildout -c storymap9.cfg install translation-csv ./buildout/bin/buildout -c storymap9.cfg install templify -
Commit your changes
Storymap10 (LUBIS)
Historic aerial view
http://storymaps.geo.admin.ch/storymaps/storymap10
-
Images have to be copied to
static\storymap10\data\photos -
Explanations are linked to map.geo.admin.ch popup
-
The
MetadatenAufnahme.csvhas to be generated from theMetadatenAufnahme.csv.templateusing theutil\lubis_scraper.pyscript -
Generate the project with:
./buildout/bin/python util/lubis_scrapper.py swissguesser/static/storymap10/data/MetadatenAufnahmen.csv.template ./buildout/bin/buildout -c storymap10.cfg install convert-csv ./buildout/bin/buildout -c storymap10.cfg install translation-csv ./buildout/bin/buildout -c storymap10.cfg install templify -
Commit your changes