A cookiecutter template for Common Lisp projects featuring:
uiop:command-line-arguments
). Proper parsing is left to do with a third-party library (clingon, unix-opts, defmain, adopt…).We are also shaping out a template for a web project, see cl-cookieweb.
NEW! 🎥 See our demo video: https://www.youtube.com/watch?v=XFc513MJjos
Create a new project. You'll be prompted to provide some basic information about your new project, which will then be auto-generated in the current working directory:
$ pip install cookiecutter $ cookiecutter https://github.com/vindarel/cl-cookieproject project_name [cookie-lisp-project]: repo_name [cookie-lisp-project]: description []: A test project version [0.0.1]: year [1984]: author [CL User]: me email [me@mail.com]: username [me]: Initialised empty Git repository in /home/vince/bacasable/lisp-projects/cookie-lisp-project/.git/
Run it straight away:
$ cd cookie-lisp-project $ sudo apt install rlwrap # a utility to bring readline keybindings and history to SBCL on the terminal. $ make run rlwrap sbcl --load run.lisp This is SBCL 2.0.10, an implementation of ANSI Common Lisp. More information about SBCL is available at <http://www.sbcl.org/>. SBCL is free software, provided as is, with absolutely no warranty. It is mostly in the public domain; some portions are provided under BSD-style licenses. See the CREDITS and COPYING files in the distribution for more information. To load "cffi": Load 1 ASDF system: cffi ; Loading "cffi" . To load "cookie-lisp-project": Load 1 ASDF system: cookie-lisp-project ; Loading "cookie-lisp-project" [package cookie-lisp-project] Hello from cookie-lisp-project! *
You can see the Hello
from the main
function, and we are given a Lisp REPL.
Build an executable:
$ make build […] [saving current Lisp image into /home/vince/bacasable/lisp-projects/cookie-lisp-project/cookie-lisp-project: writing 0 bytes from the read-only space at 0x50000000 writing 736 bytes from the static space at 0x50100000 writing 37060608 bytes from the dynamic space at 0x1000000000 writing 2154496 bytes from the immobile space at 0x50200000 writing 13910016 bytes from the immobile space at 0x52000000 done] $ ./cookie-lisp-project me Hello me from cookie-lisp-project! $ ./cookie-lisp-project -h Usage: cookie-lisp-project [name]
Build it with Roswell:
$ ros build roswell/cookie-lisp-project.ros
A binary is created in the roswell
directory.
Your users can install the application with:
$ ros install github_username/project_name
You can use command line options: https://cookiecutter.readthedocs.io/en/1.7.2/advanced/cli_options.html
--no-input
: do not prompt for parameters and only use cookiecutter.json file content --replay
: do not prompt for parameters and only use information entered previously -f, --overwrite-if-exists
: overwrite the contents of the output directory if it already exists -s, --skip-if-file-exists
: skip the files in the corresponding directories if they already exist -o, --output-dir
: where to output the generated project dir into --config-file
: user configuration fileThe first time you run cookiecutter
with a link to a GitHub repository, the skeleton is saved under ~/.cookiecutters/
. You can run the command for the second time with only the skeleton name:
cookiecutter cl-cookieproject
and:
rove
, the script returns the correct error code).internal-quit
in app-utils.lisp should be uiop:quit
asdf:make
or Roswell? (proove me wrong)Acknowledgement: we forked cookiecutter-cl.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4