The quickapp Reference Manual

Table of Contents

Next: , Previous: , Up: (dir)   [Contents][Index]

The quickapp Reference Manual

This is the quickapp Reference Manual, generated automatically by Declt version 2.3 "Robert April" on Wed Mar 14 04:29:20 2018 GMT+0.


Next: , Previous: , Up: Top   [Contents][Index]

1 Introduction

quickapp

Quicklisp

A common lisp project for generating template projects that use sbcl and buildapp

See https://github.com/triclops200/quickapp-cli for the command line standalone utility.

Example usage

(ql:quickload :quickapp)
(quickapp:quickapp
          "src/lisp/test-project"
          :project-name "test-project" 
          :executable-name "test.out" 
          :project-description "This is a sample test project" 
          :project-author "YOUR NAME HERE" 
          :dependencies '(:sdl2 :cl-openal))

This creates the needed files and Makefile as well as a template project.

For easy interactive development in slime, just do (assuming one is in their generated project directory):

(load "slime.lisp")
(in-package :<YOUR PACKAGE NAME>)

Arg parsing utilities

This library also contains two functions for dealing with argument handling for the generated application: (quickapp:parse-args) and (quickapp:generate-flag-string).

An example usage is shown below

(defun -main (&optional args)
  "Entry point"
  (let* ((arg-defs '(("h" "help" "Display this help menu")
	          ("d" "dependencies" "(:dep1 [:dep2 ...])" "The dependencies")
	          ("p" "project-name" "NAME" "The project name")
	          ("a" "project-author" "NAME" "The name of the author")
	          ("s" "project-description" "DESCRIPTION" "The project description")
	          ("e" "executable-name" "NAME" "The executable name")))
         (parsed-args (quickapp:parse-args arg-defs (cdr args))))
	  (if (or (/= (length (first parsed-args)) 1)
	          (assoc "help" (second parsed-args) :test #'string=))
		  (progn (format t "Usage: ~a PROJECT-PATH [OPTIONS]~%OPTIONS:~%~a~%~a~%~a~a~%~a~%~a~%"
			       (first args)
			       (quickapp:generate-flag-string arg-defs)
			       "Example Usage: " (first args) " test-project \\"
			       "  -d\"(:sdl2 :cl-opengl)\" \\"
			       "  --project-author=cluser"))
		  (format t "~a~%" parsed-args))))

Running that application with the --help flag results in:

Usage: ./quickapp PROJECT-PATH [OPTIONS]
OPTIONS:
  -h  --help                              Display this help menu
  -d  --dependencies=(:dep1 [:dep2 ...])  The dependencies
  -p  --project-name=NAME                 The project name
  -a  --project-author=NAME               The name of the author
  -s  --project-description=DESCRIPTION   The project description
  -e  --executable-name=NAME              The executable name

Example Usage: 
./quickapp test-project \
  -d"(:sdl2 :cl-opengl)" \
  --project-author=cluser

Running this command: ./quickapp test-project -d"(:sdl2 :cl-opengl)" --project-author=cluser results in this list returned as parsed-args

(("test-project")
 (("project-author" . "cluser") ("dependencies" . "(:sdl2 :cl-opengl)")))

#License Licensed under Modified BSD License.

See License.txt for more details.


Next: , Previous: , Up: Top   [Contents][Index]

2 Systems

The main system appears first, followed by any subsystem dependency.


Previous: , Up: Systems   [Contents][Index]

2.1 quickapp

Author

Bryan Hoyle

License

Modified BSD License

Description

A utility library to automate much of the app creation process

Source

quickapp.asd (file)

Components

Next: , Previous: , Up: Top   [Contents][Index]

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


Previous: , Up: Files   [Contents][Index]

3.1 Lisp


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.1 quickapp.asd

Location

quickapp.asd

Systems

quickapp (system)


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.2 quickapp/package.lisp

Parent

quickapp (system)

Location

package.lisp

Packages

quickapp


Next: , Previous: , Up: Lisp files   [Contents][Index]

3.1.3 quickapp/quickapp.lisp

Dependency

package.lisp (file)

Parent

quickapp (system)

Location

quickapp.lisp

Exported Definitions
Internal Definitions

Previous: , Up: Lisp files   [Contents][Index]

3.1.4 quickapp/argument-parsing.lisp

Dependency

quickapp.lisp (file)

Parent

quickapp (system)

Location

argument-parsing.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Top   [Contents][Index]

4 Packages

Packages are listed by definition order.


Previous: , Up: Packages   [Contents][Index]

4.1 quickapp

Source

package.lisp (file)

Use List

common-lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Top   [Contents][Index]

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


Next: , Previous: , Up: Definitions   [Contents][Index]

5.1 Exported definitions


Previous: , Up: Exported definitions   [Contents][Index]

5.1.1 Functions

Function: generate-flag-string ARG-DEFS

Generate the part of the help string that documents the options from the arg definition

Package

quickapp

Source

argument-parsing.lisp (file)

Function: get-dependencies ()
Package

quickapp

Source

quickapp.lisp (file)

Function: get-executable ()
Package

quickapp

Source

quickapp.lisp (file)

Function: get-project ()
Package

quickapp

Source

quickapp.lisp (file)

Function: get-project-author ()
Package

quickapp

Source

quickapp.lisp (file)

Function: get-project-description ()
Package

quickapp

Source

quickapp.lisp (file)

Function: get-utils ()
Package

quickapp

Source

quickapp.lisp (file)

Function: parse-args ARG-DEFS ARGS

Actually calls all the functions to parse the args into the correct form.

Package

quickapp

Source

argument-parsing.lisp (file)

Function: quickapp PROJECT-PATH &key PROJECT-NAME EXECUTABLE-NAME PROJECT-DESCRIPTION PROJECT-AUTHOR DEPENDENCIES

Create the project from the templates

Package

quickapp

Source

quickapp.lisp (file)


Previous: , Up: Definitions   [Contents][Index]

5.2 Internal definitions


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.1 Special variables

Special Variable: *executable-name*
Package

quickapp

Source

quickapp.lisp (file)

Special Variable: *my-directory*
Package

quickapp

Source

quickapp.lisp (file)

Special Variable: *project-author*
Package

quickapp

Source

quickapp.lisp (file)

Special Variable: *project-dependencies*
Package

quickapp

Source

quickapp.lisp (file)

Special Variable: *project-description*
Package

quickapp

Source

quickapp.lisp (file)

Special Variable: *project-name*
Package

quickapp

Source

quickapp.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

5.2.2 Macros

Macro: loop-rec BINDINGS &body BODY

Similar to the clojure loop macro

Package

quickapp

Source

argument-parsing.lisp (file)

Macro: with-string-stream STREAM &body BODY

A macro to allow one to write to a variable string stream and get the body result out

Package

quickapp

Source

argument-parsing.lisp (file)


Previous: , Up: Internal definitions   [Contents][Index]

5.2.3 Functions

Function: dispatch-stream-rewrite C1 C2 INPUT-STRING DISPATCH-FUNCTION
Package

quickapp

Source

quickapp.lisp (file)

Function: do-template PROJECT-PATH FILE &optional NAME
Package

quickapp

Source

quickapp.lisp (file)

Function: do-templates PROJECT-PATH TEMPLATES
Package

quickapp

Source

quickapp.lisp (file)

Function: eval-template-file FILE
Package

quickapp

Source

quickapp.lisp (file)

Function: eval-template-string STRING
Package

quickapp

Source

quickapp.lisp (file)

Function: fill-string STR FILL-CHAR N

Fill a string with a character until it is at least as long as n specifies

Package

quickapp

Source

argument-parsing.lisp (file)

Function: fix-argdef ARGDEF

This is a formatter for an argdef to display properly

Package

quickapp

Source

argument-parsing.lisp (file)

Function: fix-named-arg ARG-NAMES ARG

This unifies the named arguments to use the long form.

Package

quickapp

Source

argument-parsing.lisp (file)

Function: fix-named-args ARG-NAMES ARGS

Fix all of the named args to use the long form

Package

quickapp

Source

argument-parsing.lisp (file)

Function: from-my-path FILENAME
Package

quickapp

Source

quickapp.lisp (file)

Function: parse-arg ACC ARG-LIST

Parses one argument/argument pair into the named/unnamed lists appropriately

Package

quickapp

Source

argument-parsing.lisp (file)

Function: parse-unfixed-args ARGS

Parse an argument list into the appropriate list

Package

quickapp

Source

argument-parsing.lisp (file)

Function: reduce-full F &rest ARGS

A reducer that allows f to control the iteration as well as the accumulator

Package

quickapp

Source

argument-parsing.lisp (file)

Function: slurp-file FILENAME
Package

quickapp

Source

quickapp.lisp (file)

Function: spit-file FILENAME STRING
Package

quickapp

Source

quickapp.lisp (file)

Function: split-string SEPERATOR STR

Fully split a string by seperator.

Package

quickapp

Source

argument-parsing.lisp (file)

Function: split-string-first SEPERATOR STR &optional DEFAULT-VALUE

Returns a value pair representing the first split in the string matching the seperator string

Package

quickapp

Source

argument-parsing.lisp (file)

Function: subseq-rel SEQ FST &optional L

A relative subsequence function

Package

quickapp

Source

argument-parsing.lisp (file)


Previous: , Up: Top   [Contents][Index]

Appendix A Indexes


Next: , Previous: , Up: Indexes   [Contents][Index]

A.1 Concepts

Jump to:   F   L   Q  
Index Entry  Section

F
File, Lisp, quickapp.asd: The quickapp<dot>asd file
File, Lisp, quickapp/argument-parsing.lisp: The quickapp/argument-parsing<dot>lisp file
File, Lisp, quickapp/package.lisp: The quickapp/package<dot>lisp file
File, Lisp, quickapp/quickapp.lisp: The quickapp/quickapp<dot>lisp file

L
Lisp File, quickapp.asd: The quickapp<dot>asd file
Lisp File, quickapp/argument-parsing.lisp: The quickapp/argument-parsing<dot>lisp file
Lisp File, quickapp/package.lisp: The quickapp/package<dot>lisp file
Lisp File, quickapp/quickapp.lisp: The quickapp/quickapp<dot>lisp file

Q
quickapp.asd: The quickapp<dot>asd file
quickapp/argument-parsing.lisp: The quickapp/argument-parsing<dot>lisp file
quickapp/package.lisp: The quickapp/package<dot>lisp file
quickapp/quickapp.lisp: The quickapp/quickapp<dot>lisp file

Jump to:   F   L   Q  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.2 Functions

Jump to:   D   E   F   G   L   M   P   Q   R   S   W  
Index Entry  Section

D
dispatch-stream-rewrite: Internal functions
do-template: Internal functions
do-templates: Internal functions

E
eval-template-file: Internal functions
eval-template-string: Internal functions

F
fill-string: Internal functions
fix-argdef: Internal functions
fix-named-arg: Internal functions
fix-named-args: Internal functions
from-my-path: Internal functions
Function, dispatch-stream-rewrite: Internal functions
Function, do-template: Internal functions
Function, do-templates: Internal functions
Function, eval-template-file: Internal functions
Function, eval-template-string: Internal functions
Function, fill-string: Internal functions
Function, fix-argdef: Internal functions
Function, fix-named-arg: Internal functions
Function, fix-named-args: Internal functions
Function, from-my-path: Internal functions
Function, generate-flag-string: Exported functions
Function, get-dependencies: Exported functions
Function, get-executable: Exported functions
Function, get-project: Exported functions
Function, get-project-author: Exported functions
Function, get-project-description: Exported functions
Function, get-utils: Exported functions
Function, parse-arg: Internal functions
Function, parse-args: Exported functions
Function, parse-unfixed-args: Internal functions
Function, quickapp: Exported functions
Function, reduce-full: Internal functions
Function, slurp-file: Internal functions
Function, spit-file: Internal functions
Function, split-string: Internal functions
Function, split-string-first: Internal functions
Function, subseq-rel: Internal functions

G
generate-flag-string: Exported functions
get-dependencies: Exported functions
get-executable: Exported functions
get-project: Exported functions
get-project-author: Exported functions
get-project-description: Exported functions
get-utils: Exported functions

L
loop-rec: Internal macros

M
Macro, loop-rec: Internal macros
Macro, with-string-stream: Internal macros

P
parse-arg: Internal functions
parse-args: Exported functions
parse-unfixed-args: Internal functions

Q
quickapp: Exported functions

R
reduce-full: Internal functions

S
slurp-file: Internal functions
spit-file: Internal functions
split-string: Internal functions
split-string-first: Internal functions
subseq-rel: Internal functions

W
with-string-stream: Internal macros

Jump to:   D   E   F   G   L   M   P   Q   R   S   W  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.3 Variables

Jump to:   *  
S  
Index Entry  Section

*
*executable-name*: Internal special variables
*my-directory*: Internal special variables
*project-author*: Internal special variables
*project-dependencies*: Internal special variables
*project-description*: Internal special variables
*project-name*: Internal special variables

S
Special Variable, *executable-name*: Internal special variables
Special Variable, *my-directory*: Internal special variables
Special Variable, *project-author*: Internal special variables
Special Variable, *project-dependencies*: Internal special variables
Special Variable, *project-description*: Internal special variables
Special Variable, *project-name*: Internal special variables

Jump to:   *  
S  

Previous: , Up: Indexes   [Contents][Index]

A.4 Data types

Jump to:   P   Q   S  
Index Entry  Section

P
Package, quickapp: The quickapp package

Q
quickapp: The quickapp system
quickapp: The quickapp package

S
System, quickapp: The quickapp system

Jump to:   P   Q   S