Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Small Jekyll YAML Metadata package #142

Merged
merged 2 commits into from
Dec 5, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions packages/jekyll-yaml/0.1.0/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
This package lets you add some yaml-metadata to a jekyll post.

Typing `:newpost` yields the following:

```
---
date: 2024-12-05
author: YourName
smeech marked this conversation as resolved.
Show resolved Hide resolved
tags:
category:
title:
---
```

Date is set to the current date and authorname can obviously be adjusted.

Please make sure to add tags like the following and remain consistent:
smeech marked this conversation as resolved.
Show resolved Hide resolved

```
...
tags:
- tag1
- tag2
...
``
6 changes: 6 additions & 0 deletions packages/jekyll-yaml/0.1.0/_manifest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name: "jekyll yaml metadata"
title: "Jekyll YAML metadata"
description: A simple package to add metadata to your jekyll posts before writing.
version: 0.1.0
author: mathis
tags: ["jekyll", "yaml"]
smeech marked this conversation as resolved.
Show resolved Hide resolved
12 changes: 12 additions & 0 deletions packages/jekyll-yaml/0.1.0/package.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
matches:
- trigger: ":newpost"
replace: "---\ndate: {{mydate}}\nauthor: {{autorname}}\ntags:\ncategory:\ntitle:\n---"
vars:
- name: autorname
type: echo
params:
echo: YourName
- name: mydate
type: date
params:
format: "%Y-%m-%d"
Loading