sockethub 5.0.0-alpha.3 → 5.0.0-alpha.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,12 @@
1
+ # Sockethub
2
+
3
+ Sockethub server
4
+
5
+ ## About
6
+
7
+ Server code for the sockethub service, this can be called directly, though is usually called from the
8
+ parent `sockethub` package, which includes all of the dependencies and platforms.
9
+
10
+ This can be used individually if you wish to pick and choose other dependencies.
11
+
12
+ For full sockethub documentation see the [Sockethub README](../sockethub/README.md)
package/bin/sockethub CHANGED
@@ -1,3 +1,4 @@
1
- #!/usr/bin/env node
2
- const sockethubServer = require('@sockethub/server');
3
- sockethubServer();
1
+ #!/usr/bin/env bun
2
+ import("@sockethub/server").then((sockethub) => {
3
+ sockethub.server();
4
+ });
package/build.js CHANGED
@@ -1,21 +1,12 @@
1
-
2
- const fs = require('fs');
3
- const packageJSON = require('./package.json');
1
+ /* eslint-disable @typescript-eslint/no-require-imports */
2
+ const packageJSON = require("./package.json");
4
3
  const moduleList = Object.keys(packageJSON.dependencies);
5
4
 
6
- const rx = new RegExp('^@sockethub/platform-', 'i');
5
+ const rx = /^@sockethub\/platform-/i;
7
6
  const platforms = [];
8
7
 
9
- for (let moduleName of moduleList) {
10
- if (rx.test(moduleName)) {
11
- platforms.push(moduleName);
12
- }
8
+ for (const moduleName of moduleList) {
9
+ if (rx.test(moduleName)) {
10
+ platforms.push(moduleName);
11
+ }
13
12
  }
14
-
15
- const data = fs.readFileSync(
16
- 'node_modules/@sockethub/server/sockethub.config.example.json', 'utf8');
17
- const config = JSON.parse(data);
18
- config.platforms = platforms;
19
-
20
- fs.writeFileSync(
21
- './sockethub.config.json', data);
package/package.json CHANGED
@@ -1,13 +1,16 @@
1
1
  {
2
2
  "name": "sockethub",
3
3
  "description": "A polyglot messaging service",
4
- "version": "5.0.0-alpha.3",
4
+ "version": "5.0.0-alpha.6",
5
5
  "private": false,
6
6
  "author": "Nick Jennings <nick@silverbucket.net>",
7
7
  "license": "LGPL-3.0+",
8
8
  "main": "",
9
9
  "bin": "bin/sockethub",
10
10
  "preferGlobal": true,
11
+ "engines": {
12
+ "bun": ">=1.2.4"
13
+ },
11
14
  "keywords": [
12
15
  "sockethub",
13
16
  "messaging",
@@ -34,20 +37,17 @@
34
37
  },
35
38
  "homepage": "https://sockethub.org",
36
39
  "dependencies": {
37
- "@sockethub/platform-dummy": "^3.0.0-alpha.3",
38
- "@sockethub/platform-feeds": "^3.0.0-alpha.3",
39
- "@sockethub/platform-irc": "^4.0.0-alpha.3",
40
- "@sockethub/platform-xmpp": "^5.0.0-alpha.3",
41
- "@sockethub/server": "^5.0.0-alpha.3"
40
+ "@sockethub/platform-dummy": "3.0.0-alpha.6",
41
+ "@sockethub/platform-feeds": "4.0.0-alpha.6",
42
+ "@sockethub/platform-irc": "4.0.0-alpha.6",
43
+ "@sockethub/platform-xmpp": "5.0.0-alpha.6",
44
+ "@sockethub/server": "5.0.0-alpha.6"
42
45
  },
43
46
  "scripts": {
44
- "build": "node build.js && test -f sockethub.config.json",
45
- "clean:deps": "npx rimraf node_modules",
46
- "dev": "DEBUG=sockethub* ./bin/sockethub --examples -c sockethub.config.json",
47
- "start": "DEBUG=sockethub* ./bin/sockethub -c sockethub.config.json"
48
- },
49
- "engines": {
50
- "node": ">= 12.4.0"
47
+ "build": "bun build.js",
48
+ "dev": "DEBUG=sockethub* bun run --hot ./bin/sockethub --examples",
49
+ "info": "DEBUG=sockethub* bun run ./bin/sockethub --info",
50
+ "start": "DEBUG=sockethub* bun run ./bin/sockethub"
51
51
  },
52
- "gitHead": "f02238a478b7ffd3f31d8deea292eb67e630a86b"
52
+ "gitHead": "f8a937e071e7a209f94b94f63e68faa27784e00e"
53
53
  }
@@ -0,0 +1,7 @@
1
+ {
2
+ "$schema": "https://sockethub.org/schemas/3.0.0-alpha.4/sockethub-config.json",
3
+ "sentry": {
4
+ "dsn": "https://ffc702eb2f3b24d9e06ca20e1ef1fd09@o4508859714895872.ingest.de.sentry.io/4508859718369360",
5
+ "environment": "production"
6
+ }
7
+ }
@@ -1,33 +0,0 @@
1
- {
2
- "activity-streams": {
3
- "opts": {
4
- "specialObjs": [ "credentials" ]
5
- }
6
- },
7
- "examples": {
8
- "enabled": false,
9
- "secret": 1234567890
10
- },
11
- "sockethub": {
12
- "port": 10550,
13
- "host": "localhost",
14
- "path": "/sockethub"
15
- },
16
- "log_file": "",
17
- "platforms": [
18
- "@sockethub/platform-dummy",
19
- "@sockethub/platform-feeds",
20
- "@sockethub/platform-irc",
21
- "@sockethub/platform-xmpp"
22
- ],
23
- "public": {
24
- "protocol": "http",
25
- "host": "localhost",
26
- "port": 10550,
27
- "path": "/"
28
- },
29
- "redis": {
30
- "host": "127.0.0.1",
31
- "port": 6379
32
- }
33
- }
package/tsconfig.json DELETED
@@ -1,17 +0,0 @@
1
- {
2
- "extends": "../../tsconfig.base.json",
3
- "compilerOptions": {
4
- "allowJs": false,
5
- "outDir": "dist",
6
- "rootDir": "src",
7
- "baseUrl": "/",
8
- "sourceRoot": "/",
9
- "mapRoot": "/",
10
- },
11
- "include": [
12
- "src"
13
- ],
14
- "exclude": [
15
- "**/*.test.ts"
16
- ]
17
- }