Gatsby With Orga

About Your Org Files

November 10, 2020
305 words
1 minutes

You can organize your posts in two ways: per file or per headline.

File Based Posts

You just simply create org files, give it a #+TITLE and a #+DATE. Add a #+SUMMARY if you want to. You have a post.

Headline Based Posts

Tell Orga which headlines should be published via in buffer setting #+ORGA_PUBLISH_KEYWORD. It could be an array (separated by spaces). Then the headlines with matching keyword will be consider posts. Check out an example org file (yes, it's this page).

Property Metadata Map

Ordered by priority.

metadata field headline based file based
title headline content #+TITLE
EXPORT_TITLE
date DATE #+DATE
EXPORT_DATE #+EXPORT_DATE
PUBLISH_DATE #+PUBLISH_DATE
"CLOSED" planning timestamp
category CATEGORY #+CATEGORY
file name
tags tags of headline N/A
export_file_name EXPORT_FILE_NAME #+EXPORT_FILE_NAME
headline content (sanitised) file name
excerpt EXCERPT EXCERPT
SUMMARY SUMMARY
DESCRIPTION DESCRIPTION
essential property mapping

All other properties will be available for graphql queries.

SELECT_TAGS and EXCLUDE_TAGS

org-mode has these useful properties that can help you select or ignore sections when exporting your content into html. You can do the same with orgajs. There's actually another section after this one in the current org file, but you won't be able to see it because it's ignored with due to tag noexport. Again check out this org file for an real life example.

option default value details
SELECT_TAGS [] when set (none-empty array), only sections with matching tags are included
EXCLUDE_TAGS ['noexport']

I try to stick as close to org-mode syntax as possible. So array is always string separated by spaces. You can customize these settings on a per file basis, just like in org-mode.

Read more stories about "getting-started" ->