From 2682707d0c2cc9a7ebdb835bb936aedffba4eb6e Mon Sep 17 00:00:00 2001 From: Djamil Legato Date: Sat, 2 Aug 2014 13:29:05 -0700 Subject: [PATCH] Added missing configs, gitignore and data folder --- .editorconfig | 13 +++++++++++++ .gitignore | 22 ++++++++++++++++++++++ .htaccess | 29 +++++++++++++++++++++++++++++ user/data/index.html | 0 4 files changed, 64 insertions(+) create mode 100644 .editorconfig create mode 100755 .gitignore create mode 100755 .htaccess create mode 100644 user/data/index.html diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 000000000..808ae5806 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,13 @@ +# EditorConfig is awesome: http://EditorConfig.org + +# top-most EditorConfig file +root = true + +# Unix-style newlines with a newline ending every file +[*] +charset = utf-8 +end_of_line = lf +trim_trailing_whitespace = true +insert_final_newline = true +indent_style = space +indent_size = 4 diff --git a/.gitignore b/.gitignore new file mode 100755 index 000000000..f3ab92837 --- /dev/null +++ b/.gitignore @@ -0,0 +1,22 @@ +# Composer +composer.lock + +# Sass +.sass-cache + +# OS Generated +.DS_Store* +ehthumbs.db +Icon? +Thumbs.db +*.swp + +# Grav Specific +/cache +/logs +/images +/user/data/* +!/user/data/index.html + +# phpstorm +.idea/* diff --git a/.htaccess b/.htaccess new file mode 100755 index 000000000..268afb8e9 --- /dev/null +++ b/.htaccess @@ -0,0 +1,29 @@ + +RewriteEngine On + +# access site +RewriteCond %{REQUEST_FILENAME} !-f +RewriteCond %{REQUEST_FILENAME} !-d +RewriteRule . index.php [L] + +# block various user files from being accessed directly +RewriteRule ^user/accounts/(.*)$ error [R=301,L] +RewriteRule ^user/config/(.*)$ error [R=301,L] +RewriteRule ^user/(.*)\.(txt|md|html|php|yaml|json|twig|sh|bat)$ error [R=301,L] + +# block cache +RewriteRule ^cache/(.*) error [R=301,L] + +# block bin +RewriteRule ^bin/(.*)$ error [R=301,L] + +# block system +RewriteRule ^system/(.*)$ error [R=301,L] + +# block vendor +RewriteRule ^vendor/(.*)$ error [R=301,L] + + + +# Prevent file browsing +Options -Indexes diff --git a/user/data/index.html b/user/data/index.html new file mode 100644 index 000000000..e69de29bb