diff options
Diffstat (limited to 'bin/datafiles-htaccess-links.sh')
-rwxr-xr-x | bin/datafiles-htaccess-links.sh | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/bin/datafiles-htaccess-links.sh b/bin/datafiles-htaccess-links.sh new file mode 100755 index 0000000..2c9793e --- /dev/null +++ b/bin/datafiles-htaccess-links.sh @@ -0,0 +1,13 @@ +#!/bin/bash +DATE=$1 + +shift 1 +LINKS=$@ + +echo $LINKS | while read LINK +do + SOURCE_PREFIX="${LINK//.html/}" + echo "RewriteRule $SOURCE_PREFIX.json _data/$DATE.json [L]" + echo "RewriteRule $SOURCE_PREFIX.minimal.json _data/$DATE.minimal.json [L]" + echo "RewriteRule $SOURCE_PREFIX.csv https://raw.githubusercontent.com/emkael/pzbs-ranking/master/data/rankings/$DATE.csv [R,L]" +done |