Closed PreviewCompiler source opens July 1, 2026. Playground and binary available today.Join Discord →
MetaScript

Ship a package in 5 minutes

The MetaScript registry at pkg.metascriptlang.org is open — publish under your own yourname/ namespace the minute you log in. No approval queue, no gatekeeping, no application form. If you write a useful module, other people can install it five minutes later.

This guide walks from empty folder to published package.

Prerequisites

  • msc on your path (msc --version should print something)
  • A GitHub account — the registry authenticates via GitHub OAuth

1. Project skeleton

my-package/
├── src/
│   └── index.ms          # exports live here
└── build.ms              # project + package manifest

Minimal src/index.ms:

export function slugify(text: string): string {
    return text
        .toLowerCase()
        .replace(/\s+/g, "-")
        .replace(/[^\w-]/g, "");
}

Minimal build.ms:

import { BuildConfig } from "std/build";

const config: BuildConfig = {
    entry: "./src/index",
    package: {
        name: "yourname/slug",
        version: "0.1.0",
        description: "Tiny slug helper",
        license: "MIT",
        repository: "https://github.com/yourname/slug",
        keywords: ["string", "slug", "utility"],
        files: ["./src/**/*.ms"],
    },
};

export default config;

build.ms is MetaScript's only manifest — there is no package.json. One file, typed config, imports from std/build.

2. The package section

Every field the publisher looks at:

FieldRequiredPurpose
namePersonal: yourname/pkg (no @). Org: @orgname/pkg.
versionSemver under MVS resolution. v-prefix accepted (e.g. v0.1.0 or 0.1.0).
descriptionOne-line summary, shown on the registry
licenseSPDX id (MIT, Apache-2.0, ...)
repositoryRepo URL
homepageProject site or docs URL
keywordsArray — helps discovery
authorFree-form string
filesInclude globs. Empty = everything under project root
ignoreExclude globs, applied after files

3. Log in

msc login

Opens your browser to GitHub OAuth. On approval, the token is cached locally. Confirm:

msc whoami
# @yourname

4. Dry run first

msc publish --dry-run

Lists every file that would be uploaded and prints the total size. No upload happens. Use this to sanity-check your files/ignore globs — easy to accidentally ship a .env or a node_modules/ clone if you forget the ignore glob.

5. Publish

msc publish

Server limits — enforced client-side so you fail fast, not after uploading megabytes:

LimitValue
Max files per package10,000
Max uncompressed total100 MB
Max zipped upload50 MB

If publish succeeds, your package is live at pkg.metascriptlang.org/yourname/slug within a second or two.

6. Ship an update

Bump version in build.ms and publish again:

// build.ms
package: {
    name: "yourname/slug",
    version: "0.1.1",   // bumped
    // ...
},
msc publish

Follow semver: patch for bug fixes, minor for additive features, major for breaking changes. There is no msc version helper — edit the string in build.ms directly.

Scopes

PatternExampleHow to get it
Personalyourname/pkgAutomatic — your GitHub username is your namespace on first msc login. No @.
Organization@myorg/pkgmsc org create myorg (or web UI at pkg.metascriptlang.org/orgs/new). Prefixed with @.

Personal namespaces are 1:1 with GitHub usernames — the lack of @ visually distinguishes "one human's work" from @org packages that may have multiple maintainers.

Install your package from someone else

msc add yourname/slug@0.1.0

Adds the dep to their build.ms and updates msc.lock. From their code:

import { slugify } from "yourname/slug";

Discovery

Search lives on the web UI at pkg.metascriptlang.org — filter by keyword, browse by yourname/ or @org/, see download counts. There's no msc search CLI yet; contributions welcome.

Next steps