Warning: this is an htmlized version!
The original is across this link,
and the conversion rules are here.
#######
#
# E-scripts on Kepler.
#
# Note 1: use the eev command (defined in eev.el) and the
# ee alias (in my .zshrc) to execute parts of this file.
# Executing this file as a whole makes no sense.
#
# Note 2: be VERY careful and make sure you understand what
# you're doing.
#
# Note 3: If you use a shell other than zsh things like |&
# and the for loops may not work.
#
# Note 4: I always run as root.
#
# Note 5: some parts are too old and don't work anymore. Some
# never worked.
#
# Note 6: the definitions for the find-xxxfile commands are on my
# .emacs.
#
# Note 7: if you see a strange command check my .zshrc -- it may
# be defined there as a function or an alias.
#
# Note 8: the sections without dates are always older than the
# sections with dates.
#
# This file is at <http://angg.twu.net/e/kepler.e>
#           or at <http://angg.twu.net/e/kepler.e.html>.
#        See also <http://angg.twu.net/emacs.html>,
#                 <http://angg.twu.net/.emacs[.html]>,
#                 <http://angg.twu.net/.zshrc[.html]>,
#                 <http://angg.twu.net/escripts.html>,
#             and <http://angg.twu.net/>.
#
#######





# «.kepler-1.1»		(to "kepler-1.1")
# «.thttpd»		(to "thttpd")
# «.hash-bang-sapi»	(to "hash-bang-sapi")
# «.sputnik-old»	(to "sputnik-old")
# «.sputnik»		(to "sputnik")
# «.kepler-1.1beta2»	(to "kepler-1.1beta2")
# «.cosmo»		(to "cosmo")



# Mailing list:
# http://lists.luaforge.net/pipermail/kepler-project/





#####
#
# kepler-1.1
# 2007may20
#
#####

# «kepler-1.1»  (to ".kepler-1.1")
# (find-es "lua5" "kepler-1.1")
# http://kepler-tmp.dreamhosters.com/en/UNIX_Installation
# http://www.keplerproject.org/wiki/US/HomePage
# http://www.keplerproject.org/kepler-1.1-snapshot-20070511-1628.tar.gz
#*
# (eev-bounded)

rm -Rv ~/usrc/kepler-1.1/
tar -C ~/usrc/ -xvzf \
  $S/http/www.keplerproject.org/kepler-1.1-snapshot-20070511-1628.tar.gz
cd     ~/usrc/kepler-1.1/

./configure --prefix=$HOME/usrc/kepler --launcher=cgi --without-readline \
        2>&1 | tee oc
make    2>&1 | tee om

# Now install the runtime files
#  at "~/usrc/kepler/"...
rm -Rv ~/usrc/kepler/
make install \
        2>&1 | tee omi

cd ~/usrc/kepler/;     find * | sort > .files
cd ~/usrc/kepler-1.1/; find * | sort > .files

#*
# (code-c-d "keplersrc" "~/usrc/kepler-1.1/")
# (code-c-d "kepler"    "~/usrc/kepler/")
# (find-keplersrcfile "om")
# (find-keplersrcfile "omi")
# (find-keplersrcfile ".files")
# (find-keplerfile    ".files")





#####
#
# thttpd: compile the current upstream version
# 2005oct27
#
#####

# «thttpd»  (to ".thttpd")
# (find-es "http" "thttpd-compile")
# http://www.acme.com/software/thttpd/
# http://www.acme.com/software/thttpd/thttpd-2.25b.tar.gz
#*
rm -Rfv ~/usrc/thttpd-2.25b/
tar -C ~/usrc/ -xvzf \
  $S/http/www.acme.com/software/thttpd/thttpd-2.25b.tar.gz
cd     ~/usrc/thttpd-2.25b/
./configure    2>&1 | tee oc
make           2>&1 | tee om

#*
# (code-c-d "thttpd" "~/usrc/thttpd-2.25b/")
# (find-thttpdfile "")

# Links to the manpages... as I also have Debian's thttpd
# (2.23beta1) installed, find-man accesses the system-wide
# manpage (for 2.23beta1), and Emacs's WoMan accesses the
# one from 2.25b. They don't differ much.
#
# (woman-find-file "~/usrc/thttpd-2.25b/thttpd.8")
# (find-man "8 thttpd")







#####
#
# a SAPI for hash-bang CGIs
# 2007may21
#
#####

# «hash-bang-sapi»  (to ".hash-bang-sapi")
# (find-keplersrcfile ".files")
# (find-keplersrcw3m  "cgilua/doc/us/sapi.html")
# (find-keplersrcfile "launcher/cgi/cgi.lua")
# (find-keplersrcfile "launcher/cgi/sapi/")
# (find-keplersrcfile "launcher/cgi/sapi/info.lua")
# (find-keplersrcfile "launcher/cgi/sapi/request.lua")
# (find-keplersrcfile "launcher/cgi/sapi/response.lua")

