Skip to content
forked from pkgxdev/pkgx

“run anything” from the creator of `brew`

License

Notifications You must be signed in to change notification settings

yoroshikun/pkgx

Repository files navigation

tea

tea is a single, standalone binary that can run anything.   coverage release-badge

 

Quickstart

brew install teaxyz/pkgs/tea-cli

 

Run Anything

$ deno
command not found: deno

$ tea deno
Deno 1.36.3
> ^D

$ deno
command not found: deno
# ^^ nothing was installed; your system remains untouched

Run Any Version of Anything

$ tea node@14 --version
Node.js v14.21.3

$ tea python@2 --version
Python 2.7.18

Run Anywhere

  • macOS
    • macOS >= 11
    • x86-64 & Apple Silicon
  • Linux
  • Windows

    WSL2; x86-64. Native windows is planned.

  • Docker
    $ tea docker run -it teaxyz/cli
    
    (docker) $ tea node@16
    Welcome to Node.js v16.20.1.
    Type ".help" for more information.
    >

    Or in a Dockerfile:

    FROM teaxyz/cli
    RUN tea [email protected] task start

    Or in any image:

    FROM ubuntu
    RUN curl https://tea.xyz | sh
    RUN tea [email protected] -m http.server 8000

    docs.tea.xyz/docker

  • CI/CD
    - uses: teaxyz/setup@v0
    - run: tea shellcheck

    Or in other CI/CD providers:

    $ curl https://tea.xyz | sh
    $ tea shellcheck

    docs.tea.xyz/ci-cd

  • Shebangs
    #!/usr/bin/env -S tea [email protected]

    docs.tea.xyz/scripts

  • Editors
    $ cd myproj
    
    myproj $ tea +cargo
    (+cargo) myproj $ code .

    Or use dev; a separate tool that uses tea primitives to automatically determine and utilize your dependencies based on your project’s keyfiles.

    $ cd myproj
    
    myproj $ dev
    ^^ type `tea` to run that
    
    myproj $ tea
    tea +dev && dev
    dev: found cargo.toml; adding ~/.tea/cargo/v* to environment
    
    (+cargo+rust) my-rust-project $ code .

    docs.tea.xyz/editors

 

Shell Integration

tea puts the whole open source ecosystem at your fingertips and its optional shell integration makes workflows with that open source even more seamless.

$ tea [email protected]
added ~/.tea/go.dev/v1.16 to environment

(+go) $ go
Go is a tool for managing Go source code.
#

(+go) $ env | grep go
PATH=~/.tea/go.dev/v1.16.15/bin:$PATH
LIBRARY_PATH=~/.tea/go.dev/v1.16.15/lib

(+go) $ tea -go
removed ~/.tea/go.dev/v1.16 from environment

$ go
command not found: go

Tools are available for the duration of your terminal session. If you need them for longer, tea install.

docs.tea.xyz/shell-integration
docs.tea.xyz/tea-install

dev

dev is a separate tool that leverages tea's core features to auto-detect and install project dependencies, seamlessly integrating them into your shell and editor.

my-rust-proj $ dev
dev: found cargo.toml; tea +cargo

(+cargo+rust) my-rust-proj $ cargo build
Compiling my-rust-proj v0.1.0
#

docs.tea.xyz/dev

 

Getting Started

brew install teaxyz/pkgs/tea-cli

no brew? docs.tea.xyz/installing-w/out-brew

Integrating with your Shell

tea integrate --dry-run   # docs.tea.xyz/shell-integration

Further Reading

docs.tea.xyz is a comprehensive manual and user guide for tea.

 

Contributing

  • To add packages see the pantry README
  • To hack on tea itself; clone it and then tea deno task to list entrypoints for hackers

If you have questions or feedback:

About

“run anything” from the creator of `brew`

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 97.9%
  • Shell 2.0%
  • Ruby 0.1%