Skip to content

Commit 39ae77e

Browse files
authored
Merge pull request #990 from waku-org/feat/split-create-waku
2 parents db1a3a4 + 613ba08 commit 39ae77e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+1452
-421
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -21,19 +21,10 @@ jobs:
2121
with:
2222
node-version: ${{ env.NODE_JS }}
2323
- uses: bahmutov/npm-install@v1
24+
- run: npm run build
2425
- run: npm run check
2526
- run: npm run doc
2627

27-
build:
28-
runs-on: ubuntu-latest
29-
steps:
30-
- uses: actions/checkout@v3
31-
- uses: actions/setup-node@v3
32-
with:
33-
node-version: ${{ env.NODE_JS }}
34-
- uses: bahmutov/npm-install@v1
35-
- run: npm run build
36-
3728
proto:
3829
runs-on: ubuntu-latest
3930
steps:
@@ -61,6 +52,7 @@ jobs:
6152
with:
6253
node-version: ${{ env.NODE_JS }}
6354
- uses: bahmutov/npm-install@v1
55+
- run: npm run build
6456
- run: npm run test:browser
6557

6658
node:
@@ -84,6 +76,7 @@ jobs:
8476
with:
8577
node-version: ${{ env.NODE_JS }}
8678
- uses: bahmutov/npm-install@v1
79+
- run: npm run build
8780
- run: npm run test:node
8881
env:
8982
DEBUG: "waku:nwaku*,waku:test*"
@@ -130,7 +123,7 @@ jobs:
130123
node-version: ${{ env.NODE_JS }}
131124

132125
- uses: bahmutov/npm-install@v1
133-
126+
- run: npm run build
134127
- run: npm run test:node
135128
env:
136129
DEBUG: "waku:nwaku*,waku:test*"
@@ -146,7 +139,7 @@ jobs:
146139
name: Release
147140
runs-on: ubuntu-latest
148141
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
149-
needs: [check, build, proto, browser, node]
142+
needs: [check, proto, browser, node]
150143
steps:
151144
- name: Checkout
152145
uses: actions/checkout@v2

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@ src/**.js
88
coverage
99
*.log
1010
*.tsbuildinfo
11+
docs

.size-limit.cjs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@ module.exports = [
77
{
88
name: "Waku default setup",
99
path: [
10-
"packages/core/bundle/index.js",
11-
"packages/core/bundle/lib/create_waku.js",
10+
"packages/create/bundle/index.js",
11+
"packages/core/bundle/lib/wait_for_remote_peer.js"
1212
],
1313
import: {
14-
"./packages/core/bundle/lib/create_waku.js": "{ createLightNode }",
14+
"./packages/create/bundle/index.js": "{ createLightNode }",
1515
"./packages/core/bundle/lib/wait_for_remote_peer.js":
1616
"{ waitForRemotePeer }",
1717
"./packages/core/bundle/lib/waku_message/version_0.js":

bors.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
status = [
22
"check",
3-
"build",
43
"proto",
54
"browser",
65
"node",

ci/deploy.js

Lines changed: 28 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,45 @@
1-
import { promisify } from 'util'
2-
import { publish } from 'gh-pages'
1+
import { promisify } from "util";
2+
3+
import { publish } from "gh-pages";
34

45
/* fix for "Unhandled promise rejections" */
5-
process.on('unhandledRejection', err => { throw err })
6+
process.on("unhandledRejection", (err) => {
7+
throw err;
8+
});
69

7-
const ghpublish = promisify(publish)
10+
const ghpublish = promisify(publish);
811

9-
const Args = process.argv.slice(2)
10-
const USE_HTTPS = Args[0] && Args[0].toUpperCase() === 'HTTPS'
12+
const Args = process.argv.slice(2);
13+
const USE_HTTPS = Args[0] && Args[0].toUpperCase() === "HTTPS";
1114

12-
const branch = 'gh-pages'
13-
const org = 'waku-org'
14-
const repo = 'js-waku'
15+
const branch = "gh-pages";
16+
const org = "waku-org";
17+
const repo = "js-waku";
1518
/* use SSH auth by default */
1619
let repoUrl = USE_HTTPS
1720
? `https://github.com/${org}/${repo}.git`
18-
: `[email protected]:${org}/${repo}.git`
21+
: `[email protected]:${org}/${repo}.git`;
1922

2023
/* alternative auth using GitHub user and API token */
2124
if (typeof process.env.GH_USER !== "undefined") {
22-
repoUrl = (
23-
'https://' + process.env.GH_USER +
24-
':' + process.env.GH_TOKEN +
25-
'@' + `github.com/${org}/${repo}.git`
26-
)
25+
repoUrl =
26+
"https://" +
27+
process.env.GH_USER +
28+
":" +
29+
process.env.GH_TOKEN +
30+
"@" +
31+
`github.com/${org}/${repo}.git`;
2732
}
2833

29-
const main = async (url, branch)=> {
30-
console.log(`Pushing to: ${url}`)
31-
console.log(`On branch: ${branch}`)
32-
await ghpublish('build/docs', {
34+
const main = async (url, branch) => {
35+
console.log(`Pushing to: ${url}`);
36+
console.log(`On branch: ${branch}`);
37+
await ghpublish("docs", {
3338
repo: url,
3439
branch: branch,
3540
dotfiles: true,
36-
silent: false
37-
})
38-
}
41+
silent: false,
42+
});
43+
};
3944

40-
main(repoUrl, branch)
45+
main(repoUrl, branch);

0 commit comments

Comments
 (0)