Update to my Second Crack Installation

I finally invested some time to get some issues in Second Crack addressed which I found missing or a little annoying. I already forked Marcos original Github repository weeks ago but never sat down to fix the things I was concerned about. Now I finally started with two of the major things I wanted to see.

First: Tag-Folder

The tag folder is a great one for me. Instead of storing all the tag xml and html files in the root director with filenames like 'tagged-fridaywallpaper.html' now the files are all stored in a folder called 'tag' the result is for example the Friday wallpaper series is now at CSPIEGL.com/tag/fridaywallpaper. Less cluttered httpdocs folder is always a good thing!

Second: Scheduled Posts

I wanted this feature since I started using Second Crack. I know there are reasons not to schedule posts but I like it. Especially for things like my Friday wallpaper series where I now can schedule posts in advance and they go online each Friday. This way I do not have to do it every week by hand but can do it once each month for example.

The markup for scheduled posts is:

  • Add the 'Published: 2012-09-19 01:45:00pm' tag beneath the heading.
  • Add the 'publish-now' tag or move the file into the '_publish-now' folder.
  • The file now gets scheduled and will be published the next time the update.sh script is forced to run.

Third: Other Fixes

While implementing the scheduled posts feature I noticed that if you put a file with a different ending than the default post ending (in my case '.md') into the '_publish-now' folder, it will be published even though the ending is different. I fixed that too. Additionally I tried to make the code of the update_drafts function a little easier to understand.


I will try to fix more in the coming month. For a list of issues I would like to address please head over to my Github repository of Second Crack. I am also open for people to join me developing this a little further, if interested please contact me (see about page)!