M NEWS +5 -1
@@ 1,4 1,8 @@
-conf
+conf 0.2.5
+- add languages wisp and wisp-enter
+- requirements in README.md
+
+conf 0.2.4
- conf new --lang=? lists supported languages
- conf new --vcs=? lists supported version tracking systems
- new language: latex-copernicus to write a paper for a copernicus journal
M README.md +29 -4
@@ 7,14 7,33 @@ but without the NIH and currently more l
See NEWS for user-visible changes.
See ChangeLog or the history for detailed changes.
-## Usage: Create a new project
+## Usage
+
+### Create a new project (example: hello)
+
+ conf new hello --lang bash
+
+The filenames of projects are restricted to lowercase alphanumerics to
+avoid any problems due to edge-cases in different languages.
+
+### Build and install a project (example: hello)
- conf new hello_world --lang bash
+ cd hello && ./bootstrap.sh && ./configure && make && make install
+
+user installation:
+
+ cd hello && ./bootstrap.sh && ./configure --prefix ~/.local && make && make install
-Currently implemented languages:
+And generally everything else you can do with autotools. Also see
+
+ make help
+
+## Currently implemented languages:
- bash (full): script with resources
-- guile scheme
+- guile scheme: http://gnu.org/s/guile
+- wisp: see http://www.draketo.de/english/wisp
+- wisp-enter: setup for writing executable fiction
- python (partial)
- latex-copernicus: write a paper for a copernicus journal
@@ 43,6 62,12 @@ to find the place to edit.
For inspiration, look into template/bash since that includes some
necessary tricks to access data paths with autotools under bash.
+## Requirements
+
+- bash: http://gnu.org/s/bash
+- sed: http://gnu.org/s/sed
+- grep: http://gnu.org/s/grep
+
## build conf
./bootstrap.sh ; make
M conf.in +11 -10
@@ 302,8 302,6 @@ function run_new () {
for i in "${TEMPLATES}"/"${PROJLANG}"/*; do
cp -r "${i}" "${PROJ}"/
done
- sed -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/*
- sed -i "s,_TEMPLATE_AUTHOR_,${AUTHOR},g" "${PROJ}"/*
# rename template files and folders
for i in "${PROJ}"/*"_TEMPLATE_PROJ_"*; do
mv "${i}" "${i//_TEMPLATE_PROJ_/$PROJ}"
@@ 337,26 335,29 @@ function run_new () {
if test -e "${TAILTAIL}"; then
cat "${TAILTAIL}" >> "${PROJ}"/"${i}"
fi
- sed -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/"${i}"
+ sed --separate -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/"${i}"
done
# add a pregenerated skelleton
if test x"${PROJLANG}" = x"bash"; then
cp "${TEMPLATES}/${PROJLANG}/_TEMPLATE_PROJ_".in "${PROJ}"/"${PROJ}".in
- sed -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/"${PROJ}".in
+ sed --separate -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/"${PROJ}".in
fi
if test x"${PROJLANG}" = x"python"; then
cp "${TEMPLATES}/${PROJLANG}/_TEMPLATE_PROJ_.py" "${PROJ}"/"${PROJ}.py"
- sed -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/"${PROJ}.py"
+ sed --separate -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/"${PROJ}.py"
fi
if test x"${PROJLANG}" = x"guile"; then
- sed -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/"${PROJ}.scm" "${PROJ}"/"${PROJ}"/*".scm" "${PROJ}"/scripts/*
+ sed --separate -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/"${PROJ}.scm" "${PROJ}"/"${PROJ}"/*".scm" "${PROJ}"/scripts/*
fi
- if test x"${PROJLANG}" = x"wisp"; then
+ if test x"${PROJLANG}" = x"wisp" || test x"${PROJLANG}" = x"wisp-enter"; then
cp "${TEMPLATES}/${PROJLANG}/run-_TEMPLATE_PROJ_.w" "${PROJ}"/"run-${PROJ}.w"
- sed -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/"run-${PROJ}.w" "${PROJ}"/"${PROJ}"/*".w" "${PROJ}"/scripts/*
+ sed --separate -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${PROJ}"/"run-${PROJ}.w" "${PROJ}"/"${PROJ}"/*".w" "${PROJ}"/scripts/*
fi
- # replace the author
- sed -i "s/_TEMPLATE_AUTHOR_/${AUTHOR}/g" "${PROJ}"/*
+ # replace the author and project name in all files
+ for i in "${PROJ}"/* "${PROJ}"/*/* "${PROJ}"/*/*/*; do
+ sed --separate -i "s,_TEMPLATE_PROJ_,${PROJ},g" "${i}"
+ sed --separate -i "s,_TEMPLATE_AUTHOR_,${AUTHOR},g" "${i}"
+ done
chmod +x "${PROJ}"/bootstrap.sh
vcs--${PROJVCS}-prepare "${PROJ}"
M templates/wisp/Makefile.am => templates/wisp-enter/Makefile.am +0 -0
M templates/wisp/README.tail => templates/wisp-enter/README.tail +0 -0
M templates/wisp/_TEMPLATE_PROJ_/doctests.w => templates/wisp-enter/_TEMPLATE_PROJ_/doctests.w +0 -0
M templates/wisp/_TEMPLATE_PROJ_/enter.w => templates/wisp-enter/_TEMPLATE_PROJ_/enter.w +0 -0
M templates/wisp/_TEMPLATE_PROJ_/hello.w => templates/wisp-enter/_TEMPLATE_PROJ_/hello.w +0 -0
M templates/wisp/bootstrap.sh => templates/wisp-enter/bootstrap.sh +0 -0
M templates/wisp/configure.ac => templates/wisp-enter/configure.ac +0 -0
M templates/wisp/guile.am => templates/wisp-enter/guile.am +0 -0
M templates/wisp/language/wisp.scm => templates/wisp-enter/language/wisp.scm +0 -0
M templates/wisp/language/wisp/spec.scm => templates/wisp-enter/language/wisp/spec.scm +0 -0
M templates/wisp/m4/guile.m4 => templates/wisp-enter/m4/guile.m4 +0 -0
M templates/wisp/pre-inst-env.in => templates/wisp-enter/pre-inst-env.in +0 -0
M templates/wisp/run-_TEMPLATE_PROJ_.w => templates/wisp-enter/run-_TEMPLATE_PROJ_.w +0 -0
M templates/wisp/scripts/_TEMPLATE_PROJ_.in => templates/wisp-enter/scripts/_TEMPLATE_PROJ_.in +0 -0
M templates/wisp/Makefile.am +1 -4
@@ 36,8 36,6 @@ all: $(_TEMPLATE_PROJ_) $(nobase_bin_SCR
SOURCES = \
_TEMPLATE_PROJ_/hello.w \
- _TEMPLATE_PROJ_/enter.w \
- _TEMPLATE_PROJ_/doctest.w \
run-_TEMPLATE_PROJ_.w
EXTRA_DIST = \
@@ 59,9 57,8 @@ AM_DISTCHECK_CONFIGURE_FLAGS="--quiet"
.w.go:
$(GUILE) -L @abs_top_builddir@ -L @abs_top_srcdir@ -c '(import (language wisp spec))' && $(GUILE_TOOLS) compile -L @abs_top_builddir@ -L @abs_top_srcdir@ -x .w -f wisp $(GUILE_WARNINGS) -o "$@" "$<"
## run-_TEMPLATE_PROJ_.w needs cached files from dependencies that do not get created by guild, so we import from guile once
-run-_TEMPLATE_PROJ_.go : run-_TEMPLATE_PROJ_.w _TEMPLATE_PROJ_/enter.go _TEMPLATE_PROJ_/doctests.go
+run-_TEMPLATE_PROJ_.go : run-_TEMPLATE_PROJ_.w
$(GUILE) -L @abs_top_builddir@ -L @abs_top_srcdir@ -c '(import (language wisp spec))' && $(GUILE) -L @abs_top_builddir@ -L @abs_top_srcdir@ --language=wisp -x .w -c 'import : run-_TEMPLATE_PROJ_' && $(GUILE_TOOLS) compile -L @abs_top_builddir@ -L @abs_top_srcdir@ -x .w -f wisp $(GUILE_WARNINGS) -o "$@" "$<"
-_TEMPLATE_PROJ_/enter.go : _TEMPLATE_PROJ_/enter.w _TEMPLATE_PROJ_/doctests.go
language/wisp/spec.go: language/wisp/spec.scm language/wisp.go
ACLOCAL_AMFLAGS = -I m4
M templates/wisp/run-_TEMPLATE_PROJ_.w +0 -15
@@ 6,22 6,7 @@ define-module : run-_TEMPLATE_PROJ_
. #:export : main
import : _TEMPLATE_PROJ_ hello
- _TEMPLATE_PROJ_ doctests
- _TEMPLATE_PROJ_ enter
define : main args
hello-world
- dialogue
-define : dialogue
- Enter : First Witch
- First Witch
- Welcome to ,(color 'cyan) enter three witches! ,(color #f)
-
-define %this-module : current-module
-define : test
- ##
- tests
- test-equal #t : not #f
- doctests-testmod %this-module
-