# build-path

> Get a path for the given build.

Latest version **1.0.0** (published 2017-02-03) · MPL-2.0 license · 0 weekly downloads

## Install

```sh
npm install build-path
pnpm add build-path
yarn add build-path
bun add build-path
```

## 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.0 |
| Published | 2017-02-03 |
| First published | 2016-09-08 |
| Weekly downloads | 0 |
| License | MPL-2.0 |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=6 |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Seth Holladay |
| Maintainers | sholladay |
| Keywords | compile, build, builds, branch, version, path, paths, dir, dirs, directory, directories, tooling |

## Links

- npm: https://www.npmjs.com/package/build-path
- Repository: https://github.com/sholladay/build-path
- Issues: https://github.com/sholladay/build-path/issues
- npm.io page: https://npm.io/package/build-path

## Alternatives

- [base64url](https://npm.io/package/base64url.md) — 6.1M weekly downloads
- [get-installed-path](https://npm.io/package/get-installed-path.md) — 502.9K weekly downloads
- [@uppy/url](https://npm.io/package/@uppy/url.md) — 185.8K weekly downloads
- [@d3fc/d3fc-shape](https://npm.io/package/@d3fc/d3fc-shape.md) — 16.2K weekly downloads
- [localizer](https://npm.io/package/localizer.md) — 226 weekly downloads

## Recent versions

- 1.0.0 (latest) — 2017-02-03
- 0.1.1 — 2017-01-30
- 0.1.0 — 2016-09-08

## README

# build-path [![Build status for build-path on Circle CI.](https://img.shields.io/circleci/project/sholladay/build-path/master.svg "Circle Build Status")](https://circleci.com/gh/sholladay/build-path "Build Path Builds")

> Get a path for the given build.

## Why?

 - Asserts that all necessary metadata is present.
 - Uses relative paths for flexibility.
 - Platform and technology agnostic.

## Install

```sh
npm install build-path --save
```

## Usage

Get it into your program.

```js
const buildPath = require('build-path');
```

Get the path where a given build should live.

```js
const path = buildPath({
    branch : 'master',
    version : '1.0.0'
});

console.log(path);  // => build/master/1.0.0
```

Build paths cannot be constructed with incomplete data.

```js
buildPath({ version : '1.0.0' });
// TypeError: A branch is required to create the build path.
```

## API

### buildPath(option)

#### option

Type: `object`

[Build data](https://github.com/sholladay/build-data).

##### branch

Type: `string`

The branch name of the build.

##### version

Type: `string`

The version of the build.

## Related

 - [delivr](https://github.com/sholladay/delivr) - Build your code and ship it to S3.
 - [build-files](https://github.com/sholladay/build-files) - Read the files from your build.
 - [build-keys](https://github.com/sholladay/build-keys) - Get the paths of files from your build.
 - [build-dir](https://github.com/sholladay/build-dir) - Get a place to put your build.
 - [build-data](https://github.com/sholladay/build-data) - Get metadata for your build.
 - [build-version](https://github.com/sholladay/build-version) - Get a version for your build.

## Contributing

See our [contributing guidelines](https://github.com/sholladay/build-path/blob/master/CONTRIBUTING.md "The guidelines for participating in this project.") for more details.

1. [Fork it](https://github.com/sholladay/build-path/fork).
2. Make a feature branch: `git checkout -b my-new-feature`
3. Commit your changes: `git commit -am 'Add some feature'`
4. Push to the branch: `git push origin my-new-feature`
5. [Submit a pull request](https://github.com/sholladay/build-path/compare "Submit code to this project for review.").

## License

[MPL-2.0](https://github.com/sholladay/build-path/blob/master/LICENSE "The license for build-path.") © [Seth Holladay](http://seth-holladay.com "Author of build-path.")

Go make something, dang it.

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