directory_indexes features and /index.html

32 views
Skip to first unread message

Johan Sahlén

unread,
Aug 2, 2011, 10:35:40 AM8/2/11
to middlem...@googlegroups.com
Hi,
Just started checking out Middleman, and I'm really liking it so far (easy to get into, and defaults are really close to what I want to accomplish, compared to for example Nanoc.)
I'm going to serve my site from Apache, and I'd like to use pretty URLs. I've done activate :directory_indexes, and it seems to work well, except for the fact that source/index.html.haml gets built as build/index/index.html. Can I add an exception for this somehow, in config.rb, or do something else to make it behave as expected (e.g. being built as build/index.html)?

Thanks,
Johan

Thomas Reynolds

unread,
Aug 2, 2011, 11:39:51 AM8/2/11
to middlem...@googlegroups.com
Good catch. You can make an exception in config.rb (which I should add to the guide), but Middleman should probably ignore files already named index.html as well.

To ignore:

    page "/index.html", :directory_index => false

-Thomas

Johan Sahlén

unread,
Aug 3, 2011, 3:46:17 AM8/3/11
to middlem...@googlegroups.com
Thanks a lot!
Reply all
Reply to author
Forward
0 new messages