EAZY-Project - Interactive Project Generator & Manager
This used to be a fork from cl-project@fukamachi, but since almost everything is rewritten and added very much of new features, I renamed it as a new library. It is focused on the interactive features.
Now quicklisp loadable:
Launching the menu from the shell
In order to use the library from the command line you have to install it from
$ ros install eazy-project $ eazy-project
~/.roswell/bin is in the
PATH. otherwise replace the second line with
ros exec eazy-project
On the command line:
$ eazy-project # launches the main menu. $ eazy-project <project name> # starts from the project creation submenu, with the project name already set.
;; Add this statement in your .sbclrc / .ccl-init.lisp (ql:quickload :eazy-project.autoload) ;; To launch a menu, enter "!". ;; This is a symbol-macrolet alias to (eazy-project:launch-menu). ;; symbol "!" is imported to CL-USER when eazy-project.autoload is loaded. ! ;; "!!" restores the saved lisp state (described later). !! ;; Otherwise load eazy-project and use !/!! with a package prefix (ql:quickload :eazy-project) eazy-project:!
Tutorial: Creating a project using templates
Assume you are creating a new project named "myproj". First, open the menu from a REPL or the command line.
(You are now in menu EP-MAIN.) What to do next? Here are current default configs: :SESSION.SYSTEMS = (... "fare-quasiquote") :SESSION.PACKAGE = "COMMON-LISP-USER" :LOCAL-REPOSITORY = #P"/mnt/video/guicho/repos/lisp/" :SKELETON-DIRECTORY = #P"/mnt/video/guicho/repos/lisp/eazy-project/skeleton" :AUTHOR = "Masataro Asai" :EMAIL = "firstname.lastname@example.org" :GIT = T :README-EXTENSION = "md" :SOURCE-DIR = "src" :TEST-DIR = "t" :TEST-SUBNAME = "test" :DELIMITER = "." :LICENSE = "LLGPL" :TEST = :FIVEAM [Condition of type EAZY-PROJECT:ASK] Restarts: 0: [SESSION] Save/Restore the currently loaded libraries 1: [CREATE-PROJECT] Create a new project. 2: [SET-GLOBAL] Modify these default values 3: [UP] Back to the section EP-MAIN. 4: [QUIT-SESSION] Quit this session. 5: [RETRY] Retry SLIME REPL evaluation request.
Noitice the several entries are already filled in, e.g.,
:AUTHOR "Masataro Asai"=,
They can be modified later in =SET-GLOBAL submenu. The similar interactive interface shows up. To select a submenu, enter the corresponding number for the restarts (0-5) or click on each menu (on Slime REPL).
If you are satisfied with these global configurations, then select
CREATE-PROJECT. A new menu shows up:
(You are now in menu CREATE-PROJECT.) Select and enter the information, then select 'CREATE'. Current global configuration: .... Current local configuration: (no configuration specified) [Condition of type EAZY-PROJECT:ASK] Restarts: 0: [CREATE] Create 1: [RESET-LOCAL-CONFIG] Reset the current local config 2: [ADD-LOCAL-DEPENDENCY] Add-Local-Dependency 3: [NAME] Name ...
In this submenu, you can further modify several project-local configurations. Those configurations are cleared each time you enter
NAMEto enter the name of the new project, now "myproj". (if you attempt to create a project without it, the generator complains and opens an interactive prompt).
- You can further add the dependencies in ADD-LOCAL-DEPENDENCY submenu.
- The project-local dependency is a dependency only for this project.
CREATE. It will set up the repository, initialize the repo with git (by default. It can be disabled) and load it.
Tutorial: Restore the Yesterday's Coding Environment
Save and restore the set of currently loaded libraries. In the main menu, select the
SESSION submenu. (The menu items below might not reflect the latest version)
(You are now in menu EP-MAIN.) What to do next? ... ... [Condition of type EAZY-PROJECT:ASK] Restarts: 0: [SESSION] Save/Restore the currently loaded libraries 1: [CREATE-PROJECT] Create a new project. 2: [SET-GLOBAL] Modify these default values 3: [UP] Back to the section EP-MAIN. 4: [QUIT-SESSION] Quit this session. 5: [RETRY] Retry SLIME REPL evaluation request.
(You are now in menu SESSION.) What to do next? [Condition of type EAZY-PROJECT:ASK] Restarts: 0: [TOGGLE-WATCH] Watch and automatically save the session 1: [ADD-DEFAULT-SYSTEM] Add-Default-System 2: [SAVE] Save the current loaded session 3: [ABORT] Return to sldb level 1. 4: [UP] Back to the section EP-MAIN. 5: [QUIT-MENU] Quit this eazy-project menu.
Then, SAVE or RESTORE the current session. SAVE will store the current
asdf:already-loaded-systems to a persistent database. RESTORE will restore the saved session. Finally, TOGGLE-WATCH will initiate watching in a background thread which periodically check and save the session.
TODO Using Programatically
Although it is possible, the interface is not documented not structured very well. For automated testing, I'm using
simulate-menu-selection, but please don't use it. For such a purpose, use
(simulate-menu-selection `((eazy-project::create-project) (:name "test") (eazy-project::create)))
I plan to separate the interactive interface as an independent library in the near future.
Skeleton of the new project is currently not customizable, unlike original
- Masataro Asai