Commits

Shlomi Fish committed 26a2a41

Added the files of the site.

  • Participants

Comments (0)

Files changed (8)

+
+TARGET = dest
+
+# PAGES = about articles/index books/index core-doc/index index irc/index mailing-lists/index links/index site-resources/index tutorials/index web-forums/index
+
+# SUBDIRS = articles books core-doc irc links mailing-lists tutorials site-resources source source/arcs web-forums
+
+include defs.mak
+
+
+SOURCES = $(addprefix src/,$(addsuffix .html.wml,$(PAGES)))
+
+DESTS = $(patsubst src/%.html.wml,$(TARGET)/%.html,$(SOURCES))
+
+RAW_FILES = style.css
+RAW_FILES_SOURCES = $(addprefix src/,$(RAW_FILES))
+RAW_FILES_DEST = $(addprefix $(TARGET)/,$(RAW_FILES))
+
+PODS = $(addprefix docs/,roadmap spec whitepaper version-0.2-spec)
+PODS_DESTS_HTMLS = $(patsubst %,$(TARGET)/%.html,$(PODS))
+PODS_DESTS_PODS = $(patsubst %,$(TARGET)/%.pod,$(PODS))
+
+# PACKAGES_DIR = $(TARGET)/download/arcs
+# PACKAGES = $(shell cd temp && cd lk-module-compiler-final && ls)
+# PACKAGES_DESTS = $(addprefix $(PACKAGES_DIR)/,$(PACKAGES))
+
+SUBDIRS_DEST = $(addprefix $(TARGET)/,$(SUBDIRS))
+
+WML_FLAGS += --passoption=2,-X --passoption=7,"-S imgsize" -DROOT~.
+
+RSYNC = rsync --progress --verbose --rsh=ssh 
+
+ARC_NAME := $(shell cd temp && ./get-arc-name.sh)
+
+DEST_ARC_PAGE = $(TARGET)/source/index.html
+
+all: dest $(SUBDIRS_DEST) $(DESTS) $(RAW_FILES_DEST)
+
+dest:
+	if [ ! -e $@ ] ; then mkdir $@ ; fi
+	
+$(DESTS) :: $(TARGET)/% : src/%.wml template.wml
+	(cd src && wml $(WML_FLAGS) -DFILENAME=$(patsubst src/%.wml,%,$<) $(patsubst src/%,%,$<)) > $@
+
+$(RAW_FILES_DEST) :: $(TARGET)/% : src/%
+	cp -f $< $@
+
+$(SUBDIRS_DEST) :: % : unchanged
+	if [ ! -e $@ ] ; then mkdir $@ ; fi
+
+$(PODS_DESTS) :: $(TARGET)/% : src/%
+	cp -f $< $@
+
+$(PODS_DESTS_HTMLS) :: $(TARGET)/%.html : src/%.pod
+	pod2html $< > $@
+
+# $(PACKAGES_DESTS) :: $(PACKAGES_DIR)/% : ./temp/lk-module-compiler-final/%
+# 	cp -f $< $@
+
+upload: upload_berlios
+
+upload_berlios: all
+	(cd dest && $(RSYNC) -r * shlomif@shell.berlios.de:/home/groups/perl-begin/htdocs/)
+
+upload_iglu: all
+	(cd dest && $(RSYNC) -r * shlomif@iglu.org.il:/iglu/html/shlomif/Perl-Begin/)
+
+DEST_ARC_NAME = $(TARGET)/source/arcs/$(ARC_NAME)
+
+.PHONY: 
+
+$(DEST_ARC_PAGE) :: $(TARGET)/% : src/%.wml template.wml .PHONY
+	(cd src && wml $(WML_FLAGS) -DARCNAME=$(ARC_NAME) -DFILENAME=$(patsubst src/%.wml,%,$<) $(patsubst src/%,%,$<)) > $@
+
+arc: $(DEST_ARC_NAME) $(DEST_ARC_PAGE)
+
+$(DEST_ARC_NAME):
+	(cd temp && ./make-archive.sh)
+	mv temp/$(ARC_NAME) $@
+
+upload_arc: arc
+	$(RSYNC) $(ARC_NAME) shlomif@shell.berlios.de:
+
+devel-layouts: unchanged
+	cd temp && bash ./export-layouts.sh && mv -f LM-Solve-Layouts-`cat devel-layouts-ver.txt`.tar.gz ../dest
+	
+

