diff options
author | Loïc Hoguin <[email protected]> | 2013-11-02 12:53:16 +0100 |
---|---|---|
committer | Loïc Hoguin <[email protected]> | 2013-11-02 12:53:16 +0100 |
commit | f5f9f65abbce7625338e721d8fdf6c6c75cb0d75 (patch) | |
tree | e962ef76d893bd2df890f2b8ff039081b7b2a4eb /Makefile | |
parent | 1797b412baa694e489b18732408e146f7c09f59d (diff) | |
download | cowlib-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-- | Makefile | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -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) |