Blog aware, static site generation using F#.
If you've much experience with other static site generators like Octopress or Jekyll most of this should be fairly familiar, if not, hopefully it won't be too difficult to pick up.
FsBlog aims to be a blog-aware static site generator, mostly built in F#
for .NET and Mono developers.
If you've much experience with other static site generators like Octopress or Jekyll most of this should be fairly familiar, if not, hopefully it won't be too difficult to pick up.
FsBlog tends to rely on the fact that you're using the command line or terminal - almost all interaction with FsBlog and git are documented as such.
Although X-Platform is a goal for the not-too-distant-future - at the moment you'll need:
If you follow the instructions for using F# on Windows you'll probably be good to go.
First you'll need to clone the repo. On your command line, using git:
1: 2: |
git clone git://github.com/fsprojects/FsBlog.git FsBlog cd FsBlog |
Next, run the build:
1:
|
build
|
This should install a few NuGet dependencies that FsBlog makes use of.
Using your favourite F# code editor, edit the following section of the ./fsblog.fsx
file in your repo:
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: |
// -------------------------------------------------------------------------------------- // Configuration. // -------------------------------------------------------------------------------------- Environment.CurrentDirectory <- __SOURCE_DIRECTORY__ let root = "http://fsprojects.github.io/FsBlog" let title = "FsBlog - F# static site generation" let description = """ FsBlog aims to be a blog-aware static site generator, mostly built in F#. But don't worry, you won't even need to know any F# to get up and running. So long as you are comfortable using a command line or terminal, and have a degree of familiarity with Markdown and Razor syntax - you're good to go!""" |
There isn't a whole lot to change right now, but at some point you'll be able to configure a Twitter handle, GitHub account etc.
Again on your command line:
1:
|
fake new post="post title" |
This will create a new file in the following location, ready for you to edit: ./source/blog/yyyy/MM-dd-title.md
.
You can generate your website at any time from the command line using the following command:
1:
|
fake generate |
If you also want to preview your website, you can run the following command:
1:
|
fake preview |
The preview
command will also generate
the website too.