git ssb

3+

ev / sdash



Commit 7430f885d9d92edaa6642db61b753dde7fc9bc13

add post types

Ev Bogue committed on 8/25/2016, 4:09:33 PM
Parent: 390c2437a4420fe4ccd76e44d7446303ec78dcf9

Files changed

index.jschanged
views/index.jadechanged
index.jsView
@@ -6,8 +6,10 @@
66 var moment = require('moment');
77
88 var me = '@8Qee0I/DwI5DHSCi3p5fsl6FyLGArrnDz3ox9qZr5Qc=.ed25519';
99
10 +var pin = '%yP7vCxyJOKXTHYIKZ+vANjfU2dDNwyJsYYJKAJTZO2Y=.sha256';
11 +
1012 var app = express();
1113
1214 app.set('view engine', 'jade');
1315
@@ -25,8 +27,14 @@
2527 name = avatar.name;
2628 image = avatar.image;
2729 })
2830 pull(
31 + sbot.query.read({query: [{$filter: { key: pin}}], limit: 1, reverse: true}),
32 + pull.drain(function (data) {
33 + pinned = data;
34 + })
35 + )
36 + pull(
2937 sbot.query.read({query: [{$filter: { value: { author: me, content: {type: 'post'}}}}], limit: 1, reverse: true}),
3038 pull.drain(function (data) {
3139 post = data;
3240 })
views/index.jadeView
@@ -7,26 +7,38 @@
77 link(rel='stylesheet' href='https://evbogue.com/style.css')
88 body
99 .contain
1010 .eight.col.off-two
11 + p.small.ri This is <a href='http://gitmx.com/%25qrU04j9vfUJKfq1rGZrQ5ihtSfA4ilfY3wLy7xFv0xk%3D.sha256/'>sdash</a>
1112 a(href='/'): h1= title
1213 hr
13- div(class='message')
14 + div.message
15 + p.small.ri: strong #{post.value.content.type}
1416 img(src='https://evbogue.com/ws/blobs/get/#{image}' class='avatar')
1517 p <a href='http://evbogue.com/' target='_parent'>@#{name}</a>
1618 != markdown(post.value.content.text)
1719 span.date #{moment(post.value.timestamp).fromNow()}
18- div(class='message')
20 + div.message
21 + p.small.ri: strong #{vote.value.content.type}
1922 img(src='https://evbogue.com/ws/blobs/get/#{image}' class='avatar')
2023 p <a href='http://evbogue.com/' target='_parent'>@#{name}</a> dug #{vote.value.content.vote.link}
2124 span.date #{moment(vote.value.timestamp).fromNow()}
2225 div.message
26 + p.small.ri: strong #{redo.value.content.type}
2327 img(src='https://evbogue.com/ws/blobs/get/#{reauthor.image}' class='avatar')
2428 p @<a href='#{redo.value.author}'>#{reauthor.name}</a>
2529 != markdown(redo.value.content.text)
2630 span.date #{moment(redo.value.timestamp).fromNow()}
27- div(class='message')
31 + div.message
32 + p.small.ri: strong #{gits.value.content.type}
2833 img(src='https://evbogue.com/ws/blobs/get/#{image}' class='avatar')
2934 p <a href='http://evbogue.com/' target='_parent'>@#{name}</a> pushed a git commit to #{gits.value.content.repo}<br />
3035 span.date #{moment(gits.value.timestamp).fromNow()}
36 + div.message
37 + p.small.ri: strong pinned #{pinned.value.content.type}
38 + img(src='https://evbogue.com/ws/blobs/get/#{image}' class='avatar')
39 + p <a href='http://evbogue.com/' target='_parent'>@#{name}</a>
40 + != markdown(pinned.value.content.text)
41 + span.date #{moment(pinned.value.timestamp).fromNow()}
42 +
3143 hr
32- p(style='font-size: .8em') <a href='mailto:ev@evbogue.com'>ev@evbogue.com</a> | <a href='/minimalist'>The Art of Being Minimalist</a> | <a href='/node'>Minimal Node</a> | <a href='https://gitmx.com/%408Qee0I%2FDwI5DHSCi3p5fsl6FyLGArrnDz3ox9qZr5Qc%3D.ed25519'>GitMX</a> | <a href='/blog'>Blog</a> | Mexico City
44 + p.small <a href='mailto:ev@evbogue.com'>ev@evbogue.com</a> | <a href='/minimalist'>The Art of Being Minimalist</a> | <a href='/node'>Minimal Node</a> | <a href='https://gitmx.com/%408Qee0I%2FDwI5DHSCi3p5fsl6FyLGArrnDz3ox9qZr5Qc%3D.ed25519'>GitMX</a> | <a href='/blog'>Blog</a> | Mexico City

Built with git-ssb-web