Skip to content
This repository has been archived by the owner on Jul 31, 2023. It is now read-only.

Commit

Permalink
- Moving data files to data folder
Browse files Browse the repository at this point in the history
- Extracting ISO-3166-2 data for GB and US and include them as data files
- Refactoring `regions.py` to handle sub-regions (currently only US states and few sub-regions of GB)
- Refactoring `regions-wp.py` to handle sub-regions
- General linting and cleanup
- Changing the shebang lines to use `env`
  • Loading branch information
Shervin committed Jun 2, 2015
1 parent a2ecdc3 commit 265bc69
Show file tree
Hide file tree
Showing 9 changed files with 137 additions and 46,927 deletions.
11 changes: 0 additions & 11 deletions ALIASES

This file was deleted.

37 changes: 0 additions & 37 deletions ALIASES-WP

This file was deleted.

13 changes: 7 additions & 6 deletions download-wp.sh
@@ -1,6 +1,7 @@
#!/bin/sh
IFS=' '
./regions-wp.py |
#!/usr/bin/env sh

IFS=' '
python3 ./regions-wp.py |
while read region htmlurl ; do

html="html/$region.html"
Expand All @@ -12,12 +13,12 @@ while read region htmlurl ; do

echo "Downloading: $region $htmlurl"

if ! wget -q -O "$html" "$htmlurl"; then
echo "ERROR: failed downloading html: $htmlurl"
if ! wget -q -O "$html" "${htmlurl}"; then
echo "ERROR: failed downloading html: ${htmlurl}"
continue
fi

if ! grep -q public_domain "$html"; then
if ! grep -q -E "public_domain|Category:PD[-_]" "$html"; then
echo "WARNING: flag NOT in public domain; check license"
fi

Expand Down
6 changes: 0 additions & 6 deletions language-subtag-private

This file was deleted.

0 comments on commit 265bc69

Please sign in to comment.