PITWALL

Packaging

Preview

Preview. How to turn a tile project into a .pwtile package, sign it, and pass it on. Install covers what the person who gets it sees.

A package is one file holding the tile and everything it needs. A signature file sits beside it. Pitwall checks the signature before it unpacks anything. The person who installs it then knows the file wasn't changed on the way, and that later versions come from the same author.

Pack

Build the tile first, then pack it:

pitwall extension dev --once
pitwall extension pack

pack writes <id>-<version>.pwtile into the project folder, or to the path given with -o. It checks the component the way pitwall extension check does, then copies in these files and nothing else:

File
extension.jsonRequired. Its version is required too.
tile.wasmRequired. The component, at most 20 MiB.
README.mdRequired.
LICENSE, LICENSE.md, LICENSE.txt, NOTICEOptional.
CHANGELOG.mdOptional.
the input schemas its tiles nameRequired when named.
agents/SKILL.mdOptional. An agent skill, text only, at most 16 KiB.
assets/Optional. svg, png and webp only. Fonts are refused.
screenshots/Optional. png or webp, at most 8, at most 2 MiB each. A -dark and -light pair counts once.
media/Optional. The images your README shows: png, webp, jpeg or gif, at most 2 MiB each.
its icon fileWhen "icon" names one (below).

Sources, target/ and hidden files stay out. A symbolic link stops the pack. File names may use only ASCII letters, digits, ., _, - and /. The whole package may be at most 50 MiB.

The same files always give the same package, byte for byte. Two people who build the same component and pack it get identical files.

A package holds tiles only. An extension that also runs a program (an adapter or a service) is still installed from Git, npm or a folder.

Adding images

There is no upload service: an extension's images are files in its folder, packed with it, and linked by relative path. Browse and the detail page show them before and after install.

  • Its icon. "icon": "assets/icon.png" in extension.json: a square png or webp, 64 to 1024 px, at most 256 KiB. No SVG. Pitwall shows it on its card, in Browse, in the Tiles menu, on its toolbar button and in the command palette. An icon name ("grid") still works; an icon that doesn't check is replaced by the standard one.
  • Screenshots. Files in screenshots/, png or webp, at most 8. main-dark.png and main-light.png are one screenshot: Pitwall shows the one of your theme. To give them an order and captions, list them:

``json "screenshots": [ { "path": "screenshots/main.png", "caption": "The board, beside its agent" } ] ``

(main.png names the pair.) Captions are at most 120 characters. Click one to see it larger.

  • README images. Put them in media/ (or assets/, screenshots/) and link them relatively: ![How it works](media/flow.png) or <img src="media/flow.png">. Each is checked by its content, not its name. Pitwall never fetches an image from the network: ![Build](https://…) shows as a link to it. A path that leaves the folder (../) or isn't packed isn't shown. GitHub's #gh-dark-mode-only and #gh-light-mode-only work too.
  • Listing fields. "tagline" (at most 80 characters, shown under the name), "categories" (1 to 3 of the index's), "homepage" and "repository" (https), and "license" (its SPDX name). The detail page shows them.

pitwall extension check checks all of this and warns about what a listing lacks (an icon, screenshots, a tagline, categories, a licence, a network image).

Make a signing key

Make keys with Pitwall itself, outside every source repository:

pitwall catalog setup --directory "$HOME/.config/pitwall-signing"

The directory must not already exist. Pitwall asks for a password and confirmation, then writes encrypted private keys and matching public files for the publisher, current catalog, next catalog, and review roles. Use the publisher key for your extension packages; the other roles are for operating a catalog. No separate signing tool is needed.

  • Keep private .key files out of every repository and back them up securely. Losing the publisher key means installed users must explicitly trust a new one.
  • Publish publisher.pub in your project's README or website so people can compare it with the key Pitwall shows. Its public key starts with pwp1:.
  • For unattended commands, supply the password through PITWALL_SIGN_PASSWORD in your secret store. Never put a password in a command-line argument.

Sign

pitwall extension sign my-tile-0.1.0.pwtile \
  --key "$HOME/.config/pitwall-signing/publisher.key"

sign writes my-tile-0.1.0.pwtile.pwsig beside the package. It uses the explicit --key path, or PITWALL_SIGN_KEY, and asks for the password unless PITWALL_SIGN_PASSWORD supplies it. It prints the public key and fingerprint, never the private key.

Pitwall's versioned signature envelope carries the public key and a standard Ed25519 signature over a package-specific context and the package's exact bytes. The catalog, blocked list and review statements use separate contexts, so their signatures cannot be reused as package signatures. The public key carried by a package enables first-install verification; it does not by itself make the publisher trusted. Catalog and review signatures must match keys already trusted by Pitwall.

Pass it on

Send both files, the .pwtile and its .pwsig, and keep them side by side. The person installs it from Settings → Extensions → Install from file…, or with pitwall extension install <file>.

To list it in the extensions index for Browse, release both files on GitHub and run pitwall extension publish (Publishing). The index also needs a LICENSE file and a "description" in extension.json: pack tells you when either is missing.

Updates

Pack and sign each new version with the same key, and raise version in extension.json. Pitwall refuses:

  • a version signed by another key, unless the person explicitly trusts the new key;
  • an older version (they use Go back for that instead);
  • the version already installed.

When a version asks for new permissions, more memory, a larger database or new net hosts, Pitwall lists the changes before the update. It grants none of them until the person allows each one. Say why in each permission's reason, and in CHANGELOG.md.

If you must change keys, tell people first, through the same place where you published the old key. Pitwall will show them the new key and ask whether to trust it.

Folders still work

While you develop, use pitwall extension dev. To share a quick preview without a key, a folder works as before (Quick start), and so does an unsigned package. Both are marked as previews. Neither can replace a signed install.

What Pitwall checks

When it opens a package, Pitwall checks it in this order and stops at the first problem:

  1. The file is at most 50 MiB.
  2. The signature matches the file's bytes, and the key is the one trusted for this extension, if one is.
  3. The zip is plain: no zip64, encryption or comment, stored or deflate only, and headers that agree with each other.
  4. Every name passes the rules above. There are no duplicates (ignoring case), no .., no absolute paths, and no links or special files.
  5. Every size is within its limit before anything is inflated, and each file's checksum matches.
  6. The manifest is valid, its files are the ones allowed, and tile.wasm is a component that needs only what this Pitwall provides.

Only then is the package unpacked, into a new hidden folder, and shown to the person.