Discussion:
[hakyll] My experience with Hakyll
Rohan Jain
2015-09-01 12:01:14 UTC
Permalink
Recently I made a few tweaks to my Hakyll configuration and the
project structure. I decided to document some, which I think aren't
that common:

http://www.rohanjain.in/tags/hakyll/
--
Thanks
Rohan Jain
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hakyll+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
b***@gmail.com
2015-10-07 09:05:56 UTC
Permalink
Hey Rohan,

Great stuff! If you're interested, you can submit a pull request
to https://github.com/beerendlauwers/hakyll-extra, I'm collecting any
useful functionality there.
Post by Rohan Jain
Recently I made a few tweaks to my Hakyll configuration and the
project structure. I decided to document some, which I think aren't
http://www.rohanjain.in/tags/hakyll/
--
Thanks
Rohan Jain
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hakyll+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Jasper Van der Jeugt
2016-03-30 19:38:11 UTC
Permalink
Hey Rohan,

That's great! I really liked the clean URLs one, and I felt like that
was missing in the tutorials on the hakyll site. It inspired me to add a
section with external articles here:

https://jaspervdj.be/hakyll/tutorials.html#external-articles

Peace,
Jasper
Post by Rohan Jain
Recently I made a few tweaks to my Hakyll configuration and the
project structure. I decided to document some, which I think aren't
http://www.rohanjain.in/tags/hakyll/
--
Thanks
Rohan Jain
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hakyll+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Deepak Jois
2016-03-31 06:24:50 UTC
Permalink
Post by Jasper Van der Jeugt
That's great! I really liked the clean URLs one, and I felt like that
was missing in the tutorials on the hakyll site.
This approach to clean URLs is also found in Jekyll. However, I did
not like the idea of a spurious folder and an index.html file inside
it to achieve clean URLs.

Instead, I chose to use a slightly different method of stripping off
the extension altogether[1]. The problem with that approach (at least
the last time I checked) was that we would lose the mime type
information for all the files. This created problems when viewing the
site with the default web server used to preview in Hakyll. I believe
it also creates problems if you host your site on Github, which cannot
handle files with no extension. Ideally, a fix should be applied to
both these places.

As for me, I host my site on S3. So I upload the files using a custom
uploader that sniffs the mime type[2] by actually examining the
contents of the file, and then setting it as metadata on the S3
object. Ideally, this could be something that Hakyll does as well.

Deepak


[1]: https://github.com/deepakjois/website/blob/master/src/Site.hs#L41
[2]:https://github.com/deepakjois/website/blob/master/upload.go#L35
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hakyll+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Jasper Van der Jeugt
2016-03-31 09:34:24 UTC
Permalink
Yes, I completely agree that that is a more proper way to do it.

However, as far as I know, a lot of people use Hakyll to deploy to
servers they don't really control (e.g. a folder provided by
university). In that case this is a nice way to do it.

Peace,
Jasper
Post by Deepak Jois
Post by Jasper Van der Jeugt
That's great! I really liked the clean URLs one, and I felt like that
was missing in the tutorials on the hakyll site.
This approach to clean URLs is also found in Jekyll. However, I did
not like the idea of a spurious folder and an index.html file inside
it to achieve clean URLs.
Instead, I chose to use a slightly different method of stripping off
the extension altogether[1]. The problem with that approach (at least
the last time I checked) was that we would lose the mime type
information for all the files. This created problems when viewing the
site with the default web server used to preview in Hakyll. I believe
it also creates problems if you host your site on Github, which cannot
handle files with no extension. Ideally, a fix should be applied to
both these places.
As for me, I host my site on S3. So I upload the files using a custom
uploader that sniffs the mime type[2] by actually examining the
contents of the file, and then setting it as metadata on the S3
object. Ideally, this could be something that Hakyll does as well.
Deepak
[1]: https://github.com/deepakjois/website/blob/master/src/Site.hs#L41
[2]:https://github.com/deepakjois/website/blob/master/upload.go#L35
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hakyll+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Kyle Marek-Spartz
2016-03-31 14:53:55 UTC
Permalink
Here's one that I've used:

