Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file removed assets/deed-v0.2.8-wasm32-unknown-unknown.wasm
Binary file not shown.
Binary file added assets/deed-v0.2.9-wasm32-unknown-unknown.wasm
Binary file not shown.
4 changes: 2 additions & 2 deletions assets/errors.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
// artifact carries all of them, so this page cannot document a code the
// compiler does not have, or miss one it does.

const TAG = "v0.2.8";
const VERSION = "0.2.8";
const TAG = "v0.2.9";
const VERSION = "0.2.9";
const WASM_URL = `../assets/deed-${TAG}-wasm32-unknown-unknown.wasm`;

const STATUS = document.getElementById("status");
Expand Down
4 changes: 2 additions & 2 deletions assets/play.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
// release, because a release asset cannot be fetched from a browser at all:
// both the download URL and the API one redirect to a host that sends no
// `Access-Control-Allow-Origin`. See decisions/2026-07-31-no-build-step.md.
const TAG = "v0.2.8";
const VERSION = "0.2.8";
const TAG = "v0.2.9";
const VERSION = "0.2.9";
const WASM_URL = `../assets/deed-${TAG}-wasm32-unknown-unknown.wasm`;

const SOURCE = document.getElementById("source");
Expand Down
2 changes: 1 addition & 1 deletion examples/index.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"tag": "v0.2.8",
"tag": "v0.2.9",
"examples": [
{
"file": "calculator.deed",
Expand Down
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ <h2>Its signature only admits to reading one.</h2>
href="install/"
>
<strong>Install it</strong>
<span>Binaries for Linux, macOS and Windows, or build from source.</span>
<span>One line, or one file, on Linux, macOS and Windows.</span>
</a>
<a class="card" href="https://github.com/deed-lang/deed/tree/main/design">
<strong>Read it</strong>
Expand Down
125 changes: 101 additions & 24 deletions install/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ <h1>Install</h1>
</p>

<!--
Every `deed 0.2.8` below is the output of that binary on that
Every `deed 0.2.9` below is the output of that binary on that
platform, printed by the release workflow, which refuses to publish
when a binary disagrees with its tag. The program output further down
was produced by running the released Windows build.
Expand All @@ -73,7 +73,41 @@ <h1>Install</h1>
not is a broken download link, and it was one for a day.
-->

<h2>Take the file for your machine</h2>
<h2>One line</h2>
<p>On Linux, or on an Apple-silicon Mac:</p>
<pre class="code"><code>$ curl -fsSL https://raw.githubusercontent.com/deed-lang/deed/main/install.sh | sh</code></pre>
<p>On Windows:</p>
<pre class="code"><code>&gt; irm https://raw.githubusercontent.com/deed-lang/deed/main/install.ps1 | iex</code></pre>
<p>
Either one works out which release asset fits the machine, downloads
it along with the checksum list the release published, refuses it if
the hash does not match, and leaves one file in your own profile:
<code>~/.local/bin</code>, or
<code>%LOCALAPPDATA%\Programs\deed</code>. It never asks for a
password, because it never writes anywhere that would need one, and
there is nothing to uninstall but the file.
</p>
<p>
What the hash buys is worth stating exactly, since a
<code>sha256</code> in an install script tends to read like it proves
more than it does. The checksums come from the same release as the
binary, so this catches a truncated or corrupted download and does
not catch a compromised release.
</p>
<p>
Piping a script into a shell is a thing worth being uneasy about.
Both scripts are short and are in the repository beside the compiler
&mdash; <a href="https://github.com/deed-lang/deed/blob/main/install.sh"
><code>install.sh</code></a
>
and
<a href="https://github.com/deed-lang/deed/blob/main/install.ps1"
><code>install.ps1</code></a
>
&mdash; and the rest of this page is the same work done by hand.
</p>

<h2>By hand instead</h2>
<table class="files">
<thead>
<tr>
Expand All @@ -84,15 +118,15 @@ <h2>Take the file for your machine</h2>
<tbody>
<tr>
<td>Linux, 64-bit Intel or AMD</td>
<td><code>deed-v0.2.8-x86_64-unknown-linux-gnu.tar.gz</code></td>
<td><code>deed-v0.2.9-x86_64-unknown-linux-gnu.tar.gz</code></td>
</tr>
<tr>
<td>macOS, Apple silicon</td>
<td><code>deed-v0.2.8-aarch64-apple-darwin.tar.gz</code></td>
<td><code>deed-v0.2.9-aarch64-apple-darwin.tar.gz</code></td>
</tr>
<tr>
<td>Windows, 64-bit</td>
<td><code>deed-v0.2.8-x86_64-pc-windows-msvc.zip</code></td>
<td><code>deed-v0.2.9-x86_64-pc-windows-msvc.zip</code></td>
</tr>
</tbody>
</table>
Expand All @@ -101,7 +135,7 @@ <h2>Take the file for your machine</h2>
<a href="https://github.com/deed-lang/deed/releases/latest"
>the latest release</a
>. There is no Intel Mac build and no Linux ARM build; on those,
<a href="#source">build from source</a>.
<a href="#source">build it with Rust</a>.
</p>

<h2>Unpack it and ask it what it is</h2>
Expand All @@ -111,23 +145,23 @@ <h2>Unpack it and ask it what it is</h2>
</p>

<h3>Linux</h3>
<pre class="code"><code>$ tar xzf deed-v0.2.8-x86_64-unknown-linux-gnu.tar.gz
$ ./deed-v0.2.8-x86_64-unknown-linux-gnu/deed --version
deed 0.2.8</code></pre>
<pre class="code"><code>$ tar xzf deed-v0.2.9-x86_64-unknown-linux-gnu.tar.gz
$ ./deed-v0.2.9-x86_64-unknown-linux-gnu/deed --version
deed 0.2.9</code></pre>

<h3>macOS</h3>
<pre class="code"><code>$ tar xzf deed-v0.2.8-aarch64-apple-darwin.tar.gz
$ xattr -d com.apple.quarantine deed-v0.2.8-aarch64-apple-darwin/deed
$ ./deed-v0.2.8-aarch64-apple-darwin/deed --version
deed 0.2.8</code></pre>
<pre class="code"><code>$ tar xzf deed-v0.2.9-aarch64-apple-darwin.tar.gz
$ xattr -d com.apple.quarantine deed-v0.2.9-aarch64-apple-darwin/deed
$ ./deed-v0.2.9-aarch64-apple-darwin/deed --version
deed 0.2.9</code></pre>
<p>
The middle line is not optional and it is explained below.
</p>

<h3>Windows</h3>
<pre class="code"><code>&gt; Expand-Archive deed-v0.2.8-x86_64-pc-windows-msvc.zip .
&gt; .\deed-v0.2.8-x86_64-pc-windows-msvc\deed.exe --version
deed 0.2.8</code></pre>
<pre class="code"><code>&gt; Expand-Archive deed-v0.2.9-x86_64-pc-windows-msvc.zip .
&gt; .\deed-v0.2.9-x86_64-pc-windows-msvc\deed.exe --version
deed 0.2.9</code></pre>

<h2>What your operating system will say about it</h2>
<p>
Expand Down Expand Up @@ -160,18 +194,45 @@ <h2>What your operating system will say about it</h2>
<h2>Where to put it</h2>
<p>
Anywhere. It reads nothing next to itself and writes nothing beside
itself. To type <code>deed</code> instead of a path, move it onto
yours:
itself. The one-line install has already put it somewhere your shell
looks; if you unpacked it by hand and want to type
<code>deed</code> instead of a path, move it onto yours:
</p>
<pre class="code"><code>$ sudo mv deed-v0.2.8-x86_64-unknown-linux-gnu/deed /usr/local/bin/deed</code></pre>
<pre class="code"><code>$ sudo mv deed-v0.2.9-x86_64-unknown-linux-gnu/deed /usr/local/bin/deed</code></pre>
<p>
On Windows, put the folder on <code>Path</code> through Settings, or
keep using the full path. Nothing on this page needs it on
<code>Path</code>.
</p>

<h2>A first program</h2>
<p>Put this in a file called <code>hello.deed</code>:</p>
<p>
<code>deed new</code> writes one, rather than leaving you to work the
module header and the file layout out of a repository:
</p>
<pre class="code"><code>$ deed new greeter
greeter/greeter.deed
greeter/main.deed

next: cd greeter &amp;&amp; deed test .

$ cd greeter
$ deed test .
./greeter.deed
ok a greeting carries the name it was given
ok there is no greeting for nobody
ok property greeting (100 cases)

3 passed, 0 failed

$ deed run main.deed
hello, world</code></pre>
<p>
Three tests out of two files, and only two of them are written down.
The third is generated from the contract on <code>greeting</code>,
which is the point: a signature is checked rather than read.
</p>
<p>By hand instead, the whole of a program is this much:</p>
<pre class="code"><code>module hello

fn main(sys: System) -&gt; Int
Expand Down Expand Up @@ -216,6 +277,14 @@ <h2>What else is in it</h2>
</tr>
</thead>
<tbody>
<tr>
<td><code>deed new</code></td>
<td>
A project: a library module with a contract and its tests, and
a program that imports it. No manifest, because a new project
has no code outside its own tree.
</td>
</tr>
<tr>
<td><code>deed check</code></td>
<td>The compiler. Silence is the answer.</td>
Expand Down Expand Up @@ -298,14 +367,22 @@ <h2>What else is in it</h2>
to a runtime check.
</p>

<h2 id="source">From source</h2>
<h2 id="source">With Rust instead</h2>
<p>Needs Rust 1.85 or newer, and nothing else:</p>
<pre class="code"><code>$ cargo install deed-lang</code></pre>
<p>
<code>deed</code> on crates.io belongs to somebody else, so the
package is <code>deed-lang</code>. The binary it installs is
<code>deed</code>, and it is the same one file this page has been
talking about.
</p>
<p>From a clone, if you want the tree it was built from:</p>
<pre class="code"><code>$ git clone https://github.com/deed-lang/deed
$ cd deed
$ cargo install --path crates/deed-cli</code></pre>
<p>
The workspace has no external dependencies, so this compiles what is
in the tree and nothing from anywhere else.
The workspace has no external dependencies, so either way this
compiles the compiler and nothing from anywhere else.
</p>

<h2>When it does not work</h2>
Expand All @@ -322,7 +399,7 @@ <h2>When it does not work</h2>
<code>./</code>, or move it as above.
</dd>

<dt><code>--version</code> prints something other than 0.2.8</dt>
<dt><code>--version</code> prints something other than 0.2.9</dt>
<dd>
You are running a different <code>deed</code> than the one you
unpacked. <code>which deed</code> says which.
Expand Down
4 changes: 2 additions & 2 deletions one-clause/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -201,14 +201,14 @@ <h2 data-step="Now take the first one and add `Io.save` to it, and watch the com
<nav class="next" aria-label="Open in the playground">
<a
class="card"
href="../play/#0.2.8/zTZFBi9wwDIXv_hXv1i5Mk3soC0t7mcsW2oUei-MoY4MjBUveNJT-9-JktuzRsvS9p6e-xzcmhOyrEhLDQ9ONvdVCSAqLhCnNMxXiQBjJNiKGbYIgyypMbNq5vnd9j5eYFHPlYEkYhfyk8JhTpg4vkd6R1e8K-u2D5R1b9IZkCJ5hUkMcGqwpt1Hd1Wi5YJZyIBPfOjyLxcQ3UFbq8EWWNWWaYIKfND6p0jLm_dIYDbXIVDN9UKRllWJQOh0GYfOJFcIEWan4ozwXWQ75KGrDfTdgIpqGJDhc3KtPRw8S60rBWlzekJMaRpqlEEplbkZbrHzLLWK1Ug_9DlfDRCFNpA22RbJIpW2hdV3zDvIh3k13b1qHxFrktY3hKl2zg7EaWKxhrtKpf6UjzlIZ1q7y_1jYkkWphkJqJZ1GnDsjwkSL9A34Szjvzs3cpAKpfjxuMeBrKhewX2jADyuJbw_49IjvpDXb57Nyuf88OqAqqQPwZvTi_rx_ntQT-OD-un8"
href="../play/#0.2.9/zTZFBi9wwDIXv_hXv1i5Mk3soC0t7mcsW2oUei-MoY4MjBUveNJT-9-JktuzRsvS9p6e-xzcmhOyrEhLDQ9ONvdVCSAqLhCnNMxXiQBjJNiKGbYIgyypMbNq5vnd9j5eYFHPlYEkYhfyk8JhTpg4vkd6R1e8K-u2D5R1b9IZkCJ5hUkMcGqwpt1Hd1Wi5YJZyIBPfOjyLxcQ3UFbq8EWWNWWaYIKfND6p0jLm_dIYDbXIVDN9UKRllWJQOh0GYfOJFcIEWan4ozwXWQ75KGrDfTdgIpqGJDhc3KtPRw8S60rBWlzekJMaRpqlEEplbkZbrHzLLWK1Ug_9DlfDRCFNpA22RbJIpW2hdV3zDvIh3k13b1qHxFrktY3hKl2zg7EaWKxhrtKpf6UjzlIZ1q7y_1jYkkWphkJqJZ1GnDsjwkSL9A34Szjvzs3cpAKpfjxuMeBrKhewX2jADyuJbw_49IjvpDXb57Nyuf88OqAqqQPwZvTi_rx_ntQT-OD-un8"
>
<strong>read_only.deed</strong>
<span>The one a host without `Io.save` will run.</span>
</a>
<a
class="card"
href="../play/#0.2.8/zhVFBjtswDLz7FXNrArj2PWgDLNpLTwXaBXpcKBIdC2uThkhvNijy90Jy7F20h-okaciZ4bBt8Z0JfnCzEiLDQeOZnc2JEBXWE0LsOkrEnnAiuxAx7CLwMk7CxKZN1bZV2-Kxj4puZm9RGIlcUDh0cSA4DrikaKSIhpPzz00RpldL7p289ZSZNg8HfJNG3Qs1-CLjFAcKMMEvOj2o0ngarnXxOEqYB_qgiOMkyaBUTGQulgu8sLnIWozLRMllVNElGUt_L2qH-xhAIAqHKCgz_PWVzdwLH0obrHeGKclLDKQQHq7ZdG6FEi0Z5q7VW84iUTdrwaJmqi1MnKiTREgzc-Rz2QefhxyOWprLVA0et5ERyA8uUYADExW360DwjlkMI5HVRXZDluUU51sG_0Z39-L4Ci-hmNKmqjblUdpM9FQ2W1Ud5xg8qe7y0vWArzHVYDfSAT8tRT7v8fGIH6TzYJ-Wn_qOHCsgR1IBWPOr10eOr65-l-fozPdrxSK0aOyxFORDKe0u_XWPz8ftXm-oPO-MXq2gG13WeE9XY6l5I_0_8Z38qcCryht8W6636lb9AQ"
href="../play/#0.2.9/zhVFBjtswDLz7FXNrArj2PWgDLNpLTwXaBXpcKBIdC2uThkhvNijy90Jy7F20h-okaciZ4bBt8Z0JfnCzEiLDQeOZnc2JEBXWE0LsOkrEnnAiuxAx7CLwMk7CxKZN1bZV2-Kxj4puZm9RGIlcUDh0cSA4DrikaKSIhpPzz00RpldL7p289ZSZNg8HfJNG3Qs1-CLjFAcKMMEvOj2o0ngarnXxOEqYB_qgiOMkyaBUTGQulgu8sLnIWozLRMllVNElGUt_L2qH-xhAIAqHKCgz_PWVzdwLH0obrHeGKclLDKQQHq7ZdG6FEi0Z5q7VW84iUTdrwaJmqi1MnKiTREgzc-Rz2QefhxyOWprLVA0et5ERyA8uUYADExW360DwjlkMI5HVRXZDluUU51sG_0Z39-L4Ci-hmNKmqjblUdpM9FQ2W1Ud5xg8qe7y0vWArzHVYDfSAT8tRT7v8fGIH6TzYJ-Wn_qOHCsgR1IBWPOr10eOr65-l-fozPdrxSK0aOyxFORDKe0u_XWPz8ftXm-oPO-MXq2gG13WeE9XY6l5I_0_8Z38qcCryht8W6636lb9AQ"
>
<strong>read_write.deed</strong>
<span>The one it will not.</span>
Expand Down