add decap cms
Some checks are pending
/ test (push) Waiting to run

This commit is contained in:
gribse 2025-04-24 22:19:51 +02:00
parent 7cce73e2ba
commit e8025733bc
4 changed files with 534 additions and 1 deletions

29
static/admin/config.yml Normal file
View file

@ -0,0 +1,29 @@
backend:
name: gitea
repo: gribse/blog # Path to your Gitea repository
app_id: 39e3a9e2-1bd0-41be-bc4c-7c7f7023b51b # The Client ID provided by Gitea
api_root: https://git.achilletoupin.com/api/v1 # API URL of your Gitea instance
base_url: https://git.achilletoupin.com/ # Root URL of your Gitea instance
auth_endpoint: https://git.achilletoupin.com/login/oauth/authorize
# optional, defaults to master
branch: main
local_backend: true # allows local editing via npx decap-cms-proxy-server
media_folder: "static/images/uploads" # path in repo
public_folder: "/images/uploads" # URL path
collections:
- name: "posts"
label: "Posts"
folder: "content/posts"
create: true
slug: "{{slug}}"
extension: "md" # Hugo expects Markdown
format: "frontmatter"
fields:
- { label: "Title", name: "title", widget: "string" }
- { label: "Date", name: "date", widget: "datetime" }
- { label: "Draft", name: "draft", widget: "boolean", default: true }
- { label: "Tags", name: "tags", widget: "list", default: [] }
- { label: "Body", name: "body", widget: "markdown" }