[Haskell-cafe] Ghent FPG meeting on 26 June, 2013

2013-05-29 Thread Jasper Van der Jeugt
Hello,

The "Functional Programming Group Ghent" (GhentFPG) [1] is a friendly group for
all people interested in functional programming, with a tendency
towards Haskell.
It is organised as part of Zeus WPI [2].

We are pleased to announce that we will hold a next meeting on Wednesday, 26th
of June, starting at 19h00! There will be three talks.

The main presentation, by Adam Bergmark from Silk [3] is about Fay [4]:

  Fay is a proper subset of Haskell that compiles to JavaScript. There is a
  compiler with the same name written in Haskell. Web browsers only speak
  JavaScript but more and more people find that they want to compile to
  JavaScript instead.

  Why do we want to compile Haskell to JavaScript, and what advantages does
  Fay have compared to other compilers?

  What are the challenges in compiling Haskell and supporting a language
  ecosystem, and how do we do it?

  What can Fay currently do, and what is planned for the future?

  This will be a broad overview about Fay for prospective users, followed by
  an in-depth look at interesting parts of the compiler internals.

Additionally, there will be two short talks by two students who did an
Msc. Thesis
about functional programming languages:

  "Genetic Algorithms in Haskell" by Matthias Delbar
  "Automatic Detection of Recursion Patterns" by Jasper Van der Jeugt

The meeting will take place in the Jozef Plateauzaal at the following address,

Faculteit Ingenieurswetenschappen
Universiteit Gent
Plateaustraat 22
9000 Gent

As mentioned above, we aim to start at 19:00. After the meeting we can go
for drinks in a nearby pub (this latter part is, of course, completely optional)

We hope to see you all there!

Regards,
On behalf of the GhentFPG organising committee.

[1]: http://groups.google.com/group/ghent-fpg
[2]: http://zeus.ugent.be/
[3]: http://www.silkapp.com/
[4]: http://www.fay-lang.org/

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: Hakyll 4

2013-01-16 Thread Jasper Van der Jeugt
After a few weeks of beta status [1], I've now released version 4.0 of
the Hakyll static site generator library. I'm really glad with this
release, as from what I've found and heard, it makes many things a lot
easier.

# Main changes

- The important `Compiler` type has been changed from `Arrow` to
  `Monad`: this makes it much easier to write custom compilers, as
  most Haskellers are more familiar with monads.

- The template stays superficially the same, but it has grown much
  more powerful and flexible underneath.

- Early and fast access to metadata makes things such as tags and
  pagination much easier.

- All items (images, css...) can now have metadata associated.
  Metadata can no longer be manipulated, and this immutability should
  reduce the number of encountered bugs.

- A `check` command has been added. This allows you to check that all
  internal (or external) links are still alive.

# Installation, migration

In order to install Hakyll 4, grab it from Hackage:

cabal update
cabal install hakyll

Here are some useful links:

- Website: 
- Tutorial index: 
- Migration guide:
  


All feedback is welcome as always.

[1]: https://groups.google.com/d/topic/hakyll/eRKWz8bVB0w/discussion

Peace,
Jasper

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: stylish-haskell 0.2

2012-06-07 Thread Jasper Van der Jeugt
Hello all,

I've just released stylish-haskell 0.2 [1]. This release adds a
flexible configuration file, which already provides some options for
the different processing steps, and it will also make future
enhancements easy. You can use a per-project configuration file, as
documented in the README [2]. A sample configuration file looks like
[3].

Feedback is very welcome, issues and enhancement requests can filed here [4].

[1]: http://hackage.haskell.org/package/stylish-haskell
[2]: https://github.com/jaspervdj/stylish-haskell/blob/master/README.markdown
[3]: 
https://github.com/jaspervdj/stylish-haskell/blob/master/.stylish-haskell.yaml
[4]: https://github.com/jaspervdj/stylish-haskell/issues

Peace,
Jasper

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] ANN: reform - a type-safe form generation and validation library in the spirit of formlets and digestive-functors < 0.2

2012-05-22 Thread Jasper Van der Jeugt
Congrats on the release!

I would like to help out with the full comparison since I have some
knowledge and experience on the subject. Because of the different
approach, I think there's definitely room for two libraries.

Cheers,
Jasper

On Tue, May 22, 2012 at 2:23 AM, Felipe Almeida Lessa
 wrote:
> On Mon, May 21, 2012 at 7:18 PM, Jeremy Shaw  wrote:
>> I hope to do a full comparison of reform vs digestive-functors 0.3 vs
>> yesod forms in a few weeks.
>
> That would be awesome!  Just sayin' =).
>
> Cheers,
>
> --
> Felipe.
>
> --
> You received this message because you are subscribed to the Google Groups 
> "HAppS" group.
> To post to this group, send email to ha...@googlegroups.com.
> To unsubscribe from this group, send email to 
> happs+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/happs?hl=en.
>

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] [ANN] blaze-html-0.5

2012-04-21 Thread Jasper Van der Jeugt
Hello all,

I've just released a new version of blaze-html on Hackage. It has some
backward-incompatible changes, so feel free to contact me if you run
into any trouble.

Summary of changes:
- Split into blaze-markup and blaze-html
- Easy creation of custom HTML elements
- Very simple HTML tree manipulation

For more details, see:

http://jaspervdj.be/posts/2012-04-21-blaze-html-0.5.html

Cheers,
Jasper

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] 10th Ghent Functional Programming Group Meeting on Thursday, December 15, 2011 at 19h30

2011-12-11 Thread Jasper Van der Jeugt
Dear All,

We would like to remind you of the 10th Ghent Functional Programming
Group (GhentFPG) meeting, which will take place this Thursday,
December 15, 2011, at 19h30 in the Technicum building of Ghent
University (Sint-Pietersnieuwstraat 41, 9000 Gent).

This meeting, we will focus on tackling some interesting problems with
the elegance of functional programming. We will try to post the
problems to this mailing list at least two days in advance.

As with the previous meeting, the meeting room is still unreachable
through the regular building entrance because of construction works.
Hence, attendees need to take the alternative side entrance. This
entrance can be found on the right side (as seen from the street) of
the building -- it will remain open until 20:00. If you walk up to the
Technicum building and go right at the bicycle stands, you should see
“Ingang Blok 1 & Blok 2” indicated. Follow this, and you’ll be able to
get inside, at which point you’ll see arrows pointing to the meeting
room. For safety measures the blue doors will be locked, so if you
arrive after 19:30, please give us a call at +32 (0) 9 264 3370, so we
can come and open the doors for you.

P.S. we would also like to remind you that you are all certainly
welcome at the talk about "Real-World Functional Programming @
Incubaid", organized by Tom Schrijvers for his course on Functional &
Logic Programming at Ghent University. For more details see [1].

[1]: https://groups.google.com/d/topic/ghent-fpg/csUnMX08WKc/discussion

Hope to see you then!
The GhentFPG Organizing Committee.

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: websockets 0.4.0.0

2011-11-04 Thread Jasper Van der Jeugt
Hello all,

I'm pleased to announce the release of websockets [1] 0.4.0.0 today.
You can grab it on Hackage [2].

This update brings an (almost completely rewritten) library which has
support for multiple versions of the protocol, meaning you can choose
to write backwards-compatible applications, or use the latest and
greatest, all using a common API.

