Skip to content

Commit

Permalink
Update actions
Browse files Browse the repository at this point in the history
  • Loading branch information
julienmalard committed Jan 20, 2024
1 parent 55034b1 commit c230dd1
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 6 deletions.
9 changes: 8 additions & 1 deletion .github/workflows/npm-publish-next.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,18 @@ jobs:
with:
node-version: 'lts/*'
registry-url: https://registry.npmjs.org/
- name: Install pnpm
uses: pnpm/action-setup@v2.4.0
with:
version: latest
- run: pnpm install
- run: pnpm test
- run: git config --global user.email "bot@example.com"
- run: git config --global user.name "Github Action"
- run: |
pnpm version prerelease --no-git-tag-version \
--preid=`git rev-parse --short HEAD`
pnpm release -- --tag next
git commit package.json -m "next tag"
pnpm publish --tag next
env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}
4 changes: 4 additions & 0 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ jobs:
with:
node-version: 'lts/*'
registry-url: https://registry.npmjs.org/
- name: Install pnpm
uses: pnpm/action-setup@v2.4.0
with:
version: latest
- run: pnpm install
- run: pnpm release
env:
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# orbit-db-set
# @orbitdb/set-db
Set database type for orbit-db.

[![orbit-db-set tests](https://github.com/reseau-constellation/set/actions/workflows/run-test.yml/badge.svg?branch=main)](https://github.com/reseau-constellation/set/actions/workflows/run-test.yml)
[![codecov](https://codecov.io/gh/reseau-constellation/set/graph/badge.svg?token=7OZK4BJDej)](https://codecov.io/gh/reseau-constellation/set)

## Installation
```
$ pnpm add @orbitdb/set
$ pnpm add @orbitdb/set-db
```
## Introduction
As `Set` database is like a [`Feed`](https://github.com/reseau-constellation/set), but each value can only be present once. Works for primitive types as well as more complex objects.
Expand All @@ -16,7 +16,7 @@ As `Set` database is like a [`Feed`](https://github.com/reseau-constellation/set
A simple example with `Set`:
```ts
import { createOrbit } from "@orbitdb/core";
import { registerSet } from "@orbitdb/set";
import { registerSet } from "@orbitdb/set-db";

// Register set database type. IMPORTANT - must call before creating orbit instance !
registerSet();
Expand All @@ -37,7 +37,7 @@ await db.all() // Yay !! Still [1, 2]
As more complex example with object types:
```ts
import { createOrbit } from "@orbitdb/core";
import { registerSet } from "@orbitdb/set";
import { registerSet } from "@orbitdb/set-db";

// Register set database type. IMPORTANT - must call before creating orbit instance !
registerSet();
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "@orbitdb/set",
"name": "@orbitdb/set-db",
"version": "1.0.0",
"description": "Set database type for orbit-db.",
"author": "Julien Jean Malard-Adam",
Expand Down

0 comments on commit c230dd1

Please sign in to comment.