SAPI = {
    Info = {
	_COPYRIGHT = "Copyright (C) 2004-2005 Kepler Project",
	_DESCRIPTION = "CGI SAPI implementation",
	_VERSION = "CGI SAPI 1.0",
	ispersistent = false,
    },
    Request = {
	servervariable = getenv,
	getpostdata = function (n) return stdin:read (n) end,
    },
    Response = {
	contenttype = function (header) stdout:write ("Content-type: "..header.."\n\n") end,
	errorlog = function (msg, errlevel) stderr:write (msg) end,
	header = function (header, value) stdout:write (format ("%s: %s\n", header, value)) end,
	redirect = function (url) stdout:write ("Location: "..url.."\n\n") end,
	write = function (...) stdout:write (...) end,
    },
}

# (find-es "http")

# (find-keplersrcfile "")
# (find-keplersrcfile "launcher/cgi/cgi.c")
# (find-keplerfile "")
# (find-keplersrcsh "find * | sort")
# (find-keplersh    "find * | sort")
# (find-keplersrcfile "xavante/src/t_xavante_start.lua")





#####
#
# sputnik
# 2007jul18
#
#####

# «sputnik-old»  (to ".sputnik-old")
# http://lists.luaforge.net/pipermail/sputnik-list/
# http://www.freewisdom.org/projects/sputnik/
# http://www.freewisdom.org/projects/sputnik/Installation
# http://www.keplerproject.org/kepler-1.1-snapshot-20070606-1643.tar.gz
#*
rm -Rfv ~/usrc/sputnik/
mkdir   ~/usrc/sputnik/
cd      ~/usrc/sputnik/
svn checkout http://sputnik-wiki.googlecode.com/svn/trunk/ sputnik-trunk-svn
cd      ~/usrc/sputnik/sputnik-trunk-svn/
tar -cvzf        ~/tmp/sputnik-trunk-svn.tgz .* *

#*
rm -Rfv      ~/sputnik/
mkdir        ~/sputnik/
sudo rm -Rfv ~/usrc/sputnik/wiki-data/
mkdir -p     ~/usrc/sputnik/wiki-data/
chmod -v 777 ~/usrc/sputnik/wiki-data/

#*
rm -Rfv ~/usrc/sputnik/
mkdir   ~/usrc/sputnik/
mkdir   ~/usrc/sputnik/sputnik-trunk-svn/
tar  -C ~/usrc/sputnik/sputnik-trunk-svn/ -xvzf ~/tmp/sputnik-trunk-svn.tgz
cd      ~/usrc/sputnik/sputnik-trunk-svn/

patch -p0 build_sputnik.sh <<'%%%'
12c12,14
< wget http://www.keplerproject.org/kepler-1.1-snapshot-20070606-1643.tar.gz
---
> if [ ! -e kepler-1.1-snapshot-20070606-1643.tar.gz ]; then
>   wget http://www.keplerproject.org/kepler-1.1-snapshot-20070606-1643.tar.gz
> fi
%%%

cat >> sputnik_config.lua <<'%%%'
-- edrx
WIKI_DATA_DIR = "/home/edrx/usrc/sputnik/wiki-data/"
%%%

# (find-sputnikfile "build_sputnik.sh")
cp -v $S/http/www.keplerproject.org/kepler-1.1-snapshot-20070606-1643.tar.gz /tmp/

cd ~/usrc/sputnik/sputnik-trunk-svn/
sh build_sputnik.sh ~/sputnik/  |& tee osbs