All feedback is obviously welcome, I'd be glad to hear what you guys
think. For the next version, client-side support is planned, so the
library user can write clients in addition to servers. If there's any
other feature you would like to see, feel free to let me know.

[1]: http://jaspervdj.be/websockets/
[2]: http://hackage.haskell.org/package/websockets

Cheers,
Jasper

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] 9th Ghent Functional Programming Group meeting on Tuesday, the 4th of October, 2011

2011-09-27 Thread Jasper Van der Jeugt
Hello all,

We would like to remind you of our 9th GhentFPG [1] meeting and set
some things straight. In the previous announcement, we mistakenly put
“Thursday, the 4th of October”. This should be “Tuesday, the 4th of
October”. We hope this mistake has not caused any major inconvenience.

There is also a small issue regarding the the room where we will host
the meeting: it is unreachable through the regular building entrance
because of construction works. Hence, attendees need to take the
alternative side entrance. This entrance can be found on the right
side (as seen from the street) of the building -- it will remain open
until 20:00. If you walk up to the Technicum building and go right at
the bicycle stands, you should see “Ingang Blok 1 & Blok 2” indicated.
Follow this, and you’ll be able to get inside, at which point you’ll
see arrows pointing to the meeting room. For safety measures the blue
doors will be locked, so if you arrive after 19:30, please give us a
call at +32 (0) 9 264 3370, so we can come and open the doors for you.

If you can’t find the entrance, or any other problems arise, you can
also contact us at +32476264847.

[1]: http://www.haskell.org/haskellwiki/Ghent_Functional_Programming_Group

Hoping to see you there,
The GhentFPG organizing committee

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] 9th Ghent Functional Programming Group meeting on Tuesday, the 4th of October, 2011

2011-09-19 Thread Jasper Van der Jeugt
Hello all,

We are glad to invite you to our 9th GhentFPG [1] meeting, which takes
place on Thursday, the 4th of October, 2011 at 19:30 in the Technicum
building of Ghent University. You do not have to be a Functional
Programming guru to attend, everyone eager to learn is welcome.

As before, the electronic sliding doors will be locked, but a phone
number that you can call to get in will be provided at the doors on
the far left of the building.

The program is as follows:

First, we will have a talk by Jurriën Stutterheim, from Utrecht: Snap
Framework [2] is a relatively young, but very promising and already
quite popular Haskell web framework. Its upcoming 0.6 release has seen
a major redesign in the way you write (reusable) components for the
framework using so-called snaplets. In this talk, we will look at how
you can write snaplets and how you can put them together to create
modular web applications.

Then, we will have a number of lightning talks in which the following
projects are presented:

- hCole-server [3], a web interface to a framework for compiler
optimizations (Andy Georges);
- GA [4], a library to write genetic algorithms in Haskell (Kenneth Hoste);
- websockets [5], a Haskell library for writing WebSocket-capable
servers (Jasper Van der Jeugt).

If you would also like to give a lightning talk (15 mins), please
contact us and we will add you to this list. Afterwards, we will have
some drinks at a local bar.

[1]: http://www.haskell.org/haskellwiki/Ghent_Functional_Programming_Group
[2]: http://snapframework.com/
[3]: http://github.com/itkovian/hcole-server
[4]: http://github.com/boegel/GA
[5]: http://github.com/jaspervdj/websockets

Hoping to see you there,
The GhentFPG organizing commitee

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] [GSoC] Text/UTF-8: Call for Benchmarks

2011-04-27 Thread Jasper Van der Jeugt
Hello all,

I'm very glad that I have been accepted again this year for the Google
Summer of Code [1] program for haskell.org. My project aims to improve
the text [2] library by converting it to internally use UTF-8 instead
of UTF-16.

UTF-8 and UTF-16 both have advantages and disadvantages, which
actually makes it a pretty complicated choice. I've written about this
a little in my [3] (especially see Tom Harper's master dissertation if
you're interested in the subject).

To support a decision here on UTF-8 vs. UTF-16, lots of benchmarks
will be needed. Hence, this is the first focus of the GSoC project:
collecting a large benchmark suite which models real-world usage of
the text library.

This is why I'd like to ask everyone who has written/knows libraries
or applications that use the text library extensively to inform me of
these efforts. The reverse dependencies list on Hackage is a good
starting point for me but it doesn't point out how popular these
packages are and how intensively they use the text library. I will
then convert a subset of this code to a
benchmark suite using criterion.

Open source code means more reliable benchmarks, because I can publish
the code I used for them. However, I'm also willing to sign
non-disclosure agreements if this means I can try out what effects the
changes have on large systems.

There's several ways to contact me: you can reply to this thread, or
you can mail me privately using `jaspervdj+t...@gmail.com`. Thanks in
advance for any help!

[1]: http://code.google.com/soc/
[2]: http://hackage.haskell.org/package/text
[3]: http://jaspervdj.be/files/2011-gsoc-text-utf8-proposal.html

Cheers,
Jasper

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: Hakyll 3.1

2011-04-06 Thread Jasper Van der Jeugt
Hello all,

I've just uploaded Hakyll 3.1.0.0 [1] to Hackage. It contains some
backwards-incompatible changes (but they are really for the greater
good).

The most important change is the matching done in the rules DSL. What
used to be written as:

route "posts/*" someRoute
compile "posts/*" someCompiler

Is now written as:

match "posts/*" $ do
route someRoute
compile someCompiler

This new style is way more expressive, as you can define custom
predicates such as:

match (predicate (\i -> matches "foo/*" i && not (matches
"foo/bar" i))) $ do ...

For more information, see the Pattern documentation [2].

Another slight change is that the `Hakyll.Web.Tags` [3] module now
uses an association list instead of a `Data.Map` -- in case you want
to change the order in which tags are displayed.

If you have any questions or trouble migrating, feel free to drop a
mail to me or here [4] or visit us in #hakyll on Freenode.

[1]: http://hackage.haskell.org/package/hakyll
[2]: http://jaspervdj.be/hakyll/reference/Hakyll-Core-Identifier-Pattern.html
[3]: http://jaspervdj.be/hakyll/reference/Hakyll-Web-Tags.html
[4]: https://groups.google.com/forum/#!forum/hakyll

Cheers,
Jasper

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] 7th Ghent Functional Programming Group meeting on Tuesday, April 26

2011-04-03 Thread Jasper Van der Jeugt
We probably won't have a video camera, but we can always provide the slides.

Cheers,
Jasper

