aboutsummaryrefslogtreecommitdiff
path: root/generate.sh
diff options
context:
space:
mode:
authorAkshay <[email protected]>2020-01-25 18:14:22 +0000
committerAkshay <[email protected]>2020-01-25 18:14:22 +0000
commit34766e3d54af6c9f44babb03feb84bd228e5127d (patch)
tree15f80227381795d5423b03e98768e78917201c13 /generate.sh
parent7a135bc91aaf941c8ab39d13662bd417f9cbce10 (diff)
add footer, visual separators
Diffstat (limited to 'generate.sh')
-rwxr-xr-xgenerate.sh19
1 files changed, 16 insertions, 3 deletions
diff --git a/generate.sh b/generate.sh
index a95fb06..34ae4cb 100755
--- a/generate.sh
+++ b/generate.sh
@@ -16,11 +16,15 @@ link_wrapper() {
16 <div class=\"post\"> 16 <div class=\"post\">
17 <div class=\"date\"> 17 <div class=\"date\">
18 $3 18 $3
19 <span class=\"commit-hash\">$4</span>
20 </div> 19 </div>
21 <a href=\"/posts/$1\" class=\"post-link\"> 20 <a href=\"/posts/$1\" class=\"post-link\">
22 <span class=\"post-link\">$2</span> 21 <span class=\"post-link\">$2</span>
23 </a> 22 </a>
23 <span class=\"commit-hash\">
24 <a href=\"https://github.com/nerdypepper/site/blob/master/posts/$1.md\" style=\"text-decoration: none\">
25 $4
26 </a>
27 </span>
24 </div> 28 </div>
25 " 29 "
26} 30}
@@ -52,6 +56,7 @@ echo "
52# begin posts 56# begin posts
53echo " 57echo "
54<div class=\"posts\"> 58<div class=\"posts\">
59<div class="separator"></div>
55" >> docs/index.html 60" >> docs/index.html
56 61
57# posts 62# posts
@@ -63,7 +68,6 @@ for f in $posts; do
63 echo "generating post $file" 68 echo "generating post $file"
64 id="${file##*/}" # ill name my posts just fine 69 id="${file##*/}" # ill name my posts just fine
65 70
66
67 # generate posts 71 # generate posts
68 html=$(lowdown "$file") 72 html=$(lowdown "$file")
69 commit="$(git log -n1 --oneline "$file" | sed -e 's/\s.*$//g')" 73 commit="$(git log -n1 --oneline "$file" | sed -e 's/\s.*$//g')"
@@ -83,10 +87,19 @@ for f in $posts; do
83 commit="$commit" \ 87 commit="$commit" \
84 title="$post_title" 88 title="$post_title"
85 89
86 first_visible="0"
87done 90done
88 91
89echo " 92echo "
93<div class="separator"></div>
94<div class="footer">
95 <a href="https://github.com/nerdypepper"> Github </a>
96 ·
97 <a href="https://twitter.com/N3rdyP3pp3r"> Twitter </a>
98 ·
99 <a href="mailto:[email protected]"> Mail </a>
100 ·
101 <a href="https://linkedin.com/in/nerdypepper"> LinkedIn </a>
102</div>
90</div> 103</div>
91</body> 104</body>
92</html> 105</html>