chmod -v 777 ~/usrc/sputnik/wiki-data/*/

cp -v sputnik.cgi /usr/lib/cgi-bin/

#*
# (code-c-d "sputnik" "~/usrc/sputnik/sputnik-trunk-svn/")
# (find-sputnikfile "")
# (find-sputnikfile "sputnik_config.lua")
# (find-sputnikfile "build_sputnik.sh")
# (find-sputniksh   "find")
# (find-fline "/tmp/kepler-1.1/")

# (find-sh0 "sudo chown -v edrx:edrx /usr/lib/cgi-bin/")
# (find-fline "/usr/lib/cgi-bin/")
# (find-fline "~/usrc/sputnik/wiki-data/")
# (find-fline "~/sputnik/")

# (find-sputnikfile "")
# (find-sputnikfile "osbs")
# (find-sputniksh   "find")
# (find-sputnikfile "" "sputnik.cgi")
# (find-fline "~/sputnik/")
# (find-fline "~/sputnik/bin/" "cgi")

# http://localhost:8080/cgi-bin/sputnik.cgi



# (find-fline "/usr/lib/cgi-bin/")
# (find-fline "/var/www/")
# (find-fline "/var/www/edrx/")
# http://139.82.89.178/
# http://139.82.89.178/cgi-bin/
# http://139.82.89.178/cgi-bin/sputnik.cgi
# http://139.82.89.178/~edrx/
# http://139.82.89.178/edrx/
# http://139.82.89.178/edrx/TODO
# http://139.82.89.178/edrx/apache2.conf
cp -v ~edrx/TODO /var/www/edrx/
cp -v /etc/apache2/apache2.conf /var/www/edrx/




#####
#
# Sputnik
# 2007nov26
#
#####

# «sputnik»  (to ".sputnik")
# http://sputnik.freewisdom.org/en/Installation
# http://sputnik.freewisdom.org/files/sputnik_install_2008_03_14.sh
# http://sputnik.freewisdom.org/files/kepler-1.1-snapshot-20071217-2000.tar.gz
# http://luaforge.net/frs/download.php/3152/luarocks-0.4.2.tar.gz
# http://lists.luaforge.net/pipermail/sputnik-list/2008-March/000247.html
#*
rm -Rfv  ~/usrc/sputnik/
mkdir -p ~/usrc/sputnik/
cd       ~/usrc/sputnik/
cp -v $S/http/sputnik.freewisdom.org/files/sputnik_install_2008_03_14.sh .
sh sputnik_install_2008_03_14.sh  |& tee oi

#*
rm -Rfv  ~/usrc/sputnik/
mkdir -p ~/usrc/sputnik/tmp/
cd       ~/usrc/sputnik/tmp/
cp -v $S/http/sputnik.freewisdom.org/files/kepler-1.1-snapshot-20071217-2000.tar.gz .
cp -v $S/http/luaforge.net/frs/download.php/3152/luarocks-0.4.2.tar.gz .
cd       ~/usrc/sputnik/
cp -v $S/http/sputnik.freewisdom.org/files/sputnik_install_2008_03_14.sh s_i.sh
patch -p0 s_i.sh <<'%%%'
4c4,5
< mkdir $TMP && cd $TMP
---
> mkdir -p $TMP && cd $TMP
> wget () { if [ ! -e $(basename $1) ]; then /usr/bin/wget $1; fi; }
%%%

sh s_i.sh  |& tee osi

#*
# (code-c-d "sputnik"      "~/usrc/sputnik/")
# (code-c-d "sputnikrocks" "~/usrc/sputnik/share/lua/5.1/luarocks/")
# (find-sputnikfile "")
# (find-sputnikfile "s_i.sh")
# (find-sputnikfile "osi")
# (find-sputnikfile "README.txt")
# (find-sputnikgrep "grep -nH -e wget $(find *)")
# (find-sputnikrocksfile "")
# (find-sputnikrocksfile "fs_unix.lua" "if config.downloader == \"wget\" then")

# http://lists.luaforge.net/pipermail/kepler-project/
# http://www.keplerproject.org/kepler-1.1-snapshot-20071119-1940.tar.gz







#####
#
# kepler-1.1beta2
# 2008jan15
#
#####

# «kepler-1.1beta2»  (to ".kepler-1.1beta2")
# http://kepler-tmp.dreamhosters.com/en/Installation
# http://luaforge.net/frs/download.php/2720/kepler-1.1beta2.tar.gz

* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)

#*
# (eev-bounded)
rm -Rv ~/usrc/kepler-1.1/
tar -C ~/usrc/ -xvzf \
  $S/http/luaforge.net/frs/download.php/2720/kepler-1.1beta2.tar.gz
cd     ~/usrc/kepler-1.1/

./configure --enable-lua  |& tee oc
make                      |& tee om

#*
# ./configure --prefix=$HOME/usrc/kepler --launcher=cgi --without-readline \
#         2>&1 | tee oc
make    2>&1 | tee om

# Now install the runtime files
#  at "~/usrc/kepler/"...
rm -Rv ~/usrc/kepler/
make install \
        2>&1 | tee omi

cd ~/usrc/kepler/;     find * | sort > .files
cd ~/usrc/kepler-1.1/; find * | sort > .files

#*
# (code-c-d "keplersrc" "~/usrc/kepler-1.1/")
# (code-c-d "kepler"    "~/usrc/kepler/")
# (find-keplersrcfile "")
# (find-keplersrcfile "configure")
# (find-keplersrcfile "oc")
# (find-keplersrcfile "om")
# (find-keplersrcfile "omi")
# (find-keplersrcfile ".files")
# (find-keplerfile    ".files")








# «cosmo»  (to ".cosmo")
http://sputnik.freewisdom.org/en/Cosmo
http://lists.luaforge.net/pipermail/kepler-project/2007-November/001959.html
http://lists.luaforge.net/pipermail/kepler-project/2007-November/001968.html

http://www.keplerproject.org/papers/LuaGem13-MVC_with_Kepler_v22.zip



http://spu.tnik.org/en/Lua_Workshop_2008
http://spu.tnik.org/en/PUC_Presentation_2009

A very good article about Sputnik:
http://luanova.org/
http://luanova.org/sputnik/







#  Local Variables:
#  coding:               raw-text-unix
#  ee-delimiter-hash:    "\n#*\n"
#  ee-delimiter-percent: "\n%*\n"
#  ee-anchor-format:     "«%s»"
#  End: