Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/Cecilapp/Cecil
Browse files Browse the repository at this point in the history
  • Loading branch information
ArnaudLigny committed Nov 17, 2023
2 parents 639a308 + c4e588d commit 50a5d6e
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 22 deletions.
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"psr/log": "^1.1",
"psr/simple-cache": "^1.0",
"scrivo/highlight.php": "^9.18",
"scssphp/scssphp": "^1.11",
"scssphp/scssphp": "^1.12",
"spatie/image-optimizer": "^1.7",
"symfony/config": "^5.4",
"symfony/console": "^5.4",
Expand All @@ -63,7 +63,7 @@
},
"require-dev": {
"ergebnis/composer-normalize": "^2.28",
"friendsofphp/php-cs-fixer": "^3.35",
"friendsofphp/php-cs-fixer": "^3.38",
"humbug/box": "^3.16",
"phpmd/phpmd": "^2.14",
"phpstan/phpstan": "^1.10",
Expand Down
24 changes: 12 additions & 12 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

23 changes: 15 additions & 8 deletions docs/3-Templates.md
Original file line number Diff line number Diff line change
Expand Up @@ -1203,7 +1203,7 @@ If you want to use the `format_date` filter **with other locales than "en"**, yo
Cecil comes with a set of [built-in templates](https://github.com/Cecilapp/Cecil/tree/master/resources/layouts).

:::tips
If you need to modify the default templates, you can easily extract them via the following command: they will be copied in the "layouts" directory of your site.
If you need to modify built-in templates, you can easily extract them via the following command: they will be copied in the "layouts" directory of your site.

```bash
php cecil.phar util:extract
Expand All @@ -1213,23 +1213,33 @@ php cecil.phar util:extract

### Default templates

[`_default/404.html.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/_default/404.html.twig)
: A very simple error 404 ("Page not found") template.

[`_default/page.html.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/_default/page.html.twig)
: A simple default main template with a clean CSS.

[`_default/list.html.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/_default/list.html.twig)
: A pages list with (optional) pagination.

[`_default/list.atom.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/_default/list.atom.twig)
: An Atom feed.

[`_default/list.rss.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/_default/list.rss.twig)
: A RSS feed.

[`_default/vocabulary.html.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/_default/vocabulary.html.twig)
: A simple list of all terms of a vocabulary.

### Utility templates

[`sitemap.xml.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/sitemap.xml.twig)
[`_default/sitemap.xml.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/sitemap.xml.twig)
: The `sitemap.xml` template: list all pages sorted by date.

[`robots.txt.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/robots.txt.twig)
[`_default/robots.txt.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/robots.txt.twig)
: The `robots.txt` template: allow all pages except 404, with a reference to the XML sitemap.

[`_default/redirect.html.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/redirect.html.twig)
: The default redirect template.

### Partial templates

[`partials/navigation.html.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/partials/navigation.html.twig)
Expand All @@ -1244,9 +1254,6 @@ php cecil.phar util:extract
[`partials/languages.html.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/partials/languages.html.twig)
: Switcher between [languages](4-Configuration.md#languages).

[`partials/googleanalytics.js.twig`](https://github.com/Cecilapp/Cecil/blob/master/resources/layouts/partials/googleanalytics.js.twig)
: Google Analytics traking script. See [configuration](4-Configuration.md#googleanalytics).

## Custom extension

It is possible to use custom [functions](#functions) and [filters](#filters):
Expand Down

0 comments on commit 50a5d6e

Please sign in to comment.