diff --git a/resource/template/LISP-ASDF/TEMPLATE-TEXT b/resource/template/LISP-ASDF/TEMPLATE-TEXT index cbbe404..b841821 100644 --- a/resource/template/LISP-ASDF/TEMPLATE-TEXT +++ b/resource/template/LISP-ASDF/TEMPLATE-TEXT @@ -12,22 +12,34 @@ :description "${PROJECT_DESCRIPTION}" :author "${COPYRIGHT_HOLDER}" :license "${LICENSE_NAME}" - :depends-on (:alexandria) + :depends-on (#:alexandria) :components ((:module "src" - :components ((:file "package") - (:file "utilities") - (:file "entrypoint"))))) + :components ((:file "package") + (:file "utilities") + (:file "entrypoint"))))) (asdf:defsystem #:${LISP_TEST_SYSTEM_NAME} :description "${PROJECT_DESCRIPTION}" :author "${COPYRIGHT_HOLDER}" :license "${LICENSE_NAME}" - :depends-on (:alexandria :org.melusina.confidence :${LISP_SYSTEM_NAME}) + :depends-on (#:alexandria + #:org.melusina.confidence + #:${LISP_SYSTEM_NAME}) :components ((:module "testsuite" :components ((:file "package") (:file "utilities") (:file "entrypoint"))))) +(asdf:defsystem #:${LISP_SYSTEM_NAME}/development + :description "Development tools for ${PROJECT_NAME}" + :author "${COPYRIGHT_HOLDER}" + :license "${LICENSE_NAME}" + :depends-on (#:alexandria + #:org.melusina.atelier) + :components + ((:module "libexec/lisp" + :components ((:file "development"))))) + ;;;; End of file `${FILENAME}' diff --git a/resource/template/LISP-DEVELOPMENT/TEMPLATE-NAME b/resource/template/LISP-DEVELOPMENT/TEMPLATE-NAME new file mode 100644 index 0000000..482c05b --- /dev/null +++ b/resource/template/LISP-DEVELOPMENT/TEMPLATE-NAME @@ -0,0 +1 @@ +Lisp development file diff --git a/resource/template/LISP-DEVELOPMENT/TEMPLATE-TEXT b/resource/template/LISP-DEVELOPMENT/TEMPLATE-TEXT new file mode 100644 index 0000000..4b0f38a --- /dev/null +++ b/resource/template/LISP-DEVELOPMENT/TEMPLATE-TEXT @@ -0,0 +1,62 @@ +;;;; ${FILENAME} — ${SUMMARY} + +;;;; ${PROJECT_NAME} (${HOMEPAGE}) +;;;; This file is part of ${PROJECT_NAME}. +;;;; +;;;; Copyright © ${COPYRIGHT_YEAR} ${COPYRIGHT_HOLDER} +;;;; All rights reserved. + +;;;; ${LICENSE_HEADER} + +(defpackage #:${LISP_SYSTEM_NAME}/development + (:use #:common-lisp) + (:export + #:lint + #+quicklisp + #:reload)) + +(in-package #:${LISP_SYSTEM_NAME}/development) + +(defun system-relative-pathname (&rest pathnames) + (labels ((system-source-directory () + (asdf:system-source-directory #.(string-downcase (package-name *package*)))) + (merge-one (pathname) + (merge-pathnames pathname (system-source-directory)))) + (mapcar #'merge-one pathnames))) + +(defparameter *parameter-bindings* + '((:copyright-holder . "${COPYRIGHT_HOLDER}") + (:copyright-year . "${COPYRIGHT_YEAR}") + (:project-filename . "${PROJECT_FILENAME}") + (:project-name . "${PROJECT_NAME}") + (:project-description . "${PROJECT_DESCRIPTION}") + (:project-long-description . "${PROJECT_LONG_DESCRIPTION}") + (:homepage . "${HOMEPAGE}") + (:license . :${LICENSE_ID}))) + +(defun lint () + (let ((atelier:*parameter-bindings* *parameter-bindings*)) + (atelier:lint + (system-relative-pathname + #p"${PROJECT_FILENAME}.asd" + #p"development" + #p"doc" + #p"src" + #p"testsuite" + #p"libexec/lisp/development.lisp")))) + +#+quicklisp +(defun reload () + (ql:quickload '("${LISP_SYSTEM_NAME}" + "${LISP_SYSTEM_NAME}/testsuite" + "${LISP_SYSTEM_NAME}/development"))) + + +;;;; +;;;; Command Stock +;;;; + +#+nil +(${LISP_SYSTEM_NAME}/development:reload) + +;;;; End of file `${FILENAME}' diff --git a/resource/template/LISP-SETUP/TEMPLATE-NAME b/resource/template/LISP-SETUP/TEMPLATE-NAME deleted file mode 100644 index d3f4620..0000000 --- a/resource/template/LISP-SETUP/TEMPLATE-NAME +++ /dev/null @@ -1 +0,0 @@ -Lisp setup file diff --git a/resource/template/LISP-SETUP/TEMPLATE-TEXT b/resource/template/LISP-SETUP/TEMPLATE-TEXT deleted file mode 100644 index 87683d3..0000000 --- a/resource/template/LISP-SETUP/TEMPLATE-TEXT +++ /dev/null @@ -1,29 +0,0 @@ -;;;; ${FILENAME} — ${SUMMARY} - -;;;; ${PROJECT_NAME} (${HOMEPAGE}) -;;;; This file is part of ${PROJECT_NAME}. -;;;; -;;;; Copyright © ${COPYRIGHT_YEAR} ${COPYRIGHT_HOLDER} -;;;; All rights reserved. - -;;;; ${LICENSE_HEADER} - -(in-package #:cl-user) - -;;; -;;; Atelier -;;; - -(ql:quickload "org.melusina.atelier" :silent t) - -(setf org.melusina.atelier:*parameter-bindings* - '((:copyright-holder . "${COPYRIGHT_HOLDER}") - (:copyright-year . "${COPYRIGHT_YEAR}") - (:project-filename . "${PROJECT_FILENAME}") - (:project-name . "${PROJECT_NAME}") - (:project-description . "${PROJECT_DESCRIPTION}") - (:project-long-description . "${PROJECT_LONG_DESCRIPTION}") - (:homepage . "${HOMEPAGE}") - (:license . :${LICENSE_ID}))) - -;;;; End of file `${FILENAME}' diff --git a/src/template.lisp b/src/template.lisp index 78b717a..c98ddd2 100644 --- a/src/template.lisp +++ b/src/template.lisp @@ -294,8 +294,8 @@ and the testsuite: package definition, utilities and entrypoints." :template-list ((:lisp-asdf #p"${PROJECT_FILENAME}.asd" ((:summary . "System definition for ${PROJECT_NAME}"))) - (:lisp-setup #p"libexec/lisp/setup.lisp" - ((:summary . "Project setup for ${PROJECT_NAME}"))) + (:lisp-development #p"libexec/lisp/development.lisp" + ((:summary . "Development System for ${PROJECT_NAME}"))) (:lisp-docstrings #p"libexec/lisp/docstrings.lisp") (:lisp-package #p"src/package.lisp" ((:summary . "Package for ${PROJECT_NAME}")))