From e106ee4c4c2f9da75b76de36c218b893d87b0619 Mon Sep 17 00:00:00 2001 From: Stephan Ploehn Date: Fri, 22 Aug 2025 10:18:22 +0200 Subject: [PATCH] feat: initial commit --- .editorconfig | 21 ++++++++++ .gitignore | 51 +++++++++++++++++++++++ .htaccess | 67 +++++++++++++++++++++++++++++++ README.md | 36 +++++++++++++++++ composer.json | 43 ++++++++++++++++++++ content/error/error.txt | 1 + content/home/home.txt | 1 + content/site.txt | 1 + public/index.php | 23 +++++++++++ public/media/index.html | 0 site/blueprints/pages/default.yml | 21 ++++++++++ site/blueprints/site.yml | 5 +++ site/snippets/index.html | 0 site/templates/default.php | 1 + storage/accounts/index.html | 0 storage/cache/index.html | 0 storage/sessions/index.html | 0 17 files changed, 271 insertions(+) create mode 100644 .editorconfig create mode 100644 .gitignore create mode 100644 .htaccess create mode 100644 README.md create mode 100644 composer.json create mode 100644 content/error/error.txt create mode 100644 content/home/home.txt create mode 100644 content/site.txt create mode 100644 public/index.php create mode 100644 public/media/index.html create mode 100644 site/blueprints/pages/default.yml create mode 100644 site/blueprints/site.yml create mode 100644 site/snippets/index.html create mode 100644 site/templates/default.php create mode 100644 storage/accounts/index.html create mode 100644 storage/cache/index.html create mode 100644 storage/sessions/index.html diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 0000000..31cb096 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,21 @@ +[*.{css,scss,less,js,json,ts,sass,html,hbs,mustache,phtml,html.twig,md,yml}] +charset = utf-8 +indent_style = space +indent_size = 2 +end_of_line = lf +insert_final_newline = true +trim_trailing_whitespace = true + +[*.md] +indent_size = 4 +trim_trailing_whitespace = false + +[site/templates/**.php] +indent_size = 2 + +[site/snippets/**.php] +indent_size = 2 + +[package.json,.{babelrc,editorconfig,eslintrc,lintstagedrc,stylelintrc}] +indent_style = space +indent_size = 2 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..6e5293c --- /dev/null +++ b/.gitignore @@ -0,0 +1,51 @@ +# System files +# ------------ + +Icon +.DS_Store + +# Temporary files +# --------------- + +/public/media/* +!/public/media/index.html + +# Lock files +# --------------- + +.lock + +# Editors +# (sensitive workspace files) +# --------------------------- +*.sublime-workspace +/.vscode +/.idea + +# -------------SECURITY------------- +# NEVER publish these files via Git! +# -------------SECURITY------------- + +# Cache Files +# --------------- + +/storage/cache/* +!/storage/cache/index.html + +# Accounts +# --------------- + +/storage/accounts/* +!/storage/accounts/index.html + +# Sessions +# --------------- + +/storage/sessions/* +!/storage/sessions/index.html + +# License +# --------------- + +/site/config/.license + diff --git a/.htaccess b/.htaccess new file mode 100644 index 0000000..5fe5c71 --- /dev/null +++ b/.htaccess @@ -0,0 +1,67 @@ +# Kirby .htaccess +# revision 2023-07-22 + +# rewrite rules + + +# enable awesome urls. i.e.: +# http://yourdomain.com/about-us/team +RewriteEngine on + +# make sure to set the RewriteBase correctly +# if you are running the site in a subfolder; +# otherwise links or the entire site will break. +# +# If your homepage is http://yourdomain.com/mysite, +# set the RewriteBase to: +# +# RewriteBase /mysite + +# In some environments it's necessary to +# set the RewriteBase to: +# +# RewriteBase / + +# block files and folders beginning with a dot, such as .git +# except for the .well-known folder, which is used for Let's Encrypt and security.txt +RewriteRule (^|/)\.(?!well-known\/) index.php [L] + +# block all files in the content folder from being accessed directly +RewriteRule ^content/(.*) index.php [L] + +# block all files in the site folder from being accessed directly +RewriteRule ^site/(.*) index.php [L] + +# block direct access to Kirby and the Panel sources +RewriteRule ^kirby/(.*) index.php [L] + +# make site links work +RewriteCond %{REQUEST_FILENAME} !-f +RewriteCond %{REQUEST_FILENAME} !-d +RewriteRule ^(.*) index.php [L] + + + +# pass the Authorization header to PHP +SetEnvIf Authorization "(.+)" HTTP_AUTHORIZATION=$1 + +# compress text file responses + +AddOutputFilterByType DEFLATE text/plain +AddOutputFilterByType DEFLATE text/html +AddOutputFilterByType DEFLATE text/css +AddOutputFilterByType DEFLATE text/javascript +AddOutputFilterByType DEFLATE application/json +AddOutputFilterByType DEFLATE application/javascript +AddOutputFilterByType DEFLATE application/x-javascript + + +# set security headers in all responses + + +# serve files as plain text if the actual content type is not known +# (hardens against attacks from malicious file uploads) +Header set Content-Type "text/plain" "expr=-z %{CONTENT_TYPE}" +Header set X-Content-Type-Options "nosniff" + + diff --git a/README.md b/README.md new file mode 100644 index 0000000..7772e95 --- /dev/null +++ b/README.md @@ -0,0 +1,36 @@ + + +**Kirby: the CMS that adapts to any project, loved by developers and editors alike.** +The Plainkit is a minimal Kirby setup with the basics you need to start a project from scratch. It is the ideal choice if you are already familiar with Kirby and want to start step-by-step. + +You can learn more about Kirby at [getkirby.com](https://getkirby.com). + +### Try Kirby for free + +You can try Kirby and the Plainkit on your local machine or on a test server as long as you need to make sure it is the right tool for your next project. … and when you’re convinced, [buy your license](https://getkirby.com/buy). + +### Get going + +Read our guide on [how to get started with Kirby](https://getkirby.com/docs/guide/quickstart). + +You can [download the latest version](https://github.com/getkirby/plainkit/archive/main.zip) of the Plainkit. +If you are familiar with Git, you can clone Kirby's Plainkit repository from Github. + + git clone https://github.com/getkirby/plainkit.git + +## What's Kirby? + +- **[getkirby.com](https://getkirby.com)** – Get to know the CMS. +- **[Try it](https://getkirby.com/try)** – Take a test ride with our online demo. Or download one of our kits to get started. +- **[Documentation](https://getkirby.com/docs/guide)** – Read the official guide, reference and cookbook recipes. +- **[Issues](https://github.com/getkirby/kirby/issues)** – Report bugs and other problems. +- **[Feedback](https://feedback.getkirby.com)** – You have an idea for Kirby? Share it. +- **[Forum](https://forum.getkirby.com)** – Whenever you get stuck, don't hesitate to reach out for questions and support. +- **[Discord](https://chat.getkirby.com)** – Hang out and meet the community. +- **[Mastodon](https://mastodon.social/@getkirby)** – Spread the word. +- **[Bluesky](https://bsky.app/profile/getkirby.com)** – Spread the word. + +--- + +© 2009 Bastian Allgeier +[getkirby.com](https://getkirby.com) · [License agreement](https://getkirby.com/license) diff --git a/composer.json b/composer.json new file mode 100644 index 0000000..92f95bb --- /dev/null +++ b/composer.json @@ -0,0 +1,43 @@ +{ + "name": "deichrakete/kirby-moin", + "description": "Kirby starterkit with a custom folder structure and Tailwind CSS", + "type": "project", + "keywords": [ + "kirby", + "cms", + "starterkit", + "tailwindcss + ], + "authors": [ + { + "name": "Bastian Allgeier", + "email": "bastian@getkirby.com", + "homepage": "https://getkirby.com" + } + ], + "homepage": "https://getkirby.com", + "support": { + "email": "support@getkirby.com", + "forum": "https://forum.getkirby.com", + "source": "https://github.com/getkirby/plainkit" + }, + "require": { + "php": "~8.1.0 || ~8.2.0 || ~8.3.0 || ~8.4.0", + "getkirby/cms": "^5.0" + }, + "config": { + "allow-plugins": { + "getkirby/composer-installer": true + }, + "optimize-autoloader": true + }, + "scripts": { + "start": [ + "Composer\\Config::disableProcessTimeout", + "@php -S localhost:8000 -t public/ vendor/getkirby/cms/router.php" + ] + }, + "extra": { + "kirby-cms-path": false + } +} diff --git a/content/error/error.txt b/content/error/error.txt new file mode 100644 index 0000000..b588b2a --- /dev/null +++ b/content/error/error.txt @@ -0,0 +1 @@ +Title: Error \ No newline at end of file diff --git a/content/home/home.txt b/content/home/home.txt new file mode 100644 index 0000000..02896ec --- /dev/null +++ b/content/home/home.txt @@ -0,0 +1 @@ +Title: Home \ No newline at end of file diff --git a/content/site.txt b/content/site.txt new file mode 100644 index 0000000..b1f98d7 --- /dev/null +++ b/content/site.txt @@ -0,0 +1 @@ +Title: Site Title \ No newline at end of file diff --git a/public/index.php b/public/index.php new file mode 100644 index 0000000..897d1af --- /dev/null +++ b/public/index.php @@ -0,0 +1,23 @@ + [ + 'index' => __DIR__, + 'base' => $base = dirname(__DIR__), + 'content' => $base . '/content', + 'site' => $base . '/site', + 'storage' => $storage = $base . '/storage', + 'accounts' => $storage . '/accounts', + 'cache' => $storage . '/cache', + 'sessions' => $storage . '/sessions', + ] + ] +); + +echo $kirby->render(); + diff --git a/public/media/index.html b/public/media/index.html new file mode 100644 index 0000000..e69de29 diff --git a/site/blueprints/pages/default.yml b/site/blueprints/pages/default.yml new file mode 100644 index 0000000..0cb0129 --- /dev/null +++ b/site/blueprints/pages/default.yml @@ -0,0 +1,21 @@ +title: Default Page + +columns: + main: + width: 2/3 + sections: + fields: + type: fields + fields: + text: + type: textarea + size: huge + sidebar: + width: 1/3 + sections: + pages: + type: pages + template: default + files: + type: files + diff --git a/site/blueprints/site.yml b/site/blueprints/site.yml new file mode 100644 index 0000000..b7da661 --- /dev/null +++ b/site/blueprints/site.yml @@ -0,0 +1,5 @@ +title: Site + +sections: + pages: + type: pages diff --git a/site/snippets/index.html b/site/snippets/index.html new file mode 100644 index 0000000..e69de29 diff --git a/site/templates/default.php b/site/templates/default.php new file mode 100644 index 0000000..74e38ae --- /dev/null +++ b/site/templates/default.php @@ -0,0 +1 @@ +

title() ?>

diff --git a/storage/accounts/index.html b/storage/accounts/index.html new file mode 100644 index 0000000..e69de29 diff --git a/storage/cache/index.html b/storage/cache/index.html new file mode 100644 index 0000000..e69de29 diff --git a/storage/sessions/index.html b/storage/sessions/index.html new file mode 100644 index 0000000..e69de29