Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Crunchy Pi

Date: Thu, 8 Mar 2012 08:04:27 -0800 (PST)
From: =?UTF-8?Q?Andr=C3=A9?= <andre.robe...@gmail.com>
To: crunchy-discuss@googlegroups.com
Message-ID: <32242914.671.1331222667118.JavaMail.geo-discussion-forums@vbne13>
In-Reply-To: <b544f5cb-1f20-4419-8f3b-059ebbb025bf@gw9g2000vbb.googlegroups.com>
References: <b544f5cb-1f20-4419-8f3b-059ebbb025bf@gw9g2000vbb.googlegroups.com>
Subject: Re: Crunchy Pi
MIME-Version: 1.0
Content-Type: multipart/mixed; 
	boundary="----=_Part_669_26347861.1331222667111"

------=_Part_669_26347861.1331222667111
Content-Type: multipart/alternative; 
	boundary="----=_Part_670_26658595.1331222667117"

------=_Part_670_26658595.1331222667117
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

I have written a first prototype, slightly different than what I described=
=20
in the two scenarios I mentioned yesterday.   It is available from the svn=
=20
repository (svn update).

A test file has been included as the last entry in the "experimental"=20
section of the crunchy tutorial menu.

The way the prototype currently works is as follows:
1. a code listing meant to include hidden parts is identified via <pre=20
title=3D"hidden_code ..." > .... </pre>
2. The entire code (including would be hidden parts) is styled and=20
displayed.
3. An editor is appended below that includes only parts of the code
   * Code appearing between the (non-valid Python code) lines=20
 "hidden_code_begin"  and "hidden_code_end" are replaced in the editor by a=
=20
comment line "# hidden code"
   * Code lines that are removed (hidden) are stored
   * An arbitrary number of code lines can be removed
4. Prior to execution, the code in the editor is scanned and comment lines=
=20
"# hidden code" are replaced by their original versions.  This is done in a=
=20
dumb way: it is assumed that there are as many such comment lines as=20
original code sections to be removed, and that the order remains the same.

Since the entire code can be viewed above the editor, there is essentially=
=20
no reason to tack on extra security feature for this prototype version.

Comments are welcome,

Andr=C3=A9

------=_Part_670_26658595.1331222667117
Content-Type: text/html; charset=utf-8
Content-Transfer-Encoding: quoted-printable

I have written a first prototype, slightly different than what I described =
in the two scenarios I mentioned yesterday. &nbsp; It is available from the=
 svn repository (svn update).<div><br></div><div>A test file has been inclu=
ded as the last entry in the "experimental" section of the crunchy tutorial=
 menu.</div><div><br></div><div>The way the prototype currently works is as=
 follows:</div><div>1. a code listing meant to include hidden parts is iden=
tified via &lt;pre title=3D"hidden_code ..." &gt; .... &lt;/pre&gt;</div><d=
iv>2. The entire code (including would be hidden parts) is styled and displ=
ayed.</div><div>3. An editor is appended below that includes only parts of =
the code</div><div>&nbsp; &nbsp;* Code appearing between the (non-valid Pyt=
hon code) lines &nbsp;"hidden_code_begin" &nbsp;and "hidden_code_end" are r=
eplaced in the editor by a comment line "# hidden code"</div><div>&nbsp; &n=
bsp;* Code lines that are removed (hidden) are stored</div><div>&nbsp; &nbs=
p;* An arbitrary number of code lines can be removed</div><div>4. Prior to =
execution, the code in the editor is scanned and comment lines "# hidden co=
de" are replaced by their original versions. &nbsp;This is done in a dumb w=
ay: it is assumed that there are as many such comment lines as original cod=
e sections to be removed, and that the order remains the same.</div><div><b=
r></div><div>Since the entire code can be viewed above the editor, there is=
 essentially no reason to tack on extra security feature for this prototype=
 version.</div><div><br></div><div>Comments are welcome,</div><div><br></di=
v><div>Andr=C3=A9</div>
------=_Part_670_26658595.1331222667117--

------=_Part_669_26347861.1331222667111--