# generator-generator-lib

> Generate raw assets for other generators

Latest version **0.5.0** (published 2018-01-28) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install generator-generator-lib
pnpm add generator-generator-lib
yarn add generator-generator-lib
bun add generator-generator-lib
```

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 0.5.0 |
| Published | 2018-01-28 |
| First published | 2018-01-28 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 6 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | alechp |
| Maintainers | alechp |

## Links

- npm: https://www.npmjs.com/package/generator-generator-lib
- Repository: git@alechp:servexyz/generator-generator-lib
- npm.io page: https://npm.io/package/generator-generator-lib

## Dependencies (6)

- [chalk](https://npm.io/package/chalk.md) ^2.3.0
- [lowdb](https://npm.io/package/lowdb.md) ^1.0.0
- [moment](https://npm.io/package/moment.md) ^2.20.1
- [fs-extra](https://npm.io/package/fs-extra.md) ^5.0.0
- [is-empty](https://npm.io/package/is-empty.md) ^1.2.0
- [content-genesis](https://npm.io/package/content-genesis.md) ^0.5.4

## Recent versions

- 0.5.0 (latest) — 2018-01-28

## README

# file-genesis

[![Build Status](https://travis-ci.org/servexyz/file-genesis.svg?branch=master)](https://travis-ci.org/servexyz/file-genesis)

## Install

---

```js
yarn add file-genesis
```

---

## Use

---

```js
const path = require("path");
const { File } = require("file-genesis");
const gitignore = `
  .DS_Store
  node_modules
`;

file.create(path.join(__dirname, ".gitignore")).plain(gitignore);
```

> Note: Prettier is used for formatting during creation

---

## API

---

### `.plain()`, `.symlink()`, `.template()`

> This is used to specify the type and pass content

**plain**

```js
File("/path/to/file.ext").plain("content");
```

**symlink**

```js
File("/path/to/file.ext").symlink("/path/to/src", "/path/to/dest");
```

**template**

```js
let variables = { replaceMe: "withThisValue" };
File("/path/to/file.ext").template("path/to/template.ext", variables);
```

---

## Docs

---

* [api-brainstorm](./docs/api-brainstorm.md)
  > Multiple brainstorming attempts & old README content
* [debug](./docs/debug.md)
  > Documented debugging
* [resources](./docs/resources.md)
  > 3rd party API's
* [todo](./docs/todo.md)
  > Features & bugs by version

---

## Goals

---

* consistent api for symlinks, plain UTF-8 files and templates
* interoperable with content-genesis

---

## Related

---

* [content-genesis](https://github.com/servexyz/content-genesis)

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