On Sat, Apr 2, 2011 at 8:41 PM, oliver mueller  wrote:
> sounds like an interesting program...
> you should think about making the talks available later for those who
> can not attend.
> br,
> oliver
>
> On Apr 1, 7:20 pm, Jasper Van der Jeugt  wrote:
>> Dear all,
>>
>> We are very glad to announce an exciting program for the 7th meeting of the
>> Ghent Functional Programming Group, especially since we are celebrating our
>> first year of existence today. Our program features no less than three
>> interesting functional programming languages: Erlang, Haskell and Scheme.
>>
>> The meeting will take place on Tuesday, April 26 in the Technicum building of
>> Ghent University (Sint-Pietersnieuwstraat 41, 9000 Gent) at 19h30. As 
>> before, to
>> enter the building, you should go to the automatic sliding door on the far 
>> left
>> of the building and dial the phone number that is provided on the note taped 
>> to
>> the door. Someone will then open the door for you.
>>
>> Our program is as follows:
>>
>> 1. Tom Van Custem - Experiments with MapReduce in Erlang
>>
>> MapReduce is a programming model for large data processing popularized by, 
>> and
>> in daily use at Google. The MapReduce model builds strongly on key tenets of
>> functional programming such as higher-order functions and side-effect free
>> execution. In this talk, we summarize this programming model and describe a
>> didactic implementation in Erlang. Invented at Ericsson's research labs, 
>> Erlang
>> is known for its massively concurrent programming model, and itself builds 
>> on a
>> functional core language. The talk will not focus on Erlang as such, but we 
>> will
>> describe its key features as needed to understand the MapReduce abstraction.
>>
>> 2. Tom Schrijvers - How you could have won the VPW 2011 contest with Haskell
>>
>> We all know that Functional Programming is great for writing concise 
>> solutions
>> for programming problems. With some skill this can even be done quickly! Yet,
>> there was little evidence of this at the 3rd edition of the Flemish
>> Programming Contest (VPW 2011) that took place on March 23. Not so before
>> the contest: The jury stress-tested all questions by writing various
>> solutions in different languages. Haskell was used to solve most problems
>> and invariably produced short solutions.
>>
>> In this talk I present my own Haskell solutions to several of this year's
>> problems and discuss alternative solution strategies with the audience. After
>> the talk you will be all set for winning next year's edition -- or at least
>> enjoying it -- using Haskell.
>>
>> 3. Pieter Audenaert - Functional Geometry and a Graphical Language
>>
>> We will discuss a simple language for drawing images. During the 
>> presentation we
>> will illustrate the power of data abstraction and algebraic closure, 
>> meanwhile
>> using higher order procedures in an essential manner. The language has been
>> designed to easy experimenting with patterns such as those appearing in 
>> typical
>> M.C. Escher drawings where the artist repeats the pattern both moving it 
>> across
>> the drawing and scaling it when applicable. In the language we use 
>> procedures to
>> represent the data objects that will be combined in the final drawing and we
>> make sure that all operations conducted on these procedures are algebraically
>> closed. These features allow generating patterns of any complexity.
>>
>> For our implementation, we use the LISP functional programming language -- 
>> more
>> accurately, the Scheme dialect. The presentation is based on "Structure and
>> Interpretation of Computer Programs", Abelson & Sussman
>>
>> Hope to see you there!
>>
>> The GhentFPG organizing committee,
>> Andy Georges
>> Jeroen Janssen
>> Jasper Van der Jeugt
>>
>> ___
>> Haskell-Cafe mailing list
>> Haskell-C...@haskell.orghttp://www.haskell.org/mailman/listinfo/haskell-cafe
>
> ___
> Haskell-Cafe mailing list
> Haskell-Cafe@haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] 7th Ghent Functional Programming Group meeting on Tuesday, April 26

2011-04-01 Thread Jasper Van der Jeugt
Dear all,

We are very glad to announce an exciting program for the 7th meeting of the
Ghent Functional Programming Group, especially since we are celebrating our
first year of existence today. Our program features no less than three
interesting functional programming languages: Erlang, Haskell and Scheme.

The meeting will take place on Tuesday, April 26 in the Technicum building of
Ghent University (Sint-Pietersnieuwstraat 41, 9000 Gent) at 19h30. As before, to
enter the building, you should go to the automatic sliding door on the far left
of the building and dial the phone number that is provided on the note taped to
the door. Someone will then open the door for you.

Our program is as follows:

1. Tom Van Custem - Experiments with MapReduce in Erlang

MapReduce is a programming model for large data processing popularized by, and
in daily use at Google. The MapReduce model builds strongly on key tenets of
functional programming such as higher-order functions and side-effect free
execution. In this talk, we summarize this programming model and describe a
didactic implementation in Erlang. Invented at Ericsson's research labs, Erlang
is known for its massively concurrent programming model, and itself builds on a
functional core language. The talk will not focus on Erlang as such, but we will
describe its key features as needed to understand the MapReduce abstraction.

2. Tom Schrijvers - How you could have won the VPW 2011 contest with Haskell

We all know that Functional Programming is great for writing concise solutions
for programming problems. With some skill this can even be done quickly! Yet,
there was little evidence of this at the 3rd edition of the Flemish
Programming Contest (VPW 2011) that took place on March 23. Not so before
the contest: The jury stress-tested all questions by writing various
solutions in different languages. Haskell was used to solve most problems
and invariably produced short solutions.

In this talk I present my own Haskell solutions to several of this year's
problems and discuss alternative solution strategies with the audience. After
the talk you will be all set for winning next year's edition -- or at least
enjoying it -- using Haskell.

3. Pieter Audenaert - Functional Geometry and a Graphical Language

We will discuss a simple language for drawing images. During the presentation we
will illustrate the power of data abstraction and algebraic closure, meanwhile
using higher order procedures in an essential manner. The language has been
designed to easy experimenting with patterns such as those appearing in typical
M.C. Escher drawings where the artist repeats the pattern both moving it across
the drawing and scaling it when applicable. In the language we use procedures to
represent the data objects that will be combined in the final drawing and we
make sure that all operations conducted on these procedures are algebraically
closed. These features allow generating patterns of any complexity.

For our implementation, we use the LISP functional programming language -- more
accurately, the Scheme dialect. The presentation is based on "Structure and
Interpretation of Computer Programs", Abelson & Sussman

Hope to see you there!

The GhentFPG organizing committee,
Andy Georges
Jeroen Janssen
Jasper Van der Jeugt

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: Hakyll 3

2011-02-28 Thread Jasper Van der Jeugt
Hello all,

I've just uploaded the 3.0.0.0 version of Hakyll [1] to Hackage [2].
This is a complete rewrite, and completely backward-incompatible with
previous versions. Sorry for that.

On the other hand, I believe almost all aspects of the library have
improved tremendously. Hakyll now uses a declarative EDSL in Haskell
to specify compilation rules, and an arrow-based EDSL to describe the
compilation process. If you want to have a quick look, I recommend
have a glance at the example in the tutorial [3].

More documentation needs to be written, but I wanted to make sure I
can incorporate your feedback into that process.

[1]: http://jaspervdj.be/hakyll/
[2]: http://hackage.haskell.org/package/hakyll-3.0.0.2
[3]: http://jaspervdj.be/hakyll/tutorial.html

Cheers,
Jasper

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Fwd: web-routes and forms

2011-01-29 Thread Jasper Van der Jeugt
Hello,

I've backported the `inputHidden` combinator to the 0.0.2 branch, you
can find it on hackage as digestive-functors-blaze-0.0.2.2.

Hope this helps,
Cheers,
Jasper

On Fri, Jan 28, 2011 at 8:10 PM, Corentin Dupont
 wrote:
