mirror of
https://github.com/welpo/tabi.git
synced 2025-11-23 02:00:25 +01:00
✨ feat(micro): add microblogging section to homepage
- Add micro section display on homepage with RSS feed - Support configurable section name via micro_section_name - Add toggle via show_micro config option - Create templates/partials/main_page_micro_list.html - Add sass/parts/_micro.scss for styling - Include RSS icon next to section heading Closes #1
This commit is contained in:
parent
393c5a8cb9
commit
06c55da7b7
11 changed files with 256 additions and 0 deletions
29
scripts/new-micro.sh
Executable file
29
scripts/new-micro.sh
Executable file
|
|
@ -0,0 +1,29 @@
|
|||
#!/usr/bin/env bash
|
||||
# Quick micro post generator - eliminates title/date friction
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
# Get current timestamp
|
||||
NOW=$(date +"%Y-%m-%dT%H:%M:%S%:z")
|
||||
FILENAME=$(date +"%Y-%m-%d-%H%M")
|
||||
TITLE=$(date +"%Y-%m-%d %H:%M")
|
||||
|
||||
# Get content from stdin or prompt
|
||||
if [ -t 0 ]; then
|
||||
echo "Enter micro post content (Ctrl+D when done):"
|
||||
CONTENT=$(cat)
|
||||
else
|
||||
CONTENT=$(cat)
|
||||
fi
|
||||
|
||||
# Create post
|
||||
cat > "content/micro/${FILENAME}.md" <<EOF
|
||||
+++
|
||||
title = "${TITLE}"
|
||||
date = ${NOW}
|
||||
+++
|
||||
|
||||
${CONTENT}
|
||||
EOF
|
||||
|
||||
echo "Created: content/micro/${FILENAME}.md"
|
||||
Loading…
Add table
Add a link
Reference in a new issue