Mais alpine
This commit is contained in:
parent
5f6dbefe77
commit
eb775c0f9b
@ -4,10 +4,9 @@ mkdir -p content/archd
|
|||||||
mkdir -p content/archm
|
mkdir -p content/archm
|
||||||
mkdir -p content/archy
|
mkdir -p content/archy
|
||||||
|
|
||||||
ack -hm 1 "^date:" content/artigos | sed -e 's/^date: \(....\)-..-.. ..:..:../\1/' | sort -u |
|
grep -Rhm 1 ^date: content/artigos | sed -e 's/^date: \(....\)-..-.. ..:..:../\1/' | sort -u |
|
||||||
while read archy; do echo -e "---\ndate: $archy-01-01 00:00:00\n---" > content/archy/$archy.md; done
|
while read archy; do echo -e "---\ndate: $archy-01-01 00:00:00\n---" > content/archy/$archy.md; done
|
||||||
ack -hm 1 "^date:" content/artigos | sed -e 's/^date: \(....-..\)-.. ..:..:../\1/' | sort -u |
|
grep -Rhm 1 ^date: content/artigos | sed -e 's/^date: \(....-..\)-.. ..:..:../\1/' | sort -u |
|
||||||
while read archm; do echo -e "---\ndate: $archm-01 00:00:00\n---" > content/archm/$archm.md; done
|
while read archm; do echo -e "---\ndate: $archm-01 00:00:00\n---" > content/archm/$archm.md; done
|
||||||
ack -hm 1 "^date:" content/artigos | sed -e 's/^date: \(....-..-..\) ..:..:../\1/' | sort -u |
|
grep -Rhm 1 ^date: content/artigos | sed -e 's/^date: \(....-..-..\) ..:..:../\1/' | sort -u |
|
||||||
while read archd; do echo -e "---\ndate: $archd 00:00:00\n---" > content/archd/$archd.md; done
|
while read archd; do echo -e "---\ndate: $archd 00:00:00\n---" > content/archd/$archd.md; done
|
||||||
|
|
||||||
|
@ -9,7 +9,9 @@ frontmatter_handling = "Parse"
|
|||||||
files = [
|
files = [
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
find content/artigos -name "*.md" -printf "%P\n" | while read filename; do
|
find content/artigos -name "*.md" |
|
||||||
|
sed -e 's|content/artigos/||' |
|
||||||
|
while read filename; do
|
||||||
slug="$(echo "$filename" | sed -e 's|/index.md||')"
|
slug="$(echo "$filename" | sed -e 's|/index.md||')"
|
||||||
date="$(cat "content/artigos/$filename" | yq --front-matter=extract .date | sed -e 's/ ..:..:..//' -e 's/-/\//g')"
|
date="$(cat "content/artigos/$filename" | yq --front-matter=extract .date | sed -e 's/ ..:..:..//' -e 's/-/\//g')"
|
||||||
echo " {url=\"$date/$slug\", title=\"\", path=\"$filename\"},"
|
echo " {url=\"$date/$slug\", title=\"\", path=\"$filename\"},"
|
||||||
|
Loading…
Reference in New Issue
Block a user