The "CMS" I wrote was about 75 lines of sh, and had slightly fewer features than the one linked here. That's the beauty of writing your own: you decide what to include, and no more. cp wc sort awk etc. is all you need. If you want it to look beautiful, that's where design and CSS come into play, both of which are outside the scope of content management.
Creating a simple blog system with a 500-line bash script (2011)
21–30 of 31 posts
Re: Creating a simple blog system with a 500-line bash script (2011)
#22Earlier quoted context omitted.
Yes, I have, but... Jekyll is done in ruby, octopress is a layer on top of it This kinda defeats the "simple" bit doesn't it? ;) I have nothing against these and if that floats your boat, then by all means, use it. But just the idea of not having to install anything (in fact, nothing ) extra and just having this all work with a single file is very appealing to me.
Ah yes, it's true...but for a Ruby developer, something that involves Ruby is just about as good as something that involves bash :) I guess I was thinking of "simple" in terms of the static HTML and deploy. I don't think you actually have to run any Ruby commands, you just run a command line task and it reads the textfiles from the specified directory. Unless I missed it in the OP's description, one huge advantage th…
for i in ./*.md; do perl Markdown.pl --html4tags $i > pub/${i%.*}.txt; done;
And viola! We have markdown formatted to html.Now if you consider "maintenance" or "separation of concerns" or any of the other things anyone using a framework takes for granted, this is inadequate, but that's not what I see this as. I could, of course, use grep and sed to do maintenance if I felt as much.
I think maybe both you and cmelbye in his reply are not considering is that this is just a step above manually editing and creating HTML files. The appeal isn't just simplicity, but a bit of nostalgia as well.
I guess it's a bit hard to explain, but the idea here is not having more layers than absolutely necessary between my thoughts and having it accessible to the web. I hope that made sense.
Re: Creating a simple blog system with a 500-line bash script (2011)
#23Author here. Feel free to drop any comments, this was a "weekend project" as I couldn't find anything as simple as that. By the way, I recently uploaded the code to github: https://github.com/carlesfe/bashblog and some people are using it to publish their blogs via dropbox and site44, cool!
Re: Creating a simple blog system with a 500-line bash script (2011)
#24See also my little project fugitive [1] a blog engine running on top of git using hooks written in Bash (not much more than 500 lines either), well technically it's even written in bare sh. [1] http://gitorious.org/fugitive
I think the only thing that I might have done differently would have been to allow myself to use Perl since it is a dependency of git anyway.
Re: Creating a simple blog system with a 500-line bash script (2011)
#25Author here. Feel free to drop any comments, this was a "weekend project" as I couldn't find anything as simple as that. By the way, I recently uploaded the code to github: https://github.com/carlesfe/bashblog and some people are using it to publish their blogs via dropbox and site44, cool!
I know this probably isn't meant for me since I don't seem to know what I'm doing. But how do you run this? An answer in a bit more detail than your github link would be useful. I have it on my server in a public folder and now I don't know what to do.
Re: Creating a simple blog system with a 500-line bash script (2011)
#26I know not everyone is a fan of Disqus, but it's as easy to implement (OK, the scripting side, anyway) as Google Analytics. Probably wouldn't be more than a couple of lines to have that option and then put Disqus comments at the bottom of the template.
Problem with using Disqus (and similar solutions) is that comments are at Disqus, so you have no real control over them. Yet not many people care about it. Ask HN: Open source commenting systems for static pages - alternatives to Juvia? https://news.ycombinator.com/item?id=4125787
Re: Creating a simple blog system with a 500-line bash script (2011)
#27I got a copy by request back in 2008 -- good stuff.
Re: Creating a simple blog system with a 500-line bash script (2011)
#28Author here. Feel free to drop any comments, this was a "weekend project" as I couldn't find anything as simple as that. By the way, I recently uploaded the code to github: https://github.com/carlesfe/bashblog and some people are using it to publish their blogs via dropbox and site44, cool!
Re: Creating a simple blog system with a 500-line bash script (2011)
#29Earlier quoted context omitted.
Problem with using Disqus (and similar solutions) is that comments are at Disqus, so you have no real control over them. Yet not many people care about it. Ask HN: Open source commenting systems for static pages - alternatives to Juvia? https://news.ycombinator.com/item?id=4125787
Can you not import them locally via the Disqus API, so that if at some point in the future you are not happy with Disqus, you can move to an alternative solution?
Re: Creating a simple blog system with a 500-line bash script (2011)
#30Author here. Feel free to drop any comments, this was a "weekend project" as I couldn't find anything as simple as that. By the way, I recently uploaded the code to github: https://github.com/carlesfe/bashblog and some people are using it to publish their blogs via dropbox and site44, cool!
Is the motivation something like "we can't install some kind of PHP and a database for you"?