# @launchql/base32

> base32

Latest version **0.4.6** (published 2021-04-25) · 0 weekly downloads

## Install

```sh
npm install @launchql/base32
pnpm add @launchql/base32
yarn add @launchql/base32
bun add @launchql/base32
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.4.6 |
| Published | 2021-04-25 |
| First published | 2020-11-24 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 32.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Web, Inc. |
| Maintainers | pyramation |

## Links

- npm: https://www.npmjs.com/package/@launchql/base32
- npm.io page: https://npm.io/package/@launchql/base32

## Recent versions

- 0.4.6 (latest) — 2021-04-25
- 0.4.5 — 2021-04-23
- 0.4.4 — 2021-04-23
- 0.4.3 — 2021-04-23
- 0.4.2 — 2021-04-23
- 0.4.1 — 2021-04-23
- 0.4.0 — 2021-04-23
- 0.3.6 — 2021-04-23
- 0.3.5 — 2021-04-21
- 0.3.4 — 2021-04-21
- 0.3.3 — 2021-04-20
- 0.3.2 — 2021-04-20
- 0.3.1 — 2021-04-17
- 0.3.0 — 2021-04-15
- 0.2.1 — 2021-04-14
- … 31 more at https://npm.io/package/@launchql/base32/versions

## README

# base32 [![Build Status](https://travis-ci.com/pyramation/base32.svg?branch=master)](https://travis-ci.com/pyramation/base32)

RFC4648 Base32 encode/decode in plpgsql

# Usage

```sql
select base32.encode('foo');
-- MZXW6===


select base32.decode('MZXW6===');
-- foo
```

# credits

Thanks to 

https://tools.ietf.org/html/rfc4648

https://www.youtube.com/watch?v=Va8FLD-iuTg

# Development

## start the postgres db process

First you'll want to start the postgres docker (you can also just use `docker-compose up -d`):

```sh
make up
```

## install modules

Install modules

```sh
yarn install
```

## install the Postgres extensions

Now that the postgres process is running, install the extensions:

```sh
make install
```

This basically `ssh`s into the postgres instance with the `packages/` folder mounted as a volume, and installs the bundled sql code as pgxn extensions.

## testing

Testing will load all your latest sql changes and create fresh, populated databases for each sqitch module in `packages/`.

```sh
yarn test:watch
```

## building new modules

Create a new folder in `packages/`

```sh
lql init
```

Then, run a generator:

```sh
lql generate
```

You can also add arguments if you already know what you want to do:

```sh
lql generate schema --schema myschema
lql generate table --schema myschema --table mytable
```

## deploy code as extensions

`cd` into `packages/<module>`, and run `lql package`. This will make an sql file in `packages/<module>/sql/` used for `CREATE EXTENSION` calls to install your sqitch module as an extension.

## recursive deploy

You can also deploy all modules utilizing versioning as sqtich modules. Remove `--createdb` if you already created your db:

```sh
lql deploy awesome-db --yes --recursive --createdb
```

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