> Hello again,
> is there a way to had a "hidden" field in digestive-functor-blaze?
> I'm using it to transmit some data...
> Thanks,
> Corentin
>
> On Thu, Jan 27, 2011 at 11:21 AM, Corentin Dupont
>  wrote:
>>
>> OK thanks, now it's clear!
>>
>> On Thu, Jan 27, 2011 at 11:13 AM, Jasper Van der Jeugt
>>  wrote:
>>>
>>> Hello,
>>>
>>> As Jeremy said, the HTML returned by formHtml is meant to be placed
>>> inside the a  tag: it does not include a  tag. You should
>>> use it like this:
>>>
>>> >             H.form ! A.enctype (H.stringValue $ show enctype)
>>> >                    ! A.method "POST" ! A.action "/" $ do
>>> >                 html  -- The HTML rendered by formHtml
>>> >                 H.input ! A.type_ "submit" ! A.value "Submit"
>>>
>>> (with or without the submit button).
>>>
>>> Cheers,
>>> Jasper
>>>
>>> On Jan 27, 2011 10:54 AM, "Corentin Dupont" 
>>> wrote:
>>> > Hello Jasper,
>>> > Do you have an idea?
>>> >
>>> > Thanks,
>>> > Corentin
>>> >
>>> > -- Forwarded message --
>>> > From: Jeremy Shaw 
>>> > Date: Thu, Jan 27, 2011 at 2:22 AM
>>> > Subject: Re: web-routes and forms
>>> > To: Corentin Dupont 
>>> > Cc: haskell 
>>> >
>>> >
>>> > On Wed, Jan 26, 2011 at 4:33 PM, Corentin Dupont
>>> >  wrote:
>>> >
>>> >> Now turning to digestive functors, I don't see where do goes the
>>> >> "A.action
>>> >> actionURL" part that was in traditionnal forms?
>>> >> It seems I need it for routing the result of the form.
>>> >
>>> > I think you will find formHtml is returning you the stuff that goes
>>> > inside the  tag, but does not actually include the form tag
>>> > itself ?
>>> >
>>> > I am not sure how to modify the attrs using blaze-html. I think that
>>> > is a missing feature of the digestive-functors-blaze package. In
>>> > digestive-functors-hsp there is a function:
>>> >
>>> >
>>> > setAttrs :: (EmbedAsAttr x attr, XMLGenerator x, Monad m, Functor m) =>
>>> > Form m i e [HSX.GenXML x] a
>>> > -> attr
>>> > -> Form m i e [HSX.GenXML x] a
>>> > setAttrs form attrs = mapView (map (`set` attrs)) form
>>> >
>>> >
>>> > You probably need something similar for blaze.
>>> >
>>> > - jeremy
>>
>
>

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Fwd: web-routes and forms

2011-01-27 Thread Jasper Van der Jeugt
Hello,

As Jeremy said, the HTML returned by formHtml is meant to be placed
inside the a  tag: it does not include a  tag. You should
use it like this:

> H.form ! A.enctype (H.stringValue $ show enctype)
>! A.method "POST" ! A.action "/" $ do
> html  -- The HTML rendered by formHtml
> H.input ! A.type_ "submit" ! A.value "Submit"

(with or without the submit button).

Cheers,
Jasper

On Jan 27, 2011 10:54 AM, "Corentin Dupont"  wrote:
> Hello Jasper,
> Do you have an idea?
>
> Thanks,
> Corentin
>
> -- Forwarded message --
> From: Jeremy Shaw 
> Date: Thu, Jan 27, 2011 at 2:22 AM
> Subject: Re: web-routes and forms
> To: Corentin Dupont 
> Cc: haskell 
>
>
> On Wed, Jan 26, 2011 at 4:33 PM, Corentin Dupont
>  wrote:
>
>> Now turning to digestive functors, I don't see where do goes the "A.action
>> actionURL" part that was in traditionnal forms?
>> It seems I need it for routing the result of the form.
>
> I think you will find formHtml is returning you the stuff that goes
> inside the  tag, but does not actually include the form tag
> itself ?
>
> I am not sure how to modify the attrs using blaze-html. I think that
> is a missing feature of the digestive-functors-blaze package. In
> digestive-functors-hsp there is a function:
>
>
> setAttrs :: (EmbedAsAttr x attr, XMLGenerator x, Monad m, Functor m) =>
> Form m i e [HSX.GenXML x] a
> -> attr
> -> Form m i e [HSX.GenXML x] a
> setAttrs form attrs = mapView (map (`set` attrs)) form
>
>
> You probably need something similar for blaze.
>
> - jeremy

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] 6th Ghent Functional Programming Group Meeting: 17/02/2011

2011-01-22 Thread Jasper Van der Jeugt
(apologies if you receive multiple copies)

Dear all,

We would like to announce that the sixth Ghent Functional Programming
Group Meeting will take place on Thursday, February 17, in the
Technicum Building (Sint-Pietersnieuwstraat 41, 9000 Gent) of Ghent
University at 19h. We will use the "Gobelijn" room this time. To bring
some variation into the concept, we will host a problem solving
meeting instead of talks.

Bring your favorite functional programming language, a laptop with a
wireless card (if possible), and the willingness to work together in
small groups with other attendees on some interesting problems. We
would like to note that is not a contest as such, we want to focus on
elegance and working together instead of finding a quick and dirty
solution. A beamer will be available if someone wants to give a quick
explanation on his/her solution.

For more information you can follow us at twitter (@ghentfpg) or sign
up for our google group (http://groups.google.com/group/ghent-fpg).

Hope to see you all then,

The GhentFPG organizing committee,
Andy Georges
Jeroen Janssen
Jasper Van der Jeugt

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] web-routes and forms

2011-01-22 Thread Jasper Van der Jeugt
Hello,

I forgot to upload the version with the fixed type of `submit`. It is
on hackage now as digestive-functors-blaze-0.0.2.1.

Cheers,
Jasper

On Fri, Jan 21, 2011 at 9:33 PM, Corentin Dupont
 wrote:
