#3: Done; recipe for adding map pins for flags.

This commit is contained in:
Simon Brooke 2020-02-27 14:01:11 +00:00
parent eb354fdcda
commit e0b2a45a96
No known key found for this signature in database
GPG key ID: A7A4F18D1D4DF987
4 changed files with 25 additions and 1 deletions

2
.gitignore vendored
View file

@ -23,6 +23,6 @@ resources/docs/orig.md
resources/public/img/map-pins/colours/*.svg
resources/public/img/map-pins/colours/*.png
resources/public/img/map-pins/flags/*.png
.rebel_readline_history

View file

@ -4,6 +4,16 @@ A wee tool to show comma-separated value data on a map.
[![Clojars Project](https://img.shields.io/clojars/v/geocsv.svg)](https://clojars.org/geocsv)
## Other variants
This is a little project I've played about with, and there are now three variants:
1. [geocsv](https://github.com/simon-brooke/geocsv) is a fairly heavyweight web-app with both client-side and serverside components. It was the first version, and is the only version which meets the original requirement of being able to present data from [Google Sheets](https://www.google.co.uk/sheets/about/), but it's a remarkably heavyweight solution to what should be a simple problem.
2. [geocsv-lite](https://github.com/simon-brooke/geocsv-lite) is a much lighter, client-side only reworking of the problem, in ClojureScript. I still wasn't satisfied that this was light enough.
3. [geocsv-js](https://github.com/simon-brooke/geocsv-js) is a reworking in native JavaScript without any frameworks or heave libraries, except Leaflet. It is vastly lighter, and probably the one to use in most applications.
## Overview
The CSV file must have
* column names in the first row;

Binary file not shown.

View file

@ -0,0 +1,14 @@
#!/bin/bash
# Assumes presence of ImageMajick
unzip -u flags-mini.zip
base=../basic_map_pin.png
for flag in *.png
do
cc="$(tr '[:lower:]' '[:upper:]' <<< ${flag:0:1})${flag:1:1}"
composite -compose atop -geometry +0+5 $flag $base ../${cc}-pin.png
rm $flag
done