Skip to content

Commit

Permalink
Individual repos for kuiper databases
Browse files Browse the repository at this point in the history
  • Loading branch information
julienmalard committed Jan 19, 2024
0 parents commit b381a62
Show file tree
Hide file tree
Showing 25 changed files with 15,725 additions and 0 deletions.
52 changes: 52 additions & 0 deletions .aegir.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
import path, { dirname } from "path";
import { fileURLToPath } from "url";
import { createRequire } from "module";

const require = createRequire(import.meta.url);

const __dirname = dirname(fileURLToPath(import.meta.url));

// https://github.com/node-webrtc/node-webrtc/issues/636#issuecomment-774171409
process.on("beforeExit", (code) => process.exit(code));

// https://github.com/ipfs/aegir/blob/master/md/migration-to-v31.md
const esbuild = {
// this will inject all the named exports from 'node-globals.js' as globals
inject: [path.join(__dirname, "./scripts/node-globals.js")],
external: ["fs", "path", "os", "chokidar", "url", "zlib", "rimraf"],
plugins: [
{
name: "node built ins", // this will make the bundler resolve node builtins to the respective browser polyfill
setup(build) {
build.onResolve({ filter: /^stream$/ }, () => {
return { path: require.resolve("stream-browserify") };
});
build.onResolve({ filter: /^os$/ }, () => {
return { path: require.resolve("os-browserify") };
});
build.onResolve({ filter: /^crypto$/ }, () => {
return { path: require.resolve("crypto-browserify") };
});
build.onResolve({ filter: /^fs/ }, () => {
return { path: require.resolve("browserify-fs") };
});
},
},
],
};

/** @type {import('aegir').PartialOptions} */
const options = {
test: {
browser: {
config: {
buildConfig: esbuild,
},
},
},
build: {
config: esbuild,
},
};

export default options;
10 changes: 10 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
root = true

[*]
end_of_line = lf
insert_final_newline = true

[*.{js,ts,json,yml}]
charset = utf-8
indent_style = space
indent_size = 2
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
lib
22 changes: 22 additions & 0 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
module.exports = {
env: {
browser: true,
es2021: true,
node: true,
},
extends: [
"eslint:recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"prettier",
],
parser: "@typescript-eslint/parser",
parserOptions: {
ecmaVersion: 12,
sourceType: "module",
},
plugins: ["@typescript-eslint"],
rules: {
"@typescript-eslint/no-non-null-assertion": "off",
},
};
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/requ-te-de-fonctionnalit-.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Requête de fonctionnalité
about: Proposer une nouvelle idée
title: ''
labels: ''
assignees: ''

---

**Votre suggestion est-elle liée à un problème spécifique ? Veuillez décrire ci-dessous :**
Une explication claire, nette et précise du problème. Par exemple, "cela me frustre lorsque [...]"

**Décrire la solution telle que vous l'envisagez**
Une description claire et précise du comportement que vous préfériez voir.

**Décrire les alternatives**
Une brève description des solutions alternatives que vous avez considéré (si applicable).

**Contexte additionnel**
Vous pouvez ajouter d'autres informations ou même des prises d'écran si vous le souhaitez.
34 changes: 34 additions & 0 deletions .github/ISSUE_TEMPLATE/signaler-un-probl-me.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
name: Signaler un problème
about: Signalez-le et nous y travaillerons
title: ''
labels: ''
assignees: ''

---

**Décrire le problème**
Une description claire, nette et précise du problème.

**Comment le reproduire**
Instructions détaillées pour reproduire le problème.

**Comportement attendu**
Une brève description du comportement auquel vous vous attendez.

**Prises d'écran**
Si cela s'applique, incluez des prises d'écran du problème.

**Pour ordinateurs :**
- SO: [p. ex. iOS, Windows 11, Linux, ...]
- Navigateur [p.ex. firefox, brave, chrome, safari]
- Version [p. ex. 22]

**Pour téléphones intelligents :**
- Dispositig: [p. ex. iPhone6]
- SO: [p. ex. iOS8.1]
- Navigateur [p.ex. firefox, brave, chrome, safari]
- Version [p. ex. 22]

**Contexte additionnel**
Inclure toute autre information utile.
34 changes: 34 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Orbit-db Kuiper tests
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
tests-et-couverture:
name: Node.js test
runs-on: ubuntu-latest
steps:
- name: Préparation de Node.js
uses: actions/setup-node@v4
with:
node-version: 16

- name: Installer pnpm
uses: pnpm/action-setup@v2.4.0
with:
version: latest

- name: Ouvrir la branche
uses: actions/checkout@v4

- name: Nétoyer les dépendances d'installation
run: pnpm install --lockfile=false

- name: Vérifier les tests
run: pnpm test

- name: Envoyer couverture à Codecov
uses: codecov/codecov-action@v3
17 changes: 17 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
*.log
.DS_Store
node_modules
/dist
/.coverage
/node_modules
/.nyc_output
/.vscode
/_stockageTemp

.yarn/*
!.yarn/cache
!.yarn/patches
!.yarn/plugins
!.yarn/releases
!.yarn/sdks
!.yarn/versions
6 changes: 6 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
*.log
.DS_Store
node_modules
!dist
coverage
docu
Loading

0 comments on commit b381a62

Please sign in to comment.