# foundry-js

> The foundry binary published to npmjs.

Latest version **1.0.128** (published 2024-02-22) · ISC license · 0 weekly downloads

## Install

```sh
npm install foundry-js
pnpm add foundry-js
yarn add foundry-js
bun add foundry-js
```

Provides the commands `cast`, `anvil`, `forge`, `chisel`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.128 |
| Published | 2024-02-22 |
| First published | 2024-02-12 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 8.2 KB |
| Known vulnerabilities | 0 (+15 in 2 direct dependencies) |
| Install scripts | no |
| GitHub stars | 2 |
| Author | Soptq |
| Maintainers | soptq |

## Links

- npm: https://www.npmjs.com/package/foundry-js
- Repository: https://github.com/Soptq/foundry-js
- Issues: https://github.com/Soptq/foundry-js/issues
- npm.io page: https://npm.io/package/foundry-js

## Dependencies (3)

- [tar](https://npm.io/package/tar.md) ^6.2.0
- [adm-zip](https://npm.io/package/adm-zip.md) ^0.5.10
- [node-fetch](https://npm.io/package/node-fetch.md) ^2.7.0

## Recent versions

- 1.0.128 (latest) — 2024-02-22
- 1.0.212 (nightly-0.2.0) — 2024-04-27
- 1.0.209 (nightly-0.2.0-d431f74) — 2024-04-27
- 1.0.208 (nightly-0.2.0-008922d) — 2024-04-23
- 1.0.207 (nightly-0.2.0-4603195) — 2024-04-10
- 1.0.206 (nightly-0.2.0-f625d0f) — 2024-04-03
- 1.0.201 (nightly-0.2.0-d94e3c6) — 2024-03-31
- 1.0.199 (nightly-0.2.0-d1ab09d) — 2024-03-30
- 1.0.197 (nightly-0.2.0-617dfc2) — 2024-03-29
- 1.0.195 (nightly-0.2.0-9881e7d) — 2024-03-28
- 1.0.193 (nightly-0.2.0-9148dbc) — 2024-03-27
- 1.0.191 (nightly-0.2.0-563e062) — 2024-03-26
- 1.0.189 (nightly-0.2.0-88e09f6) — 2024-03-25
- 1.0.186 (nightly-0.2.0-f9da73d) — 2024-03-23
- 1.0.184 (nightly-0.2.0-c2233ec) — 2024-03-22
- … 195 more at https://npm.io/package/foundry-js/versions

## README

# foundry-js

The foundry binary published to npmjs. See all the available versions [here](https://www.npmjs.com/package/foundry-js?activeTab=versions).

## Install

```bash
npm install foundry-js@nightly

# or install globally
# npm install -g foundry-js@nightly-0.2.0
# or specify a release tag (version)
# npm install foundry-js@nightly-0.2.0-a170021
```

## Usage

If installed globally:

```bash
forge -V

# forge 0.2.0 (a170021 2024-02-16T00:17:36.445247161Z)
```

If installed locally:

```bash
npx forge -V

# forge 0.2.0 (a170021 2024-02-16T00:17:36.445247161Z)
```

## Development
### Set up the Github Actions

1. Clone the repository.
2. Change the package name in `package.json`. Don't alter the version (leave it to 1.0.0), as the version will be self managed by the Github Actions.
3. Add your npm token to the Github Actions repository secrets: NODE_AUTH_TOKEN = <your-npm-token>.

### Publish workflow

1. `.github/workflows/publish.yml` is triggered either scheduled-ly or manually.
2. This workflow will set the npm token and execute `ci.sh`.
3. In `ci.sh`, it will fetch all releases of `foundry`, and check if there is a new release. 
4. If there is, it will download the pre-compiled binary using `download.js` and publish it to npm.
5. `bin/<>-delegate.sh` (e.g., `bin/forge-delegate.sh`) will link the pre-compiled binary to the PATH while installing the package, and handle different architectures (currently support linux-amd64, linux-arm64, darwin-amd64 and darwin-arm64).

---
_Source: https://npm.io/package/foundry-js · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