https://javran.github.io/posts/2014-03-01-add-tags-to-your-hakyll-blog.html

Regarding the custom uploader, here's what I do:

http://kyle.marek-spartz.org/posts/2013-12-09-widely-and-hakyll.html

And I've inlined my CSS into each page because Google told me to:

http://kyle.marek-spartz.org/posts/2014-12-09-hakyll-css-template-compiler.html
Post by Jasper Van der Jeugt
Yes, I completely agree that that is a more proper way to do it.
However, as far as I know, a lot of people use Hakyll to deploy to
servers they don't really control (e.g. a folder provided by
university). In that case this is a nice way to do it.
Peace,
Jasper
Post by Deepak Jois
Post by Jasper Van der Jeugt
That's great! I really liked the clean URLs one, and I felt like that
was missing in the tutorials on the hakyll site.
This approach to clean URLs is also found in Jekyll. However, I did
not like the idea of a spurious folder and an index.html file inside
it to achieve clean URLs.
Instead, I chose to use a slightly different method of stripping off
the extension altogether[1]. The problem with that approach (at least
the last time I checked) was that we would lose the mime type
information for all the files. This created problems when viewing the
site with the default web server used to preview in Hakyll. I believe
it also creates problems if you host your site on Github, which cannot
handle files with no extension. Ideally, a fix should be applied to
both these places.
As for me, I host my site on S3. So I upload the files using a custom
uploader that sniffs the mime type[2] by actually examining the
contents of the file, and then setting it as metadata on the S3
object. Ideally, this could be something that Hakyll does as well.
Deepak
[1]: https://github.com/deepakjois/website/blob/master/src/Site.hs#L41
[2]:https://github.com/deepakjois/website/blob/master/upload.go#L35
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
For more options, visit https://groups.google.com/d/optout.
--
Kyle Marek-Spartz
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hakyll+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Jasper Van der Jeugt
2016-04-01 11:53:29 UTC
Permalink
Thanks, I've added those to the list!

Peace,
Jasper
Post by Kyle Marek-Spartz
https://javran.github.io/posts/2014-03-01-add-tags-to-your-hakyll-blog.html
http://kyle.marek-spartz.org/posts/2013-12-09-widely-and-hakyll.html
http://kyle.marek-spartz.org/posts/2014-12-09-hakyll-css-template-compiler.html
Post by Jasper Van der Jeugt
Yes, I completely agree that that is a more proper way to do it.
However, as far as I know, a lot of people use Hakyll to deploy to
servers they don't really control (e.g. a folder provided by
university). In that case this is a nice way to do it.
Peace,
Jasper
Post by Deepak Jois
Post by Jasper Van der Jeugt
That's great! I really liked the clean URLs one, and I felt like that
was missing in the tutorials on the hakyll site.
This approach to clean URLs is also found in Jekyll. However, I did
not like the idea of a spurious folder and an index.html file inside
it to achieve clean URLs.
Instead, I chose to use a slightly different method of stripping off
the extension altogether[1]. The problem with that approach (at least
the last time I checked) was that we would lose the mime type
information for all the files. This created problems when viewing the
site with the default web server used to preview in Hakyll. I believe
it also creates problems if you host your site on Github, which cannot
handle files with no extension. Ideally, a fix should be applied to
both these places.
As for me, I host my site on S3. So I upload the files using a custom
uploader that sniffs the mime type[2] by actually examining the
contents of the file, and then setting it as metadata on the S3
object. Ideally, this could be something that Hakyll does as well.
Deepak
[1]: https://github.com/deepakjois/website/blob/master/src/Site.hs#L41
[2]:https://github.com/deepakjois/website/blob/master/upload.go#L35
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
For more options, visit https://groups.google.com/d/optout.
--
Kyle Marek-Spartz
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "hakyll" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hakyll+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...