open-index/open-npm huggingface dataset:
npm package: @sixty-nine/cli-tools
Description: A reusable TypeScript library for CLI tools.
Author: Daniele Barsotti
Latest version: 1.0.1

# @sixty-nine/cli-tools

## Description
A opinionated reusable TypeScript library for CLI tools.

## Installation

You can install this package using `yarn` or `npm`:

```bash
yarn add @sixty-nine/cli-tools
# or
npm install @sixty-nine/cli-tools
```

## Usage

This library provides a set of utilities to build command-line interfaces. Here's how to use it:

```typescript
import useCli from '@sixty-nine/cli-tools';

const cli = useCli();

cli.title('My Awesome CLI Tool');
cli.subtitle('A list of items');
cli.list(['item 1', 'item 2', 'item 3'], (s) => chalk.white(s));

cli.subtitle('A table of data');
const headers = ['Name', 'Age', 'City'].map((s) => chalk.yellow(s));
const rows = [
  ['John Doe', 30, 'New York'],
  ['Jane Doe', 25, 'London'],
];
cli.table(headers, rows);

cli.error('Something went wrong!');
```

## Development

To set up the development environment, build, lint, and format the code, use the following commands:

1.  **Install dependencies:**
    ```bash
    yarn install
    ```

2.  **Build the project:**
    ```bash
    yarn build
    ```

3.  **Lint the code:**
    ```bash
    yarn lint
    ```

4.  **Format the code:**
    ```bash
    yarn format
    ```

## Contributing
Contributions are welcome! Please follow the existing code style and ensure your changes pass linting and formatting checks.

## License
This project is licensed under the MIT License.