Skip to main content

CLI wrapper for Mojo with automatic package discovery

Project description

mojox

CLI wrapper for Mojo with automatic package discovery.

mojox is ~15 lines of Python. On every invocation it:

  1. Finds <site-packages>/mojo_packages/ via sysconfig.
  2. Injects -I so mojo sees installed .mojoc / .mojopkg files.
  3. Augments LD_LIBRARY_PATH / DYLD_LIBRARY_PATH for native libs in <pkg>/lib.
  4. Hands off to mojo._entrypoints.exec_mojo (the same entry point the bundled mojo binary uses).

Install

uv add mojox                # in a project
uv tool install mojox       # globally

mojox depends on mojo-compiler, which is installed automatically.

Usage

uv run mojox run my_app.mojo
uv run mojox build my_app.mojo
uv run mojox test tests/
uv run mojox precompile my_lib -o my_lib.mojoc   # `package … -o …mojopkg` on Mojo < 1.0

Subcommands that get -I injected: run, build, precompile, package, test, repl, doc, format, debug.

Top-level flags (mojox --version, etc.) pass through untouched.

See also

  • mojox-build — PEP 517 build backend so Mojo libraries can be packaged as wheels and consumed via uv add.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mojox-0.3.0.tar.gz (2.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mojox-0.3.0-py3-none-any.whl (3.2 kB view details)

Uploaded Python 3

File details

Details for the file mojox-0.3.0.tar.gz.

File metadata

  • Download URL: mojox-0.3.0.tar.gz
  • Upload date:
  • Size: 2.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.23 {"installer":{"name":"uv","version":"0.11.23","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for mojox-0.3.0.tar.gz
Algorithm Hash digest
SHA256 43fae83725d3cdc0ba8afb01bc7aafbedb49883c77f6629ddd61625621d684f0
MD5 499bbd6d4c928c17d3aa5753c2566e54
BLAKE2b-256 5899ac9360b6397837372693eae6e33956e4fd791140ca0bf9e1f435acdfd6e4

See more details on using hashes here.

File details

Details for the file mojox-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: mojox-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 3.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.23 {"installer":{"name":"uv","version":"0.11.23","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for mojox-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2eafb29829d2521a67d4ccc1abbd033a3f8f6ad51f61986213ddbe76f513fd1c
MD5 be2c02f054c78ef70e170e3de0d63d0d
BLAKE2b-256 204eb7dc8bd6c38e561de67bb386b8da4559c2857f0bd04c6474748f6962b93a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page