aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2013-11-02 12:53:16 +0100
committerLoïc Hoguin <[email protected]>2013-11-02 12:53:16 +0100
commitf5f9f65abbce7625338e721d8fdf6c6c75cb0d75 (patch)
treee962ef76d893bd2df890f2b8ff039081b7b2a4eb /Makefile
parent1797b412baa694e489b18732408e146f7c09f59d (diff)
downloadcowlib-f5f9f65abbce7625338e721d8fdf6c6c75cb0d75.tar.gz
cowlib-f5f9f65abbce7625338e721d8fdf6c6c75cb0d75.tar.bz2
cowlib-f5f9f65abbce7625338e721d8fdf6c6c75cb0d75.zip
Improve mimetypes code based on cowboy_static usage
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 4 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index d731acf..3074904 100644
--- a/Makefile
+++ b/Makefile
@@ -15,8 +15,10 @@ gen:
> $(GEN_OUT)
$(gen_verbose) wget -qO - $(GEN_URL) \
| grep -v ^# \
- | awk '{for (i=2; i<=NF; i++) if ($$i != "") \
- print "all_ext(<<\"" $$i "\">>) -> <<\"" $$1 "\">>;"}' \
+ | awk '{for (i=2; i<=NF; i++) if ($$i != "") { \
+ split($$1, a, "/"); \
+ print "all_ext(<<\"" $$i "\">>) -> {<<\"" \
+ a[1] "\">>, <<\"" a[2] "\">>, []};"}}' \
| sort \
| uniq -w 25 \
>> $(GEN_OUT)