From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Amirouche Boubekki Newsgroups: gmane.lisp.guile.user Subject: sfx: baby steps of an html templating engine based on skribillo's skribe reader and sxml Date: Thu, 30 Jul 2015 13:55:00 +0200 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=_472b5b2293570600ec10b0e2c71422ee" X-Trace: ger.gmane.org 1438263586 11730 80.91.229.3 (30 Jul 2015 13:39:46 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 30 Jul 2015 13:39:46 +0000 (UTC) To: guile-user@gnu.org Original-X-From: guile-user-bounces+guile-user=m.gmane.org@gnu.org Thu Jul 30 15:39:35 2015 Return-path: Envelope-to: guile-user@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZKo3a-0004bw-E3 for guile-user@m.gmane.org; Thu, 30 Jul 2015 15:39:34 +0200 Original-Received: from localhost ([::1]:40091 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZKo3Z-0006xX-Nc for guile-user@m.gmane.org; Thu, 30 Jul 2015 09:39:33 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:55113) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZKmQZ-0006FX-Cz for guile-user@gnu.org; Thu, 30 Jul 2015 07:55:16 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZKmQS-0004s1-Ci for guile-user@gnu.org; Thu, 30 Jul 2015 07:55:11 -0400 Original-Received: from relay3-d.mail.gandi.net ([2001:4b98:c:538::195]:56056) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZKmQS-0004pF-1l for guile-user@gnu.org; Thu, 30 Jul 2015 07:55:04 -0400 Original-Received: from mfilter17-d.gandi.net (mfilter17-d.gandi.net [217.70.178.145]) by relay3-d.mail.gandi.net (Postfix) with ESMTP id 60383A80AA for ; Thu, 30 Jul 2015 13:55:02 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at mfilter17-d.gandi.net Original-Received: from relay3-d.mail.gandi.net ([IPv6:::ffff:217.70.183.195]) by mfilter17-d.gandi.net (mfilter17-d.gandi.net [::ffff:10.0.15.180]) (amavisd-new, port 10024) with ESMTP id wyeS8qeX9Cuo for ; Thu, 30 Jul 2015 13:55:00 +0200 (CEST) X-Originating-IP: 10.58.1.148 Original-Received: from webmail.gandi.net (unknown [10.58.1.148]) (Authenticated sender: amirouche@hypermove.net) by relay3-d.mail.gandi.net (Postfix) with ESMTPA id 9678CA80BB for ; Thu, 30 Jul 2015 13:55:00 +0200 (CEST) X-Sender: amirouche@hypermove.net User-Agent: Roundcube Webmail/1.1.2 X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4b98:c:538::195 X-Mailman-Approved-At: Thu, 30 Jul 2015 09:39:04 -0400 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane.org@gnu.org Original-Sender: guile-user-bounces+guile-user=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.user:11930 Archived-At: --=_472b5b2293570600ec10b0e2c71422ee Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable H=C3=A9llo, I've been lurking around skribillo and artanis. I don't really like the=20 rails-like syntax of artanis, even if it has its use-cases and I wanted to hack on=20 something "small", so I've put together sfx. The code of skribe reader is included in sfx.scm. So the only dependency=20 is guile (2.0.11) and guile-reader that you can install using `guix package -i guile-reader`. This bare template language has the following features: - wanna be simpler sxml syntax - templates with custom environment - external libraries loading inside the template # Wanna be simpler sxml syntax Skribe reader (implemented with guile-reader) provide a handy syntax to both define keywords and quasiquote. In an sxml context those features are used to implemented attributes and text nodes. ## attributes Attributes in sxml are defined as follow: (div (@ (id "shell")) "This the main area") Instead of requiring the nesting of `(attribute-name attribute-value)`=20 sfx use the simpler keyword syntax `:keyword`. The above snippet becomes: (div (@ :id "shell") "This the main area") I'm not sure it's worth the trouble of diverting from sxml standard.=20 That said, it looks more like plain xml. ## text nodes Text nodes can be defined as (p [h=C3=A9llo hacker]) This is looks the same as the default reader. It becomes handy when you=20 include an inline element inside the text node: (p [h=C3=A9llo ,(b [hacker]) `,()` is a special syntax of skribe reader which provides `(unquote)`=20 inside [bracket] `quasiquote`. With the default guile reader, this must be written as: (p "h=C3=A9llo " (b "hacker")) This is looks verbose and prone to error. One must not forget the space=20 in the string before the `(b)` element. # templates with custom environment Right now this part of the template language is not really userfriendly.=20 But you can pass custom variables to the template but those must be parameters. In the example=20 sfx.scm (which includes example use of the procedures) the environment in which the template is=20 evaled is defined as follow: (define value (make-parameter 42)) (define amirouche (make-person "amirouche" 30)) (define env (let ((value value) (amirouche amirouche)) (the-environment))) Then `value` can be echo'ed inside the template using the unquote syntax=20 `,()`, e.g. (p [Here is a lucky number for you =C2=AB,(value)=C2=BB]) As you can see the previous snippet, there is also a `` record=20 inside the environment. One can (maybe) provide in the environment the required procedures to=20 echo the correct fields but this is verbose. Instead sfx use `(use-modules)` inside the=20 template definition file. This is presented in the following and last part. # external libraries loading inside the template Currently it's (only) possible to do `(use-modules)` inside the template=20 file. The template file looks like the following: ``` (use-modules (person)) `(html (body (p [My name is ,(person-name amirouche)]))) ``` I could not make procedure definition work inside the template, this my=20 be linked to the way I eval the template. It's shame because for quick and dirty hacks it can=20 be handy like defining mini-templates inside the big template. This is my second try at this and having a look at the code of haunt [1]=20 was helpful. Hope this helps! [1] https://git.dthompson.us/haunt.git --=20 Amirouche ~ amz3 ~ http://www.hyperdev.fr --=_472b5b2293570600ec10b0e2c71422ee Content-Transfer-Encoding: base64 Content-Type: text/plain; name=index.scm Content-Disposition: attachment; filename=index.scm; size=1179 KHVzZS1tb2R1bGVzIChwZXJzb24pKQoKYChodG1sCiAgKGhlYWQKICAgKG1ldGEgKEAgOmNoYXJz ZXQgInV0Zi04IikpCiAgICh0aXRsZSBbVGhpcyBpcyBhIHBhZ2UgZ2VuZXJhdGVkIGZyb20gc2No ZW1lXSkKICAgKG1ldGEgKEAgOm5hbWUgImF1dGhvciIgOmNvbnRlbnQgIkFtaXJvdWNoZSBCT1VC RUtLSSA8YW1pcm91Y2hlQGh5cGVybW92ZS5uZXQ+IikpCiAgIChtZXRhIChAIDpuYW1lICJ2aWV3 cG9ydCIgOmNvbnRlbnQgIndpZHRoPWRldmljZS13aWR0aCwgaW5pdGlhbC1zY2FsZT0xIikpCiAg IChsaW5rIChAIDpyZWwgInN0eWxlc2hlZXQiIDpocmVmICJzdGF0aWMvY3NzL2Jvb3RzdHJhcC5t aW4uY3NzIikpCiAgIChsaW5rIChAIDpyZWwgInN0eWxlc2hlZXQiIDpocmVmICJzdGF0aWMvY3Nz L2Jvb3RzdHJhcC10aGVtZS5taW4uY3NzIikpCiAgIChsaW5rIChAIDpyZWwgInN0eWxlc2hlZXQi IDpocmVmICJzdGF0aWMvY3NzL21haW4uY3NzIikpKSAgCiAgKGJvZHkgKEAgOmNsYXNzICJpbmRl eCIpCiAgICAgICAgKGRpdiAoQCA6Y2xhc3MgY29udGFpbmVyKQogICAgICAgICAgICAgKGRpdiAo QCA6Y2xhc3MgImhlYWRlciBjbGVhcmZpeCIpCiAgICAgICAgICAgICAgICAgIChuYXYKICAgICAg ICAgICAgICAgICAgICh1bCAoQCA6Y2xhc3MgIm5hdiBuYXYtcGlsbHMgcHVsbC1yaWdodCIpICAg ICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgKGxpIChAIDpyb2xlICJw cmVzZW50YXRpb24iIDpjbGFzcyAiYWN0aXZlIikKICAgICAgICAgICAgICAgICAgICAgICAgICAg KGEgKEAgOmhyZWYgIiMiKSBbSG9tZV0pKQogICAgICAgICAgICAgICAgICAgICAgIChsaSAoQCA6 cm9sZSAicHJlc2VudGF0aW9uIiApCiAgICAgICAgICAgICAgICAgICAgICAgICAgIChhIChAIDpo cmVmICJtYWlsdG86YW1pcm91Y2hlQGh5cGVyZGV2LmZyIikgW0NvbnRhY3RdKSkpKQogICAgICAg ICAgICAgICAgICAoaDMgKEAgOmNsYXNzICJ0ZXh0LW11dGVkIikgW2h5cGVyZGV2LmZyXSkpCiAg ICAgICAgICAgICAoZGl2IChAIDpjbGFzcyAicm93IikKICAgICAgICAgICAgICAgICAgKHAgWywo cGVyc29uLW5hbWUgYW1pcm91Y2hlKSBzYXlzOiBIw6lsbG8gc3RyYW5nZXIhIEhlcmUgaXMgYSBs dWNreSBudW1iZXIgZm9yIHlvdSDCqywodmFsdWUpwrtdKSkpKSkK --=_472b5b2293570600ec10b0e2c71422ee Content-Transfer-Encoding: base64 Content-Type: text/plain; name=sfx.scm Content-Disposition: attachment; filename=sfx.scm; size=7017 Ozs7IENvcHlyaWdodCDCqSAyMDE1ICBBbWlyb3VjaGUgQm91YmVra2kgPGFtaXJvdWNoZUBoeXBl cm1vdmUubmV0Pgo7OzsgQ29weXJpZ2h0IMKpIDIwMDUsIDIwMDYgTHVkb3ZpYyBDb3VydMOocyA8 bHVkb3ZpYy5jb3VydGVzQGxhYXMuZnI+Cjs7Owo7OzsgVGhpcyBsaWJyYXJ5IGlzIGZyZWUgc29m dHdhcmU7IHlvdSBjYW4gcmVkaXN0cmlidXRlIGl0IGFuZC9vcgo7OzsgbW9kaWZ5IGl0IHVuZGVy IHRoZSB0ZXJtcyBvZiB0aGUgR05VIExlc3NlciBHZW5lcmFsIFB1YmxpYyBMaWNlbnNlCjs7OyBh cyBwdWJsaXNoZWQgYnkgdGhlIEZyZWUgU29mdHdhcmUgRm91bmRhdGlvbjsgZWl0aGVyIHZlcnNp b24gMyBvZgo7OzsgdGhlIExpY2Vuc2UsIG9yIChhdCB5b3VyIG9wdGlvbikgYW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mNvbnRlbnQgIndpZHRoPWRldmlj ZS13aWR0aCwgaW5pdGlhbC1zY2FsZT0xIikpCjs7ICAgIChsaW5rIChAIDpyZWwgInN0eWxlc2hl ZXQiIDpocmVmICJzdGF0aWMvY3NzL2Jvb3RzdHJhcC5taW4uY3NzIikpCjs7ICAgIChsaW5rIChA IDpyZWwgInN0eWxlc2hlZXQiIDpocmVmICJzdGF0aWMvY3NzL2Jvb3RzdHJhcC10aGVtZS5taW4u Y3NzIikpCjs7ICAgIChsaW5rIChAIDpyZWwgInN0eWxlc2hlZXQiIDpocmVmICJzdGF0aWMvY3Nz L21haW4uY3NzIikpKSAgCjs7ICAgKGJvZHkgKEAgOmNsYXNzICJpbmRleCIpCjs7ICAgICAgICAg KGRpdiAoQCA6Y2xhc3MgY29udGFpbmVyKQo7OyAgICAgICAgICAgICAgKGRpdiAoQCA6Y2xhc3Mg ImhlYWRlciBjbGVhcmZpeCIpCjs7ICAgICAgICAgICAgICAgICAgIChuYXYKOzsgICAgICAgICAg ICAgICAgICAgICh1bCAoQCA6Y2xhc3MgIm5hdiBuYXYtcGlsbHMgcHVsbC1yaWdodCIpICAgICAg ICAgICAgICAgICAgICAgCjs7ICAgICAgICAgICAgICAgICAgICAgICAgKGxpIChAIDpyb2xlICJw cmVzZW50YXRpb24iIDpjbGFzcyAiYWN0aXZlIikKOzsgICAgICAgICAgICAgICAgICAgICAgICAg ICAgKGEgKEAgOmhyZWYgIiMiKSBbSG9tZV0pKQo7OyAgICAgICAgICAgICAgICAgICAgICAgIChs aSAoQCA6cm9sZSAicHJlc2VudGF0aW9uIiApCjs7ICAgICAgICAgICAgICAgICAgICAgICAgICAg IChhIChAIDpocmVmICIjIikgW0Fib3V0XSkpCjs7ICAgICAgICAgICAgICAgICAgICAgICAgKGxp IChAIDpyb2xlICJwcmVzZW50YXRpb24iICkKOzsgICAgICAgICAgICAgICAgICAgICAgICAgICAg KGEgKEAgOmhyZWYgIiMiKSBbQ29udGFjdF0pKSkpCjs7IC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gtcHJvYyAncjopKSkKCjs7Owo7Ozsgc2ty aWJlIHJlYWRlciAoYm9ycm93ZWQgZnJvbSBza3JpYmlsbykKOzs7CgooZGVmaW5lIChtYWtlLWNv bG9uLWZyZWUtdG9rZW4tcmVhZGVyIHRyKQogIDs7IFN0b2xlbiBmcm9tIGBndWlsZS1yZWFkZXIn IDAuMy4KICAiSWYgdG9rZW4gcmVhZGVyIEB2YXJ7dHJ9IGhhbmRsZXMgdGhlIEBjb2Rlezp9IChj b2xvbikgY2hhcmFjdGVyLCByZW1vdmUgaXQKZnJvbSBpdHMgc3BlY2lmaWNhdGlvbiBhbmQgcmV0 dXJuIHRoZSBuZXcgdG9rZW4gcmVhZGVyLiIKICAobGV0KiAoKHNwZWMgKHI6dG9rZW4tcmVhZGVy LXNwZWNpZmljYXRpb24gdHIpKQogICAgICAgICAocHJvYyAocjp0b2tlbi1yZWFkZXItcHJvY2Vk dXJlIHRyKSkpCiAgICAocjptYWtlLXRva2VuLXJlYWRlciAoZmlsdGVyIChsYW1iZGEgKGNocikK ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAobm90IChjaGFyPT8gY2hyICNcOikp KQogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzcGVjKQogICAgICAgICAgICAgICAg ICAgICAgICAgcHJvYykpKQoKKGRlZmluZSAmc2hhcnAtcmVhZGVyCiAgOzsgVGhlIHJlYWRlciBm b3Igd2hhdCBjb21lcyBhZnRlciBhIGAjJyBjaGFyYWN0ZXIuCiAgKGxldCogKChkc3NzbC1rZXl3 b3JkLXJlYWRlciAgOzsga2V5d29yZHMgw6AgbGEgYCMha2V5JwogICAgICAgICAgKHI6bWFrZS10 b2tlbi1yZWFkZXIgI1whCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAocjp0b2tlbi1y ZWFkZXItcHJvY2VkdXJlCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKHI6c3RhbmRh cmQtdG9rZW4tcmVhZGVyICdrZXl3b3JkKSkpKSkKICAgICAgKHI6bWFrZS1yZWFkZXIgKGNvbnMg ZHNzc2wta2V5d29yZC1yZWFkZXIKICAgICAgICAgICAgICAgICAgICAgICAgICAgKG1hcCByOnN0 YW5kYXJkLXRva2VuLXJlYWRlcgogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICcoY2hh cmFjdGVyIHNyZmktNCB2ZWN0b3IKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG51 bWJlcityYWRpeCBib29sZWFuCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzcmZp MzAtYmxvY2stY29tbWVudAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc3JmaTYy LXNleHAtY29tbWVudCkpKQogICAgICAgICAgICAgICAgICAgICAjZiA7OyB1c2UgZGVmYXVsdCBm YXVsdCBoYW5kbGVyCiAgICAgICAgICAgICAgICAgICAgICdyZWFkZXIvcmVjb3JkLXBvc2l0aW9u cykpKQoKKGRlZmluZSAobWFrZS1za3JpYmUtcmVhZGVyKQogIChsZXQgKChjb2xvbi1rZXl3b3Jk cyA7OyBrZXl3b3JkcyDDoCBsYSBgOmtleScgZmFzaGlvbgogICAgICAgICAocjptYWtlLXRva2Vu LXJlYWRlciAjXDoKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKHI6dG9rZW4tcmVhZGVy LXByb2NlZHVyZQogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKHI6c3RhbmRhcmQtdG9r ZW4tcmVhZGVyICdrZXl3b3JkKSkpKQogICAgICAgIChzeW1ib2wtbWlzYy1jaGFycy10cgogICAg ICAgICA7OyBNYWtlIHN1cmUgYDonIGlzIGhhbmRsZWQgb25seSBieSB0aGUga2V5d29yZCB0b2tl biByZWFkZXIuCiAgICAgICAgIChtYWtlLWNvbG9uLWZyZWUtdG9rZW4tcmVhZGVyCiAgICAgICAg ICAocjpzdGFuZGFyZC10b2tlbi1yZWFkZXIgJ3I2cnMtc3ltYm9sLW1pc2MtY2hhcnMpKSkpCgoK ICAgIDs7IE5vdGU6IHdlIHVzZSB0aGUgYHI2cnMtc3ltYm9sLSonIGFuZCBgcjZycy1udW1iZXIn IHRva2VuIHJlYWRlcnMgc2luY2UKICAgIDs7IHRoZXkgY29uc2lkZXIgc3F1YXJlIGJyYWNrZXRz IGFzIGRlbGltaXRlcnMuCiAgICAocjptYWtlLXJlYWRlciAoY29ucyogKHI6bWFrZS10b2tlbi1y ZWFkZXIgI1wjICZzaGFycC1yZWFkZXIpCiAgICAgICAgICAgICAgICAgICAgICAgICAgY29sb24t a2V5d29yZHMKICAgICAgICAgICAgICAgICAgICAgICAgICBzeW1ib2wtbWlzYy1jaGFycy10cgog ICAgICAgICAgICAgICAgICAgICAgICAgIChtYXAgcjpzdGFuZGFyZC10b2tlbi1yZWFkZXIKICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgIGAod2hpdGVzcGFjZQogICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgICBzZXhwIHN0cmluZyByNnJzLW51bWJlcgogICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgICByNnJzLXN5bWJvbC1sb3dlci1jYXNlCiAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgIHI2cnMtc3ltYm9sLXVwcGVyLWNhc2UKICAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgcXVvdGUtcXVhc2lxdW90ZS11bnF1b3RlCiAgICAgICAgICAgICAgICAg ICAgICAgICAgICAgICAgIHNlbWljb2xvbi1jb21tZW50CiAgICAgICAgICAgICAgICAgICAgICAg ICAgICAgICAgIHNrcmliZS1leHApKSkKICAgICAgICAgICAgICAgICAgICNmIDs7IHVzZSB0aGUg ZGVmYXVsdCBmYXVsdCBoYW5kbGVyCiAgICAgICAgICAgICAgICAgICAncmVhZGVyL3JlY29yZC1w b3NpdGlvbnMKICAgICAgICAgICAgICAgICAgICkpKQoKKGRlZmluZSAoa2V5d29yZHMtPmF0dHJp YnV0ZXMga2V5d29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ZJWE1FOiB0aGUgZW52aXJvbm1lbnQgaXMgaGFyZGNvZGVkIGlu c2lkZSBmbHlldmFsCih1c2UtbW9kdWxlcyAocGVyc29uKSkKKGRlZmluZSB2YWx1ZSAobWFrZS1w YXJhbWV0ZXIgNDIpKQooZGVmaW5lIGFtaXJvdWNoZSAobWFrZS1wZXJzb24gImFtaXJvdWNoZSIg MzApKQooZGVmaW5lIGVudiAobGV0ICgodmFsdWUgdmFsdWUpCiAgICAgICAgICAgICAgICAgIChh bWlyb3VjaGUgYW1pcm91Y2hlKSkKICAgICAgICAgICAgICAodGhlLWVudmlyb25tZW50KSkpCgoo ZGVmaW5lIChmbHlldmFsIHNleHByKQogICgobG9jYWwtZXZhbCBgKGxhbWJkYSAoKSAsc2V4cHIp IGVudikpKQoKCihkZWZpbmUqIChyZWFkLWV2YWwtdGVtcGxhdGUgIzpvcHRpb25hbCBvdXQpCiAg KGxldCAoKHNleHAgKHNrcmliZSkpKQogICAgKGlmIChlb2Ytb2JqZWN0PyBzZXhwKQogICAgICAg IG91dAogICAgICAgIChyZWFkLWV2YWwtdGVtcGxhdGUgKGZseWV2YWwgc2V4cCkpKSkpCgoKKGRl ZmluZSAob3V0cHV0KQogICAgKHdpdGgtaW5wdXQtZnJvbS1maWxlICJpbmRleC5zY20iCiAgICAg IChsYW1iZGEgKCkKICAgICAgICAoZGlzcGxheSAiPCFET0NUWVBFIGh0bWw+IikKICAgICAgICAo c3htbC0+eG1sIChmbHlldmFsIChsaXN0ICdxdWFzaXF1b3RlIChzZngtPnN4bWwgKHJlYWQtZXZh bC10ZW1wbGF0ZSkpKSkpKSkpCgoKOzsgKG91dHB1dCkgIDs7IGRpc3BsYXkgaHRtbCB0byBzdGRv dXQKCgood2l0aC1vdXRwdXQtdG8tZmlsZSAiaW5kZXguaHRtbCIKICAobGFtYmRhICgpIChvdXRw dXQpKSkK --=_472b5b2293570600ec10b0e2c71422ee Content-Transfer-Encoding: base64 Content-Type: text/plain; name=person.scm Content-Disposition: attachment; filename=person.scm; size=205 KGRlZmluZS1tb2R1bGUgKHBlcnNvbikpCgoodXNlLW1vZHVsZXMgKHNyZmkgc3JmaS05KSkKCihk ZWZpbmUtcmVjb3JkLXR5cGUgPHBlcnNvbj4KICAobWFrZS1wZXJzb24gbmFtZSBhZ2UpCiAgcGVy c29uPwogIChuYW1lIHBlcnNvbi1uYW1lKQogIChhZ2UgcGVyc29uLWFnZSkpCgooZXhwb3J0IG1h a2UtcGVyc29uIHBlcnNvbi1uYW1lIHBlcnNvbi1hZ2UpCg== --=_472b5b2293570600ec10b0e2c71422ee--