3
4
Fork
You've already forked ingle
1
some conveniences for ningle
  • Common Lisp 100%
2026年03月28日 10:36:36 +01:00
conditions.lisp init 2025年02月17日 09:56:37 +01:00
docs.lisp docs no toc 2025年02月18日 09:54:53 +01:00
docs.org docs 2025年02月22日 10:28:40 +01:00
http-codes.lisp init 2025年02月17日 09:56:37 +01:00
http.lisp change default redirect to 302 :found 2025年02月22日 10:26:48 +01:00
ingle.asd more mime type and allowed ext funs 2025年02月21日 11:56:35 +01:00
jingle-licence.txt add jingle licence file 2025年02月19日 10:41:33 +01:00
mime-types.lisp more mime type and allowed ext funs 2025年02月21日 11:56:35 +01:00
package.lisp Export the get-params function 2026年03月25日 22:37:20 +00:00
params.lisp Added get-params to complement get-param 2026年03月25日 18:20:07 +00:00
readme.org readme 2025年03月03日 19:02:52 +01:00
utils.lisp write to file funs just take a full path, not file / dir 2025年02月21日 11:56:43 +01:00

ingle

Some convenience functions for use with ningle, the Common Lisp web microframework.

There's the jingle library, but I find it adds too many bells and whistles and does annoying things like foist a particular JSON library onto the user. That said, it's well documented and great to learn with, so check it out if you are coming to grips with ningle.

ingle has no bells to jingle, it just keeps you a little bit warm. It started out with me both building a few basic functions, and gathering useful things that others had shared on the ningle repo and elsewhere online.

a redirect function

  • from jingle

set/get flash messages

  • push-flash - push a str to ningle:*session* for flashing
  • get-flashes for rendering
  • not from jingle

request parameters handling

  • get-param convenience function, and
  • with-params macro for easy handling of ningle's request parameter alists
  • not from jingle

response macros

  • with-http-response and
  • with-json-response macros
  • both set response status and content-type
  • modified from jingle: don't assume we want to use a particular JSON library.

other code from jingle

  • handle requests and responses (headers, statuses)
  • handle http status codes

file wrangling

  • write-upload-to-file - save a file upload to disk
  • write-to-file - write stream to filename in directory
  • delete-file-in-dir - delete a file

other utilities

  • file-size-readable - get a human readable file size for a file
  • mod-time-readable - get a human readable last modified time for a file
  • format-date (WIP) - get a human readable date string from an encoded time number (currently only DD-MM-YYYY)
  • mime-type-verify - verify the MIME-type of a file, using magicffi.
  • exts-for-mime-type - return a list of extensions for given MIME-type.

also of interest

Apart from Jingle, there's also niglex, which overlaps with ingle.

https://github.com/defunkydrummer/ninglex

licence

jingle code has its own licence: jingle-licence.txt.

the rest is GPLv3.