{"id":15569170,"url":"https://github.com/dan-online/brinedb","last_synced_at":"2025-04-24T00:20:41.226Z","repository":{"id":232001675,"uuid":"783043400","full_name":"dan-online/brinedb","owner":"dan-online","description":"SeaORM wrapper for NodeJS, providing basic key/value storage in SQLite/Postgres/MySQL/MariaDB","archived":false,"fork":false,"pushed_at":"2025-04-20T08:36:01.000Z","size":9986,"stargazers_count":1,"open_issues_count":4,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-20T09:44:59.218Z","etag":null,"topics":["database","key-value","kv","mariadb","mysql","nodejs","postgres","seaorm","sqlite","storage"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dan-online.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":["dan-online"]}},"created_at":"2024-04-06T19:29:40.000Z","updated_at":"2025-04-20T08:34:51.000Z","dependencies_parsed_at":"2024-05-05T02:28:23.084Z","dependency_job_id":"2068fa6a-62ae-40d0-97fd-59737d2a4e81","html_url":"https://github.com/dan-online/brinedb","commit_stats":{"total_commits":101,"total_committers":2,"mean_commits":50.5,"dds":0.3465346534653465,"last_synced_commit":"5f64244f24f9210b100912ce479d55e9fdbf1a65"},"previous_names":["dan-online/brinedb"],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dan-online%2Fbrinedb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dan-online%2Fbrinedb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dan-online%2Fbrinedb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dan-online%2Fbrinedb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dan-online","download_url":"https://codeload.github.com/dan-online/brinedb/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250536020,"owners_count":21446662,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["database","key-value","kv","mariadb","mysql","nodejs","postgres","seaorm","sqlite","storage"],"created_at":"2024-10-02T17:22:23.661Z","updated_at":"2025-04-24T00:20:41.206Z","avatar_url":"https://github.com/dan-online.png","language":"TypeScript","funding_links":["https://github.com/sponsors/dan-online"],"categories":[],"sub_categories":[],"readme":"![npm version](https://img.shields.io/npm/v/@brine-db/brine)\n\n# BrineDB\n\n[SeaORM](https://www.sea-ql.org/SeaORM/) wrapper for NodeJS, providing basic key/value storage in SQLite/Postgres/MySQL/MariaDB.\n\n## Table of contents\n\n- [BrineDB](#brinedb)\n  - [Table of contents](#table-of-contents)\n  - [Getting Started](#getting-started)\n  - [Installation](#installation)\n  - [Quick Start](#quick-start)\n  - [Typescript](#typescript)\n  - [Development](#development)\n    - [Prerequisites](#prerequisites)\n    - [Building the entire package](#building-the-entire-package)\n  - [Contributing](#contributing)\n  - [Built With](#built-with)\n  - [Versioning](#versioning)\n  - [Authors](#authors)\n  - [License](#license)\n\n## Getting Started\n\n## Installation\n\nTo install and set up the library, run:\n\n```sh\n$ yarn add @brine-db/brine\n```\n\nOr if you prefer npm:\n\n```sh\n$ npm i @brine-db/brine\n```\n\n## Quick Start\n\n```js\nconst { Brine } = require('@brine-db/brine');\n\n// SQLite\nconst brinedb = new Brine('sqlite::memory:');\nconst brinedb = new Brine('sqlite:/path/to/database.sqlite');\n\n// Postgres\nconst brinedb = new Brine('postgres://user:pass@localhost:5432/dbname');\n\n// MySQL/MariaDB\nconst brinedb = new Brine('mysql://user:pass@localhost:3306/dbname');\n\n// Initialize the database (also runs migrations)\nawait brinedb.init();\n\n// Set a value\nawait brinedb.set('key', { hello: 'world' });\n\n// Get a value\nconst value = await brinedb.get('key');\n```\n\n## Typescript\n\nThis library is written in Typescript and includes type definitions. Here is an example that will be typed correctly:\n\n```ts\nimport { Brine } from '@brine-db/brine';\n\ntype Value = { hello: string }\n\nconst brinedb = new Brine\u003cValue\u003e('sqlite::memory:');\n\nawait brinedb.set('key', { hello: 'world' });\n\nconst decoded = brinedb.get('key');\n\ntypeof decoded.hello; // string\n```\n\n## Development\n\n### Prerequisites\n\nThis project requires NodeJS (version 18 or later) and yarn.\n[Node](http://nodejs.org) and [Yarn](https://yarnpkg.com/) are really easy to install.\nTo make sure you have them available on your machine,\ntry running the following command.\n\n```sh\n$ yarn -v \u0026\u0026 node -v \u0026\u0026 rustc --version # Example output\n3.6.3\nv20.11.1\nrustc 1.78.0-nightly (4a0cc881d 2024-03-11)\n```\n\n### Building the entire package\n\n_Requirement: Rust is installed on your machine._\n\n```sh\n$ yarn build\n```\n\nThis task will create a distribution version of the project\ninside your local `dist/` folder and output a binary in `native/`\n\n## Contributing\n\n1.  Fork it!\n2.  Create your feature branch: `git checkout -b my-new-feature`\n3.  Add your changes: `git add .`\n4.  Commit your changes: `git commit -am 'Add some feature'`\n5.  Push to the branch: `git push origin my-new-feature`\n6.  Submit a pull request :sunglasses:\n\n## Built With\n\n- [Napi-RS](https://napi.rs/)\n- [SeaORM](https://www.sea-ql.org/SeaORM/)\n- VSCode\n- TypeScript\n- Rust\n\n## Versioning\n\nWe use [SemVer](http://semver.org/) for versioning. For the versions available, see the [tags on this repository](https://github.com/dan-online/brinedb/tags).\n\n## Authors\n\n- **DanCodes** - [@dan-online](https://github.com/dan-online) - \u003cdan@dancodes.online\u003e\n\n## License\n\n[MIT License](https://dancodes.mit-license.org/2024) © DanCodes\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdan-online%2Fbrinedb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdan-online%2Fbrinedb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdan-online%2Fbrinedb/lists"}