> Hello Jeremy,
> I'm still trying to integrate web routes, but there is one thing I don't
> understand:
> how to deal with multiple forms?
>
> In my former application, each forms used to redirect to a subdirectory of
> the web site, and an appropriate handler was waiting there.
> But now with web routes I don't see how to do that.
> I've tried to push down the decision over subdirectories (with the guard
> "dir") inside the RouteT monad:
>
> type NomicServer   = ServerPartT IO
> type RoutedNomicServer = RouteT PlayerCommand NomicServer
>
> nomicSite :: ServerHandle -> Site PlayerCommand (NomicServer Html)
> nomicSite sh = setDefault (Noop 0) Site {
>   handleSite = \f url -> unRouteT (routedNomicHandle sh url) f
>     , formatPathSegments = \u -> (toPathSegments u, [])
>     , parsePathSegments  = parseSegments fromPathSegments
> }
>
> routedNomicHandle :: ServerHandle -> PlayerCommand -> RoutedNomicServer Html
> routedNomicHandle sh pc = do
>    d <- liftRouteT $ liftIO getDataDir
>    msum [dir "Login" $ loginPage,
>  dir "postLogin" $ postLogin,
>  --nullDir >> fileServe [] d,
>  dir "NewRule" $ newRule sh,
>  dir "NewGame" $ newGameWeb sh,
>  dir "Nomic" $ routedNomicCommands sh pc]
>
>
> routedNomicCommands :: ServerHandle -> PlayerCommand -> RoutedNomicServer
> Html
> routedNomicCommands sh (Noop pn)   = nomicPageComm pn sh
> (return ())
> routedNomicCommands sh (JoinGame pn game)  = nomicPageComm pn sh
> (joinGame game pn)
> routedNomicCommands sh (LeaveGame pn)  = nomicPageComm pn sh
> (leaveGame pn)
> routedNomicCommands sh (SubscribeGame pn game) = nomicPageComm pn sh
> (subscribeGame game pn)
> routedNomicCommands sh (UnsubscribeGame pn game)   = nomicPageComm pn sh
> (unsubscribeGame game pn)
> routedNomicCommands sh (Amend pn)  = nomicPageComm pn sh
> (amendConstitution pn)
> routedNomicCommands sh (DoAction pn an ar) = nomicPageComm pn sh
> (doAction' an ar pn)
> routedNomicCommands sh (NewRule pn name text code) = nomicPageComm pn sh
> (submitRule name text code pn)
> routedNomicCommands sh (NewGame pn game)   = nomicPageComm pn sh
> (newGame game pn)
>
>
> loginPage :: RoutedNomicServer Html
> loginPage = do
>    l <- loginForm
>    ok $ H.html $ do
>   H.head $ do
>     H.title (H.string "Login to Nomic")
>     H.link ! rel "stylesheet" ! type_ "text/css" ! href
> "/static/css/nomic.css"
>     H.meta ! A.httpEquiv "Content-Type" ! content
> "text/html;charset=utf-8"
>     H.meta ! A.name "keywords" ! A.content "Nomic, game, rules, Haskell,
> auto-reference"
>   H.body $ do
>     H.div ! A.id "container" $ do
>    H.div ! A.id "header" $ "Login to Nomic"
>    H.div ! A.id "login" $ l
>    H.div ! A.id "footer" $ "footer"
>
> loginForm :: RoutedNomicServer Html
> loginForm = do
>    ok $ H.form ! A.method "POST" ! A.action "/postLogin" ! enctype
> "multipart/form-data;charset=UTF-8"  $ do
>   H.label ! for "login" $ "Login"
>   input ! type_ "text" ! name "login" ! A.id "login" ! tabindex "1" !
> accesskey "L"
>   H.label ! for "password" $ "Password"
>   input ! type_ "text" ! name "password" ! A.id "password" ! tabindex
> "2" ! accesskey "P"
>   input ! type_  "submit" ! tabindex "3" ! accesskey "S" ! value "Enter
> Nomic!"
>
> postLogin :: RoutedNomicServer Html
> postLogin = do
>   methodM POST -- only accept a post method
>   mbEntry <- getData -- get the data
>   case mbEntry of
>     Nothing -> error $ "error: postLogin"
>     Just (LoginPass login password)  -> do
>   mpn <- liftRouteT $ liftIO $ newPlayerWeb login password
>   case mpn of
>  Just pn -> do
>     link <- showURL $ Noop pn
>     seeOther link $ string "Redirecting..."
>  Nothing -> seeOther ("/Login?status=fail" :: String) $ string
> "Redirecting..."
>
> launchWebServer :: ServerHandle -> IO ()
> launchWebServer sh = do
>    putStrLn "Starting web server...\nTo connect, drive your browser to
> \"http://localhost:8000/Login\"";
>    simpleHTTP nullConf $ implSite "http://localhost:8000/"; "" (nomicSite sh)
>
>
> But when I drive my browser to "http://localhost:8000/Login/";, happstack
> tell me there is nothing here.
> Am I doing it right? If yes, I must have made a mistake.
> (as you can see I'm still far from putting in disgestive functors ;)
>
> If you need, the complete application can be found here (see file Web.hs):
> https://github.com/cdupont/Nomic
>
> Thanks,
> Corentin
>
> On Wed, Jan 19, 2011 at 5:12 PM, Corentin Dupont 
> wrote:
>>
>> Thanks Jeremy.
>> I had it to work now ;)
>>
>> Corentin
>>
>> On Tue, Jan 18, 2011 at 6:01 PM, Jeremy Shaw  wrote:
>>>
>>> Hello,
>>>
>>>

Re: [Haskell-cafe] Problem on overlapping instances

2011-01-05 Thread Jasper Van der Jeugt
Hello,

{-# LANGUAGE OverlappingInstances, FlexibleInstances #-}
import Data.Binary

instance Binary [String] where
get = undefined
put = undefined

works fine here on GHC 6.12.3. That being said, it would be safer
perhaps to add a newtype around [String] so you can avoid the orphan
instance as well, i.e.

import Data.Binary

newtype MyType = MyType [String]

instance Binary MyType where
get = undefined
put = undefined

Cheers,
Jasper

On Wed, Jan 5, 2011 at 9:24 AM, Magicloud Magiclouds
 wrote:
> Hi,
>  I am using Data.Binary which defined "instance Binary a => Binary
> [a]". Now I need to define "instance Binary [String]" to make
> something special for string list.
>  How to make it work? I looked into the chapter of
> overlappinginstances, nothing works.
> --
> 竹密岂妨流水过
> 山高哪阻野云飞
>
> ___
> Haskell-Cafe mailing list
> Haskell-Cafe@haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] ANN: Digestive functors 0.0.2.0

2010-12-10 Thread Jasper Van der Jeugt
Hello,

Thanks for the error report. Is blaze-html installed correctly? Could
you cabal install blaze-html and verify that you can import Text.Blaze
in ghci?

Cheers,
Jasper

On Fri, Dec 10, 2010 at 5:07 PM, Larry Evans  wrote:
> On 12/09/10 16:46, Jasper Van der Jeugt wrote:
>> Hello all,
>>
>> I'm very glad to announce the 0.0.2.0 release of the digestive
>> functors library. The library provides a general API to input
>> consumption, and is an upgrade of formlets.
>>
>> I've written an announcing blogpost and tutorial with more information here:
>>
>> http://jaspervdj.be/posts/2010-12-09-digestive-functors-0.0.2.html
>>
>
> Hi jasper.
>
> Following the instructions on the .html page, I did:
>
>    cabal update
>    cabal install snap-server
>    cabal install digestive-functors-blaze
>    cabal install digestive-functors-snap
>
> However, when I tried:
>
>  runghc -v 2010-12-09-digestive-functors-0.0.2.lhs
>
> I got:
>
> --{--cut here--
>
> *** Chasing dependencies:
> Chasing modules from: *2010-12-09-digestive-functors-0.0.2.lhs
> Created temporary directory: /tmp/ghc7611_0
> *** Literate pre-processor:
> /usr/lib/ghc-6.12.1/unlit -h 2010-12-09-digestive-functors-0.0.2.lhs
> 2010-12-09-digestive-functors-0.0.2.lhs /tmp/ghc7611_0/ghc7611_0.lpp
>
> 2010-12-09-digestive-functors-0.0.2.lhs:15:9:
>    Could not find module `Text.Digestive.Blaze.Html5':
>      locations searched:
>        Text/Digestive/Blaze/Html5.hs
>        Text/Digestive/Blaze/Html5.lhs
> Failed, modules loaded: none.
> *** Deleting temp files:
> Deleting: /tmp/ghc7611_0/ghc7611_0.lpp
>
> --}--cut here--
>
>  In directory:
>
> /home/evansl/.cabal/lib/digestive-functors-blaze-0.0.2.0/ghc-6.12.1/Text/Digestive/Blaze
>
>  there is:
>
>  -rw-r--r-- 1 evansl evansl 13984 Dec 10 09:18 Html5.hi
>
> Please, what should I do?
>
> -regards,
> Larry
>
>
>
> ___
> Haskell-Cafe mailing list
> Haskell-Cafe@haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: Digestive functors 0.0.2.0

2010-12-09 Thread Jasper Van der Jeugt
Hello all,

I'm very glad to announce the 0.0.2.0 release of the digestive
functors library. The library provides a general API to input
consumption, and is an upgrade of formlets.

I've written an announcing blogpost and tutorial with more information here:

http://jaspervdj.be/posts/2010-12-09-digestive-functors-0.0.2.html

You can get it on hackage here:

http://hackage.haskell.org/package/digestive-functors

As always, all feedback is welcome.

Kindest regards,
Jasper Van der Jeugt

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Reminder: BelHac: A Hackathon in Belgium, 5-7 November

2010-10-08 Thread Jasper Van der Jeugt
Hello all,

We would like to remind you of BelHac, an international Hackathon
taking place in Ghent, Belgium next month.

All details are available on this wiki page [1]. You can register here [2].

WHEN

Friday November 5: 2pm - 7pm
Saturday November 6: 10am - 6pm
Sunday November 7: 10am - 6pm

WHERE

In “The Therminal”, in Ghent, Belgium. Please see the wiki [1] for more details!

SPONSORS

Well-Typed: http://well-typed.com/
O’Reilly: http://oreilly.com/
Incubaid: http://incubaid.com/

We hope to see you in Belgium!

[1]: 
http://www.haskell.org/haskellwiki/Ghent_Functional_Programming_Group/BelHac
[2]: 
http://www.haskell.org/haskellwiki/Ghent_Functional_Programming_Group/BelHac/Register

On behalf of the GhentFPG organizing committee,
Kind regards,
Jasper Van der Jeugt
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Web application framework comparison?

2010-09-27 Thread Jasper Van der Jeugt
Hey Dave,

You should check out this page (if you haven't already):
http://haskell.org/haskellwiki/Web

Cheers,
Jasper

On Sun, Sep 26, 2010 at 8:41 PM, Dave Hinton  wrote:
> There are 179 packages in the Web category on Hackage.
>
> It am finding it difficult, as someone who is not familiar with any of
> the Haskell web application frameworks on Hackage (and there seem to
> be at least 9), to determine which are good quality, which do things I
> would like a web framework to do for me, and which insist on doing
> things I would rather do myself.
>
> Is there a page comparing the major frameworks somewhere? I've been
> unable to find one via Google.
> ___
> Haskell-Cafe mailing list
> Haskell-Cafe@haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: blaze-builder 0.1

2010-08-05 Thread Jasper Van der Jeugt
Dear all,

I have just released a package called blaze-builder on Hackage. It is
basically a builder monoid supporting fast string concatenation. It
was originally written for the blaze-html package, but because we
thought it could be useful elsewhere as well, we are releasing it as a
separate package.

Here is a blogpost with more information:
http://jaspervdj.be/posts/2010-08-05-blaze-builder.html
And here is the Hackage link: http://hackage.haskell.org/package/blaze-builder

All feedback is welcome,
Kind regards,
Jasper Van der Jeugt
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] BelHac: A Hackaton in Belgium, 5-7 November

2010-07-20 Thread Jasper Van der Jeugt
Hello all,

We are very pleased to officially announce an international
Hackaton/Get-together in Ghent, Belgium, on 5, 6 and 7 November 2010.

If you are interested in attending, we have put some information on
the wiki [1]. We will soon put up more details about transportation,
accommodation and food. (And Belgian beer, of course!) You can
register here [2].

WHEN

Friday November 5: 2pm - 7pm
Saturday November 6: 10am - 6pm
Sunday November 7: 10am - 6pm

WHERE

In “The Therminal”, in Ghent, Belgium. Please see the wiki [1] for more details.

We hope to see you in Belgium!

[1]: 
http://www.haskell.org/haskellwiki/Ghent_Functional_Programming_Group/BelHac
[2]: 
http://www.haskell.org/haskellwiki/Ghent_Functional_Programming_Group/BelHac/Register

On behalf of the GhentFPG organizing committee,
Kind regards,
Jasper Van der Jeugt
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] ANN: BlazeHtml 0.1

2010-06-19 Thread Jasper Van der Jeugt
Hey Chris,

Here's an start [1]. However, I'm quite sure the type signature of
`blazeTemplate` is not really what you want, since you have no access
to the snap environment that way. Hence, I'm looking forward to see
your solution :-)

[1]: 
http://github.com/jaspervdj/BlazeHtml/blob/develop/doc/examples/SnapFramework.hs

Kind regards,
Jasper Van der Jeugt

On Sat, Jun 19, 2010 at 1:53 PM, Christopher Done
 wrote:
> On 19 June 2010 12:50, Jasper Van der Jeugt  wrote:
>> Hello all,
>>
>> In light of Google Summer of Code, we are proud to release the first
>> version of BlazeHtml today. It's a 0.1 release, so beware of bugs!
>> Nevertheless, we encourage you to try it out. You can find more
>> information:
>
> Hurrah! I will use it in my next web project at work. Sounds good to
> try with Snap. If I need to make any patches I'll contribute. Thanks
> for your work!
>
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: BlazeHtml 0.1

2010-06-19 Thread Jasper Van der Jeugt
Hello all,

In light of Google Summer of Code, we are proud to release the first
version of BlazeHtml today. It's a 0.1 release, so beware of bugs!
Nevertheless, we encourage you to try it out. You can find more
information:

- On the website: http://jaspervdj.be/blaze
- On hackage: http://hackage.haskell.org/package/blaze-html-0.1
- In this blogpost: http://jaspervdj.be/posts/2010-06-20-blazehtml-0.1.html

Looking forward to your feedback,
Kind regards,
Jasper Van der Jeugt
Simon Meier
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [web-devel] Re: [Haskell-cafe] Google Summer of Code: BlazeHTML RFC

2010-06-03 Thread Jasper Van der Jeugt
On Thu, May 27, 2010 at 8:31 PM, Matt Parker  wrote:
> will it be possible to easily interleave IO values into the HTML? like
> instead of the [1,2,3]
>
> ul $ forM_ [1, 2, 3] (li . string . show)
>
> what if it was a function that returned IO [1,2,3] (maybe 1,2,3 came out of
> a database). will the forM_ handle that OK?

Depends on how you write the code. More precisely, it depends on in
which monad the forM_ takes place. Also, I would not recommend
interleaving IO values into the HTML, because the HTML is pure -- you
usually don't want to mix that with IO. I'd rather write something
like:

numbers <- getFromDataBase
return $ ul $ forM_ numbers (li . string . show)

Or it could be possible to store your templates in a separate modules,
and they would all have a pure type signature:

templateX :: Arg1 -> Arg2 -> Html a

I think this would be the preferred way, because it allows a
separation between the pure View code and the IO-interleaved
Controller code in a web application.

Kind regards,
Jasper Van der Jeugt

On Thu, May 27, 2010 at 8:31 PM, Matt Parker  wrote:
> will it be possible to easily interleave IO values into the HTML? like
> instead of the [1,2,3]
>
> ul $ forM_ [1, 2, 3] (li . string . show)
>
> what if it was a function that returned IO [1,2,3] (maybe 1,2,3 came out of
> a database). will the forM_ handle that OK?
>
>
> On Thu, May 27, 2010 at 12:19 PM, Matt Parker 
> wrote:
>>
>> Blaze HTML looks wonderful to me (especially with the do notation), and
>> better then Hamlet for one reason: writing idiomatic haskell for stuff like
>> this:
>>
>> ul $ forM_ [1, 2, 3] (li . string . show)
>>
>> instead of the Hamlet style:
>>
>> %ul
>>   $forall children.person child
>> %li $child$
>>
>> which, i don't know, for some reason, made me feel like i was back in PHP
>> land.
>>
>> -matt
>>
>>
>> On Thu, May 27, 2010 at 7:08 AM, Alberto G. Corona 
>> wrote:
>>>
>>> As a user, I have too many HTML generators, a few of them with Ajax and
>>> none with server-side event handling (like ASPX or JSPX).  Ajax is
>>> complicated but server side event handling is  what I really miss because it
>>> is simple  from the user point of view, my ervents could be handled in
>>> haskell code rather than in javaScript and I  implicitly could  use the
>>> advantages of  dinamic HTML and Ajax without the need to know them at all.
>>> Imagine a dynamic Web application  with 100% haskell code made with
>>> dynamic widgets created by third party developers.
>>> So, anyone want to create a HTML templating system with server side event
>>> handling? It is not terribly hard to do. (I refer to ASP.NET documentation
>>> or the JavaServer Faces framework).
>>> By the way, I vote for XML templating or else, combinator templating that
>>> produce XHML templating because it can be handled by a future graphical IDE.
>>>
>>> 2010/5/27 Jasper Van der Jeugt 
>>>>
>>>> Hey Bas,
>>>>
>>>> > How about also providing an enumerator back-end?
>>>> >
>>>> > http://hackage.haskell.org/packages/archive/iteratee/0.3.5/doc/html/Data-Iteratee-Base.html#t%3AEnumeratorGM
>>>> >
>>>> > Then your library can integrate more easily with the snap framework:
>>>> > http://snapframework.com
>>>>
>>>> Sure, I can do that. But I already tested integration with the snap
>>>> framework, the best path here seems to call the `writeLBS` function
>>>> from the snap framework on the `L.ByteString` that BlazeHtml produces
>>>> (`writeLBS` internally uses an enumerator).
>>>>
>>>> Kind regards,
>>>> Jasper Van der Jeugt
>>>>
>>>> On Thu, May 27, 2010 at 10:38 AM, Bas van Dijk 
>>>> wrote:
>>>> > Q14: Do you see any problems with respect to integrating BlazeHtml in
>>>> > your favourite web-framework/server?
>>>> >
>>>> > How about also providing an enumerator back-end?
>>>> >
>>>> > http://hackage.haskell.org/packages/archive/iteratee/0.3.5/doc/html/Data-Iteratee-Base.html#t%3AEnumeratorGM
>>>> >
>>>> > Then your library can integrate more easily with the snap framework:
>>>> > http://snapframework.com
>>>> >
>>>> > Regards,
>>>> >
>>>> > Bas
>>>> >
>>>> ___
>>>> Haskell-Cafe mailing list
>>>> Haskell-Cafe@haskell.org
>>>> http://www.haskell.org/mailman/listinfo/haskell-cafe
>>>
>>>
>>> ___
>>> web-devel mailing list
>>> web-de...@haskell.org
>>> http://www.haskell.org/mailman/listinfo/web-devel
>>>
>>
>
>
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: [web-devel] Google Summer of Code: BlazeHTML RFC

2010-06-02 Thread Jasper Van der Jeugt
On Sat, May 29, 2010 at 7:34 PM, Matt Parker  wrote:
>
>> Q3: Which HTML version would you preferably use?
>
> HTML 5. google summer of code should be about pushing the new and exciting.

I can say that HTML 5 will definitely be supported. We use some sort
of metacode to generate Haskell combinators from a simple, formal HTML
specification. Thus, it should be possible to support HTML 5, HTML 4
Strict and HTML 4 Transitional easily.

Kind regards,
Jasper Van der Jeugt
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: [web-devel] Google Summer of Code: BlazeHTML RFC

2010-05-30 Thread Jasper Van der Jeugt
Hey Thomas,

Yes, hsx/hsp could get a performance gain by using BlazeHtml as a
backend. However, I'm not sure if it is possible to change the backend
without changing the user API (but I do hope so).

Kind regards,
Jasper Van der Jeugt

On Sun, May 30, 2010 at 5:58 PM, Thomas Hartman  wrote:
> I'm a heavy hsp user. Could hsp benefit from this project by using
> blaze as a back end instead of whatever it's using now?
>
> IIUC, Hsp uses hsx (via the preprocessor program trhsx) to convert
> xml-containing hybrid hsp/xml/html files into compilable haskell.
>
> I expected hsx uses XHTML (which iiuc is what blaze would replace) on
> the backend but I don't see it listed in the dependencies at
>
> http://hackage.haskell.org/package/hsx-0.7.0
>
> so I guess it doesn't and uses something internal rather than xhtml. (Right?)
>
> My question as regards BlazeHTML is if there could be any performance
> win/tie in for the hsp/hsx toolchain.
>
> FWIW, wrt to blaze sclv commented on reddit "The idea is rather that
> this would be a replacement for the html combinator library, as
> distinct from templating (hamlet, hstringtemplate, bravo, chunks,
> press, & co) and as distinct from the *sp model of inlined code (hsp).
>
> Edit: Ideally, and generally for Haskell libs, the choices of
> persistence layer, html generation library, dispatch model, and server
> layer are largely orthogonal. Strong typing makes any ad-hoc plumbing
> a breeze."
>
> http://www.reddit.com/r/haskell/comments/bxa0a/blazehtml_a_blazingly_fast_html_combinator/
>
> thomas.
>
> 2010/5/30 Tom Lokhorst :
>> +1 for HTML5.
>>
>> Also, I suggest focussing on the html serialization of HTML5.
>>
>> The xml serialization (XHTML5) is only useful in an XML environment.
>> For such environments pure xml libraries are more appropriate.
>>
>> Besides, I like html syntax better.
>>
>> On 30 May 2010 16:27, Jochem Berndsen  wrote:
>>> On 05/29/2010 08:05 PM, Gregory Collins wrote:
>>>>
>>>> Matt Parker  writes:
>>>>
>>>>>     Q3: Which HTML version would you preferably use?
>>>>>
>>>>> HTML 5. google summer of code should be about pushing the new and
>>>>> exciting.
>>>>
>>>> Yes, definitely, this should be the default IMO.
>>>
>>> +1
>>>
>>>
>>> --
>>> Jochem Berndsen | joc...@functor.nl
>>> ___
>>> Haskell-Cafe mailing list
>>> Haskell-Cafe@haskell.org
>>> http://www.haskell.org/mailman/listinfo/haskell-cafe
>>>
>> ___
>> Haskell-Cafe mailing list
>> Haskell-Cafe@haskell.org
>> http://www.haskell.org/mailman/listinfo/haskell-cafe
>>
> ___
> Haskell-Cafe mailing list
> Haskell-Cafe@haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Google Summer of Code: BlazeHTML RFC

2010-05-27 Thread Jasper Van der Jeugt
Hey Bas,

> How about also providing an enumerator back-end?
> http://hackage.haskell.org/packages/archive/iteratee/0.3.5/doc/html/Data-Iteratee-Base.html#t%3AEnumeratorGM
>
> Then your library can integrate more easily with the snap framework:
> http://snapframework.com

Sure, I can do that. But I already tested integration with the snap
framework, the best path here seems to call the `writeLBS` function
from the snap framework on the `L.ByteString` that BlazeHtml produces
(`writeLBS` internally uses an enumerator).

Kind regards,
Jasper Van der Jeugt

On Thu, May 27, 2010 at 10:38 AM, Bas van Dijk  wrote:
> Q14: Do you see any problems with respect to integrating BlazeHtml in
> your favourite web-framework/server?
>
> How about also providing an enumerator back-end?
> http://hackage.haskell.org/packages/archive/iteratee/0.3.5/doc/html/Data-Iteratee-Base.html#t%3AEnumeratorGM
>
> Then your library can integrate more easily with the snap framework:
> http://snapframework.com
>
> Regards,
>
> Bas
>
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Google Summer of Code: BlazeHTML RFC

2010-05-27 Thread Jasper Van der Jeugt
Dear all,

BlazeHtml started out on ZuriHac 2010. Now, Jasper Van der Jeugt is
working on it as a student to Google Summer of Code for haskell.org.
His mentors are Simon Meier and Johan Tibell. The goal is to create a
high-performance HTML generation library.

In the past few weeks, we have been exploring the performance and
design of different drafts of this library. Now, the time has come to
ask some questions to the Haskell community — more specifically the
future users of BlazeHtml as well as current users of other HTML
generation libraries.

We have written an RFC to gather feedback from the community:

HTML version: http://jaspervdj.be/posts/2010-05-27-blazehtml-rfc.html
Plain version: http://github.com/jaspervdj/BlazeHtml/raw/develop/doc/RFC.lhs

The easiest way of sending us feedback, comments or criticism is
replying to the haskell-cafe thread here. Alternatively, drop a
comment at the bottom of the HTML version or at reddit.

Looking forward to your feedback,
Kind regards,
Simon Meier
Jasper Van der Jeugt
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: Hakyll-2.0

2010-03-31 Thread Jasper Van der Jeugt
Hello,

On this spring day I would like to announce the 2.0 release of
Hakyll[1], the static site generator. It is a rewrite, changes the API
for the better and introduces some new features. A brief changelog:

- Rewrite of the codebase to a clean, arrow based API.
- Pagination was added.
- Built-in functions to generate RSS and Atom.
- Many bugfixes.
- New tutorials added.

Of course, all feedback is welcome.

Kind regards,
Jasper Van der Jeugt

[1]: http://jaspervdj.be/hakyll
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: hakyll-1.3

2010-01-30 Thread Jasper Van der Jeugt
Hello,
Today I'd like to announce the release of hakyll-1.3.
Changes since 1.2:
- Categories were added (as opposed to tags). You can find some
information in this tutorial[1].
- createListing and createListingWith functions were added, as a way
of having a more high-level way to create listings. All tutorials have
been updated to work with listings now, a short explanation is
available here[2]. In short, this basically replaces the old and
verbose renderAndConcat/createCustomPage workflow.

Changes since 1.1:
- Rewrote caching system.
- Rewrote templating system.
- 4x speed improvement, mostly because of the Data.Binary library.

You can get the latest version from hackage[3]. All
feedback/criticism/comments are welcome.

Kind regards,
Jasper Van der Jeugt

[1]: http://jaspervdj.be/hakyll/tutorial6.html
[2]: http://jaspervdj.be/hakyll/tutorial3.html#custom-pages
[3]: http://hackage.haskell.org/package/hakyll
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: hakyll-1.0

2010-01-14 Thread Jasper Van der Jeugt
Hello,

I have just released hakyll[1] 1.0. It is now available on hackage[2].
This is considered a first stable release (hence 1.0), and pretty it
is functional.

Hakyll is a Haskell library for generating static sites. It is written
in a very configurable way and uses an xmonad-like DSL for
configuration.

Important changes:
- Switched from the template library to a custom template system,
because we needed some more flexibility, but not quite as much as
something like HStringTemplate would give.
- Switched from inconsistent String/ByteString usage to String only
for the external API.
- Added a $root system so it is easy to work with relative/absolute URL's.
- Many bugfixes.
- More documentation and a reference are online now.

All feedback and questions are welcome.

Kind regards,
Jasper Van der Jeugt

[1]: http://jaspervdj.be/hakyll
[2]: http://hackage.haskell.org/package/hakyll
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: hakyll-0.4

2010-01-08 Thread Jasper Van der Jeugt
Hello,

I am announcing the release of hakyll-0.4. Hakyll is a static site generator
library written Haskell. It is written in a very configurable way and uses
an xmonad-like DSL for configuration. Notable changes since the last big
release (0.1) include:

- CSS compression
- Dependency handling (aka. not generate everything again every time)
- A simple http server for previewing your site
- Speed improvements and bug fixes
- Several specialized functions for dealing with dates, tags...
- Abstraction of context manipulations
- Some tutorials are added and documentation is mostly complete
- Example sites were added

More information can be found at
http://jaspervdj.be/hakyll
All feedback is welcome.

Kind regards,
Jasper Van der Jeugt
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] A question on DSL's

2010-01-04 Thread Jasper Van der Jeugt
Hello,

I see no real reason to use the second approach, unless you're doing
something tremendously new and big. Besides, the first solution is much
easier and will be easier to maintain (in case the back end changes).

Kind regards,
Jasper Van der Jeugt

On Mon, Jan 4, 2010 at 6:14 PM, CK Kashyap  wrote:

> Hi,
> I am not sure if I'm using DSL in the right context here but I am referring
> to those solutions that allow us to write code in Haskell and generate a
> target code source code of another language or even object code for that
> matter. I am aware of two ways of achieving this -
> 1. Implement functions that emit the target code - that is, when the
> Haskell code is compiled and run, the target code is emitted
> 2. Modify the Haskell compiler's back end to emit the code - that is when
> the Haskell code is compiled the target code is emitted
>
> I am not sure if there are more ways (hybrid perhaps) ...
>
> My question is,  when would I chose one approach over the other?
>
> Regards,
> Kashyap
>
>
>
>
>
> ___
> Haskell-Cafe mailing list
> Haskell-Cafe@haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] ANN: hakyll-0.1

2009-12-07 Thread Jasper Van der Jeugt
Okay,

You're right. I will change the license info as soon as possible.

Kind regards,
Jasper Van der Jeugt

On Dec 8, 2009 6:30 AM, "Tom Tobin"  wrote:

On Sat, Dec 5, 2009 at 6:35 AM, Jasper van der Jeugt 
wrote: > Hakyll is a simp...
I hate to say this, but it looks like you're violating the GPL by not
releasing Hakyll under the GPL, since Pandoc is GPL'd.  I don't think
you're alone in this — IIRC I've seen several Hackage libraries doing
the same thing.

I *really* wish Pandoc would switch to a non-copyleft license.
(Pretty please, with sugar and cherries on top?)  I know that GPL
authors are trying to enforce contributions, but the opposite can very
well happen: if you have an "essential" copyleft library, someone's
eventually going to write a non-copyleft replacement for it (e.g.,
witness the replacements for Readline) rather than continue to allow
it to restrict the licensing options of the community.  Great
libraries should be able to be embraced without reservations.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] ANN: hakyll-0.1

2009-12-05 Thread Jasper van der Jeugt

Hello all,

Hakyll is a simple static site generator library, mostly aimed at blogs. 
It supports markdown, tex and html templates.


It is inspired by the ruby Jekyll program. It has a very small codebase 
because it makes extensive use of the excellent pandoc and Text.Template 
libraries.


More information can be found on:
http://hackage.haskell.org/package/hakyll-0.1
http://github.com/jaspervdj/Hakyll

Kind regards,
Jasper Van der Jeugt
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe