diff options
| author | Paul Buetow <git@mx.buetow.org> | 2021-05-17 21:19:35 +0100 |
|---|---|---|
| committer | Paul Buetow <git@mx.buetow.org> | 2021-05-17 21:19:35 +0100 |
| commit | 944b6b1e820542406ccc3fc19808c624a033c608 (patch) | |
| tree | 81c3381a53456ee3922984714425ffdff87d1c1a /packages/atomfeed.source.sh | |
| parent | c7696200b0c5235eb024b912c4185be4cabec1b0 (diff) | |
refactor
Diffstat (limited to 'packages/atomfeed.source.sh')
| -rw-r--r-- | packages/atomfeed.source.sh | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/packages/atomfeed.source.sh b/packages/atomfeed.source.sh index feb074a8..3a3e1e73 100644 --- a/packages/atomfeed.source.sh +++ b/packages/atomfeed.source.sh @@ -1,3 +1,4 @@ +# Retrieves meta data of a given blog post. Generate new meta info if not yet exists. atomfeed::meta () { local -r gmi_file_path="$1"; shift local -r meta_file=$($SED 's|gemtext|meta|; s|.gmi$|.meta|;' <<< "$gmi_file_path") @@ -36,6 +37,7 @@ META test $is_draft == yes && rm "$meta_file" } +# Retrieves the core content as XHTML of the blog post, to include to the feed. atomfeed::content () { local -r gmi_file_path="$1"; shift log VERBOSE "Retrieving feed content from $gmi_file_path" @@ -50,6 +52,7 @@ atomfeed::content () { " } +# Generate an atom.xml feed file. atomfeed::generate () { local -r gemfeed_dir="$CONTENT_DIR/gemtext/gemfeed" local -r atom_file="$gemfeed_dir/atom.xml" |
