11 ms·
Author of Journey here (thanks Maksadbek for posting it on HN). I'm going to repost my comment from Reddit: I've been working on this blog engine in my spare t
by Kabukks 11y ago
Author of Journey here (thanks Maksadbek for posting it on HN).
I'm going to repost my comment from Reddit:
I've been working on this blog engine in my spare time for the last few months. My blog has been running on it without hiccups for about a month now (low volume, 700 visits a day tops).
I'd like some opinions if anyone has the time to try it out. (Worth pursuing? Any ideas for features? Should I die in a fire because my code quality sucks?)
Thanks :)
- syntern 11y agoLooks like it is a neat project, thanks for open sourcing it. Do you plan to support static export?
- Kabukks 11y agoIt's not yet planned, but definitely something that would be useful. I'll add it to the list. Here's my high priority feature list right now: Gzip support, hashes for serving static assets, multi-user support, support for all of the Ghost theme helpers, MySQL, Postgres, and Google App Engine support.
- ChuckMcM 11y agoOne of the reasons I started playing with Ghost is because generating the site statically allows for a lot of performance on a $5 VPS with nothing special but a fat internet pipe. As blogs are typically not heavy on the "interaction" aspects of things, this works really well. So consider this a vote for "static site support". If I were to express that as a requirement it would be something like "Site is served off a set of static pages that were generated on demand as the content on them or around them changed."
- bootload 11y ago"One of the reasons I started playing with Ghost is because generating the site statically allows for a lot of performance on a $5 VPS with nothing special but a fat internet pipe. As blogs are typically not heavy on the "interaction" aspects of things, this works really well." Wrote my own engine for exactly this reason. All python, no templates and only one imported module (markdown) which I'm going to use pythons (why not in the first place?). I concur with the idea. Whole blog is about 1.4Mb of text. Images are hosted so it's AUD3.5/month to host the blog + domain. It's not Ghost compatible. I based my template on Jeckyl. That is YAML front-matter followed by markdown. All contained in text files. It's a bit slot at the moment but works a charm. What format are you following?
- ChuckMcM 11y agoHeh, same. Used FrontPage for a while to basically "push" static pages to my site, then played with Blosxom for a bit but never published anything with it, wrote my own in Perl with Template toolkit and Markdown, and as that was going along, heard about and downloaded Ghost. Then built a 'theme' that matched my original skeumorphic notebook theme and basically have what I need to push the button on it (but haven't for some reason).
- bootload 11y agoprevious * hotdog (binary) -> site (worked there) * blosxom (perl) -> site * perl -> TT -> ftp -> site * python -> webpy -> appengine -> site now * python -> markdown -> ftp/ssh -> site future * [some back-end language/Rpi] -> js [front-end/iPad] -> [some transport layer] -> site I'm trading simplicity for speed and turn-around. The tool-chain is all cli, vim + browser. At some stage soon I'll write either an api/server to allow a simple interface to speed up process. The basic ideas are based on Dave Winer and Scripting.com
- Yhippa 11y agoI wish Octopress was this easy to use.
- tankenmate 11y agoI had a look at the docs on github (I haven't checked the source yet) but it doesn't mention if it supports more than one domain (or SNI, but I'm assuming it would piggy back on Go's support for SNI). If it doesn't yet support multi domain will it ever?
- Kabukks 11y agoInteresting. I haven't thought about that. It should be possible, but is not implemented yet. Go does indeed support SNI, but I'm using ListenAndServeTLS at the moment + I'm loading only one SSL certificate right now. I'll add that to the list as well. I think that might be a useful feature.
- mixu 11y agoIf you need static export, I wrote a project a while back that converts markdown to static output with Ghost theme support: https://github.com/mixu/ghost-render https://github.com/mixu/ghost-render
- Maksadbek 11y agoAuthor of the post here. I found your blog engine awesome. It inspired me to create my blog. Thanks for such a good project :)
- zura 11y agoRegarding Golang's if-hell e.g. in https://github.com/kabukky/journey/blob/master/database/update.go https://github.com/kabukky/journey/blob/master/database/upda... Couldn't you use panic/recover locally, inside functions - just for having a single error handling code?
- pdq 11y agoNo, panic/recover is a major hack. Rob Pike has written ideas here on how to clean up error handling if-blocks: http://blog.golang.org/errors-are-values http://blog.golang.org/errors-are-values
- burntsushi 11y agoNo, it's not a "major hack." That blog post is excellent, but it just doesn't always apply. The panic/recover idiom is extremely useful in parsers. For example, Go's JSON decoder: http://golang.org/src/encoding/json/decode.go http://golang.org/src/encoding/json/decode.go
- pdq 11y agoThe difference is that in parsers, errors are almost certainly fatal. As opposed to a runtime SQL error, where it could be a user error, value error, or other database error, which can be recovered from. Panic/recover are usually meant to catch "coding" and "assertion"-type errors (null pointers, array overflows, etc), not runtime errors. The latter is what the "error" values are used for.
- thirsteh 11y agoPanic/recover is no problem as long as it does not traverse API boundaries, i.e. affects the user of your package, unless it really is a "fatal user error" in a function that wouldn't otherwise return an error.
- burntsushi 11y agoI'm pretty sure you've misunderstood. Did you read the code I linked you to? Look at how it handles errors internally. Go's standard JSON decoder isn't going to crash your program if it fails to parse JSON---that would be disastrous. It exposes regular errors to the user. But internally, it uses panic/recover because it elides a lot of manual error checking.
- monk_e_boy 11y agoHow did using Go feel compared with other languages, I'm a php, ruby, python guy. Just wondering your opinion on why you chose Go?
- Kabukks 11y agoI chose Go because I wanted to learn it ;) In retrospect tough, I couldn't have wished for a better language to write a web server in. I especially like the opinionated handling of code formatting and memory safety (it won't let you compile if you have a unused variable for example) and the consistent error handling (I know, a lot people seem to dislike Go's error-oriented programming style).
- wting 11y agoUnused variables have nothing to do with memory safety. At most they'll take up some stack or heap space. https://en.wikipedia.org/wiki/Memory_safety https://en.wikipedia.org/wiki/Memory_safety Memory safety is enforced in Go via best practices–like C and C++ ecosystems. However because of gc and channels race conditions happen less often in Go but there's no explicitly tooling to prevent them from happening: http://research.swtch.com/gorace http://research.swtch.com/gorace
- Kabukks 11y agoYou are right. I was thinking about the general fail-safety of my programs. Not letting me compile saved me from overlooking a (return) value more than once.
- threeseed 11y agoYou could accomplish the same thing by incorporating a code checker as part of your build process. That way you would be catching a lot more code issues then just unused imports, variables etc.
- Immortalin 11y agoIt would really great if you could convert it into a modular CMS with ecommerce features similar to Drupal Commerce.