summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorelijah <elijah@riseup.net>2013-12-31 23:22:31 -0800
committerelijah <elijah@riseup.net>2013-12-31 23:22:31 -0800
commit020b3a8d972005207129a6af7a2c519fb0981820 (patch)
treeb1e2807d7d8c1e1f204ba84d3e85ea996109fedd /README.md
initial commit
Diffstat (limited to 'README.md')
-rw-r--r--README.md130
1 files changed, 130 insertions, 0 deletions
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..21596eb
--- /dev/null
+++ b/README.md
@@ -0,0 +1,130 @@
+Bitmask downloads
+-----------------------------------------
+
+This is the Bitmask download website (https://dl.bitmask.net)
+
+It is entirely static, but relies on a bunch of apache tricks for things like language negotiation, server side includes, and pretty directory indexes.
+
+Requirements
+-----------------------------------------
+
+The following apache mods are required:
+
+ sudo a2enmod include rewrite autoindex mime negotiation
+
+The following apache directives are required, on the document root:
+
+ ##
+ ## PERMISSIONS
+ ##
+
+ AllowOverride None
+ Order deny,allow
+ Allow from all
+
+ ##
+ ## LOCALE SUPPORT (e.g. index.en.html)
+ ##
+
+ LanguagePriority en
+ ForceLanguagePriority Prefer Fallback
+ DirectoryIndex index
+ Options +MultiViews
+
+ ##
+ ## SERVER SIDE INCLUDES
+ ##
+
+ AddType text/html .shtml
+ AddOutputFilter INCLUDES .shtml
+ Options +Includes
+
+ ##
+ ## REWRITES
+ ##
+
+ Options +FollowSymLinks
+ RewriteEngine on
+ LogLevel alert rewrite:trace4
+
+ #
+ # Allow /:locale/ prefix path if the document exists
+ # e.g. /de/blah/ ==> /blah/index.de.shtml
+ #
+
+ RewriteCond %{DOCUMENT_ROOT}/$2/index.$1.shtml -f
+ RewriteRule ^([a-z]{2})/(.*) /$2/index.$1.shtml [L]
+
+ RewriteCond %{DOCUMENT_ROOT}/index.$1.shtml -f
+ RewriteRule ^([a-z]{2})$ /index.$1.shtml [L]
+
+ #
+ # Fall back to english if the document doesn't exist
+ # e.g. /xx/blah ==> /blah/index.en.shtml
+ #
+
+ RewriteCond %{DOCUMENT_ROOT}/$2/index.$1.shtml !-f
+ RewriteRule ^([a-z]{2})/(.*) /$2/index.en.shtml [L]
+
+ RewriteCond %{DOCUMENT_ROOT}/index.$1.shtml !-f
+ RewriteRule ^([a-z]{2})$ /index.en.shtml [L]
+
+ ##
+ ## Index Directories
+ ##
+
+ Options +Indexes
+ IndexOptions +FancyIndexing +Charset=UTF-8
+ IndexOptions +SuppressRules +SuppressDescription +NameWidth=*
+ IndexOptions +FoldersFirst +VersionSort +HTMLTable
+ #IndexOptions +SuppressHTMLPreamble +HTMLTable
+ #IndexOptions +SuppressHTMLPreamble +HTMLTable
+ IndexIgnore .htaccess /assets header.html footer.html
+ HeaderName /assets/header.html
+ ReadmeName /assets/footer.html
+
+ AddIcon /assets/icons/blank.png ^^BLANKICON^^
+ AddIcon /assets/icons/folder.png ^^DIRECTORY^^
+ AddIcon /assets/icons/folder-home.png ..
+ AddIcon /assets/icons/audio.png .aif .iff .m3u .m4a .mid .mp3 .mpa .ra .wav .wma .f4a .f4b .oga .ogg
+ AddIcon /assets/icons/bin.png .bin
+ AddIcon /assets/icons/c.png .c
+ AddIcon /assets/icons/calc.png .xlsx .xlsm .xltx .xltm .xlam .xlr .xls .csv
+ AddIcon /assets/icons/css.png .css
+ AddIcon /assets/icons/deb.png .deb
+ AddIcon /assets/icons/doc.png .doc .docx .docm .dot .dotx .dotm .log .msg .odt .pages .rtf .tex .wpd .wps
+ AddIcon /assets/icons/draw.png .svg
+ AddIcon /assets/icons/eps.png .ai .eps
+ AddIcon /assets/icons/gif.png .gif
+ AddIcon /assets/icons/html.png .html .xhtml .shtml .htm
+ AddIcon /assets/icons/ico.png .ico
+ AddIcon /assets/icons/java.png .jar
+ AddIcon /assets/icons/jpg.png .jpg .jpeg
+ AddIcon /assets/icons/js.png .js .json
+ AddIcon /assets/icons/markdown.png .md
+ AddIcon /assets/icons/package.png .pkg .dmg
+ AddIcon /assets/icons/pdf.png .pdf
+ AddIcon /assets/icons/php.png .php .phtml
+ AddIcon /assets/icons/png.png .png
+ AddIcon /assets/icons/ps.png .ps
+ AddIcon /assets/icons/psd.png .psd
+ AddIcon /assets/icons/rar.png .rar
+ AddIcon /assets/icons/rb.png .rb
+ AddIcon /assets/icons/rpm.png .rpm
+ AddIcon /assets/icons/rss.png .rss
+ AddIcon /assets/icons/sql.png .sql
+ AddIcon /assets/icons/tiff.png .tiff
+ AddIcon /assets/icons/text.png .txt .nfo
+ AddIcon /assets/icons/video.png .asf .asx .avi .flv .mkv .mov .mp4 .mpg .rm .srt .swf .vob .wmv .m4v .f4v .f4p .ogv
+ AddIcon /assets/icons/xml.png .xml
+ AddIcon /assets/icons/zip.png .zip
+ DefaultIcon /assets/icons/default.png
+
+Credits
+-----------------------------------------
+
+Stylesheet is adapted from Apaxy, in the public domain.
+https://github.com/AdamWhitcroft/Apaxy
+
+Icons are from "Faenza Icons" Licensed under the GPL.
+http://tiheum.deviantart.com/art/Faenza-Icons-173323228