File gen_helper.sh

+#!/bin/bash
+list_wmls()
+{
+    find ./src/ -name '*.html.wml' | 
+        sed 's!^\./src/!!' | 
+        sed 's!\.html\.wml$!!' | 
+        grep -v '^source/index$' |
+        sort
+}
+
+get_subdirs()
+{
+    grep '/' | 
+        sed 's!/[^/]*$!!' |         
+        uniq
+}
+
+add_extra()
+{
+    cat ;
+    echo "source"
+    echo "source/arcs"
+}
+
+(echo "PAGES = $(list_wmls | xargs)" ;
+echo
+echo "SUBDIRS = $(list_wmls | get_subdirs | add_extra | xargs)"
+echo ) > defs.mak
+
+    

File src/download.html.wml

+#include '../template.wml'
+
+<subject "LM-Solve Downloads" />
+
+<h2>Stable Version</h2>
+
+<define-tag file:with:url>
+<a href="%0">%0</a>
+</define-tag>
+
+<p>
+<file:with:url "LM-Solve-0.6.0.tar.gz" /> - <b>executable and 
+code</b>.
+</p>
+
+<p>
+<file:with:url "LM-Solve-layouts-0.6.0.tar.gz" /> - 
+<b>layouts for some of the puzzles on the sites</b>. I just supply them, but I 
+am not their legal owner. If you write down others, please send them to me.
+</p>
+
+<h2>Development Version</h2>
+
+<p>
+<a href="http://www.cpan.org/modules/by-module/Games/Games-LMSolve-0.7.12.tar.gz">Games-LMSolve-0.7.12.tar.gz</a>
+</p>
+
+<p>
+<:{
+my $ver = `cat ../temp/devel-layouts-ver.txt`;
+my $filename = "LM-Solve-Layouts-$ver.tar.gz";
+print "<a href=\"$filename\">$filename</a>\n";
+}:>
+</p>
+
+

File src/index.html.wml

+#include '../template.wml'
+
+<subject "LM-Solve - a Logic Mazes Solver" />
+
+<p>
+LM-Solve is a set of solvers I wrote for the Logic Mazes featured on the 
+<a href="http://www.logicmazes.com/">Logic Mazes site</a> and
+<a href="http://www.clickmazes.com/">Click Mazes site</a>. They are written 
+in Perl and should be very portable.
+</p>
+
+<hr style="width:50%" />
+
+<h2>News</h2>
+
+<h3>15-Aug-2002</h3>
+
+<p>
+LM-Solve version 0.6.0 was released. This versions sports support for
+<a href="http://www.clickmazes.com/planks/ixplanks.htm">
+Planks in the Swamp Puzzles</a> (rectangular only), and can be built as 
+an RPM out of the box.
+</p>
+
+<h3>12-Jun-2002</h3>
+
+<p>
+LM-Solve version 0.4.0 was released. This version features support for three
+types of <a href="http://www.clickmazes.com/newtilt/ixtilt2d.htm">tilt 
+mazes</a>: single goal, multiple goals, and <a
+href="http://www.clickmazes.com/newtilt/ixtilt.htm">Red-Blue Tilt Puzzles
+</a>
+</p>
+
+<h2>Links</h2>
+
+<p>
+<a href="http://freshmeat.net/projects/lm-solve/">The Freshmeat Project's
+Record</a><br />
+<a href="http://stalker.iguide.co.il:8080/svn/lm-solve/">The Subversion Repository of the Project</a><br />
+</p>
+
+<p>
+<a href="http://www.logicmazes.com/">The Logic Mazes site</a><br />
+<a href="http://www.iit.edu/~maxiori/apps/Theseus.html">The Original
+Applet for Theseus and the Minotaur</a><br />
+<a href="http://www.bardavid.com/">Yoah Bar-David's site</a> - contains
+applets for constructing and solving Alice Mazes and Minotaur Mazes.<br />
+<a href="http://www.clickmazes.com/">Andrea Glibert's Click-Mazes</a> -
+more mazes.<br />
+</p>
+
+

File src/style.css

+a:hover, img.highlight:hover { background-color : lightgreen }
+td.navbar 
+{ 
+    background-color: #ddabea;
+    width : 20% ; 
+    border-color : black;
+    border-width : thick;
+    border-style : double;
+}
+
+td.navbar h2 { color: black ; border : none ; font-size : large ; margin-left : 0.5em ; background-color : transparent }
+p.desc { margin-left : 3em }
+ul.navbarmain { padding-left : 1em ; margin-left : 1em ; font-size : 90%}
+ul.navbarnested { padding-left : 0em ; margin-left : 2em }
+h3.newsitem { text-indent: 3em }
+p.newsitem { margin-left : 6em }
+div.indent { margin-left : 3em }
+p.indent { margin-left : 3em  }
+div.rightalign { text-align : right }
+/*
+    Make sure the links inside the navigation bar are highlited
+    with a different colour. That's CSS 2.
+    http://www.zvon.org/xxl/CSS2Tutorial/Examples/example3.html
+*/
+td.navbar a:hover { background-color : orange }
+td.main { padding-left : 1em ; margin-left : 1em }
+h1 { font-family : serif }
+h2.plain{ color : black ; border : none ; font-family : serif }
+
+tt { color : #8A2BE2 /* The BlueViolet Color */ }

File temp/export-layouts.sh

+#!/bin/bash
+
+mkdir lay
+cd lay
+svn export http://stalker.iguide.co.il:8080/svn/lm-solve/lm-solve/layouts/layouts
+ver="$(cat layouts/ver.txt)"
+dir_base="LM-Solve-Layouts-$ver"
+arc_name="$dir_base.tar.gz"
+mv layouts $dir_base
+tar -czvf $arc_name $dir_base
+mv -f $arc_name ../
+cd ..
+rm -fr lay
+echo -n $ver > devel-layouts-ver.txt
+

File template.wml

+# #use wml::des::navbar
+
+<define-tag email:link>
+<a href="mailto:%0">%0</a>
+</define-tag>
+
+# The Definition of the page itself
+<?xml version="1.0" encoding="iso-8859-1"?>
+<!DOCTYPE html 
+     PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US" lang="en-US">
+<head>
+<title>{#SUBJECT_LOC#}</title>
+<link rel="stylesheet" href="$(ROOT)/style.css" type="text/css" />
+</head>
+<body>
+
+<define-tag rellink whitespace="delete">
+<preserve url />
+<set-var %attributes />
+$(ROOT)/<get-var url />
+<restore url />
+</define-tag>
+
+<define-tag site:link whitespace="delete">
+<preserve url />
+<set-var %attributes />
+http://perl-begin.berlios.de/<get-var url />
+<restore url />
+</define-tag>
+
+
+<define-tag navbarlink whitespace="delete">
+<preserve title />
+<set-var %attributes />
+<set-var l="<rellink url="%0" />" />
+<set-var t="<if "<get-var title />" <attributes-quote title=<get-var title /> /> "" />" />
+<if
+    ;;; Determine if %0 matches this document
+    <ifeq "$(FILENAME)" "%0"
+        "1"
+        <ifeq "$(FILENAME)" "%0index.html"
+            "1"
+            <ifeq "$(FILENAME)" "%0/index.html" 
+                "1"
+                ""
+                />
+        />
+
+    />
+    ;;; If so - bolds the text
+    "<b>%1</b>"
+    ;;; If not - makes a hyperlink
+    "<a href="<get-var l />" <get-var t />>%1</a>"
+/>
+<restore title />
+</define-tag>
+
+
+<define-tag vipe:url>http://vipe.technion.ac.il/~shlomif/%0</define-tag>
+<define-tag lect:link><navbarlink "lecture/%0" "%1" host="vipe" /></define-tag>
+
+<define-tag links:group endtag="required">
+<ul class="navbarmain">
+%body
+</ul>
+</define-tag>
+
+<define-tag wiki:link whitespace="delete">
+<preserve url />
+<set-var %attributes />
+<ifeq "<get-var url />" "" 
+    "" 
+    "<set-var url="?<get-var url />" />" 
+    />
+<site:link url="cgi-bin/chiq_chaq/chiq.pl" /><get-var url />
+<restore url />
+</define-tag>
+
+<define-tag mailing:list:link whitespace="delete">
+https://lists.berlios.de/mailman/listinfo/perl-begin-help
+</define-tag>
+
+<define-tag web:forum:link whitespace="delete">
+http://developer.berlios.de/forum/forum.php?forum_id=2341
+</define-tag>
+
+<define-tag nothing></define-tag>
+
+<define-tag navbar:head>
+<preserve href />
+<preserve title />
+<preserve hint />
+<set-var %attributes />
+<set-var title:attr="<if "<get-var hint />" <attributes-quote title=<get-var hint /> /> <nothing /> />" />
+<h2><a href="<get-var href />" <get-var title:attr />><get-var title /></a></h2>
+<restore hint />
+<restore title />
+<restore href />
+</define-tag>
+
+<table summary="Layout Table: The first cell contains a navigation bar, the second the main page" border="0" width="99%">
+<tr>
+<td valign="top" class="navbar" style="width:20%">
+
+<links:group>
+<li><navbarlink "" "Home" /></li>
+<li><navbarlink "download.html" "Download" /></li>
+<li><navbarlink "links.html" "Links" /></li>
+</links:group>
+
+
+<define-tag uses:link>
+<preserve href />
+<preserve caption />
+<preserve title />
+<preserve hide />
+<set-var %attributes />
+<set-var t="<if "<get-var title />" <attributes-quote title=<get-var title /> /> "" />" />
+<if "<ifeq "<get-var hide />" "1" "<match "$(FILENAME)" "^uses/" action="report" />" "1" />"
+    "<li><navbarlink "<get-var href />" "<get-var caption />" <get-var t /> /></li>"
+    ""
+    />
+<restore hide />
+<restore title />
+<restore caption />
+<restore href />
+</define-tag>
+
+<define-tag validhtml>
+<br /><br /><br /><br />
+<p>
+<a href="http://validator.w3.org/check/referer"><img 
+    style="border:0" src="http://www.w3.org/Icons/valid-xhtml10" 
+         alt="Valid XHTML 1.0!"
+         /></a>
+</p>
+<p>
+ <a href="http://jigsaw.w3.org/css-validator/"><img style="border:0"
+       src="http://jigsaw.w3.org/css-validator/images/vcss" 
+       alt="Valid CSS!" /></a>
+</p>
+<p>
+</p>
+</define-tag>
+
+<ifeq "$(FILENAME)" "index.html" "<validhtml />" "" />
+
+</td>
+<td valign="top" class="main">
+<h1>{#SUBJECT_LOC#}</h1>
+{#BODY#}
+
+</td>
+</tr>
+</table>
+<hr />
+<p>
+<b>Webmaster:</b> <a href="mailto:shlomif@vipe.technion.ac.il">Shlomi Fish - shlomif@vipe.technion.ac.il</a>
+</p>
+
+</body>
+</html>
+
+<define-tag subject>
+{#SUBJECT_LOC#:%0:##}
+</define-tag>
+
+
+#   per default we are in body
+{#BODY#:
+

File unchanged

Empty file added.