Skip to content

Commit b72d4b0

Browse files
su-changhuanwindmemory陶鑫lijiarui
authored
merge master (#20)
* 0.45.3 * 0.45.4 * upgrade puppet to use async-map-like memory-card * upgrade puppet * 0.45.5 * build onbuild docker image * 0.45.6 * test for onbuild home dir * 0.45.7 * deploy wechaty/onbuld * fix test for both wechaty & /bot * 0.45.8 * publish to wechaty/wechatyh * 0.45.9 * build with onbuld * 0.45.10 * rename zixia/wechaty -> wechaty/wechaty * 0.45.11 * fix typo * 0.45.12 * fix onbuild npm run * 0.45.13 * update official example * Update README.md * fix asscessory tests, and protect user class constructor from public to private * Increase MaxListener for Wechaty * 0.45.14 * add plugin uninstaller logic * 0.45.15 * fix race condition for plugin uninstallation * 0.45.16 * template clean * 0.45.17 * upgrade puppet * 0.46.0 * 0.46.1 * add new puppet for official account * 0.46.2 * Wechaty is a Conversational SDK for Chatbot Makers * fix bio * 0.46.3 * clean log message * 0.46.4 * upgrade hostie * 0.45.6 * 0.46.5 * 0.47.0 * 0.47.1 * support onbuild:version * 0.47.2 * use artifact image name * 0.47.3 * clean version & tag * 0.47.4 * 0.47.5 * fix hostie start bug * 0.47.6 * clean * 0.46.5 * 0.47.7 * add svg logos * use wechaty.js.org host * 0.47.7 * 0.47.8 * update * 0.47.9 * use docker for changelog * 0.47.10 * update changelog * 0.47.11 * use wechaty.js.org/qrcode/ to replace wechaty.github.io/qrcode/ * 0.47.12 * Update README.md * feat: add scoped wxwork puppet into puppet config (wechaty#2043) * add scoped wxwork puppet into puppet config * skip install scoped puppet * 0.47.13 * add phone method in contact class (wechaty#2039) * add phone method in contact class * 0.47.13 * 0.47.14 * update wechaty-puppet version * add jsdoc for contact.phone * use puppet.dirtyPayload (wechaty/puppet-service#43) * 0.47.15 * fix dirty exception * 0.47.16 * TODO: implement the dirty logic (wechaty/puppet-service#43) * 0.47.17 * TODO: implement the dirty logic (wechaty/puppet-service#43) * 0.47.18 * implement the dirty logic (wechaty/puppet-service#43) * 0.47.19 * clean * 0.47.20 * remove deprecated methods (wechaty#2049) * 0.47.21 * Upgrade to TypeScript 4.0! * 0.47.22 * feat: add more methods into contact class (wechaty#2048) * add more methods into contact class * fix code with new wechaty-puppet * 0.47.21 * 0.47.23 * throw a nice error message when we call user module before start wechaty * 0.47.24 * 0.48.0 (wechaty#2050) * bump hostie version to be the stable one (wechaty#2051) * bump hostie version to be the stable one * 0.48.1 * link images to wechaty.js.org * update links * 0.48.2 * update jsdocs * 0.48.3 * add gitter puppet * 0.48.4 * fix typo * 0.48.5 * add location user module * 0.47.25 * 0.48.6 * clean * 0.48.7 * add telegram channel for wechaty * 0.48.8 * add bibtex cite code * 0.48.9 * add star history badge * 0.48.10 * Split to trunks when making requests of room.findAll() and room.ready() (wechaty#2067) * add pagination on room.findAll() and room.ready() * 0.48.11 * fix wechaty#2073 (wechaty#2074) * fix wechaty#2073 * 0.48.12 * 0.48.13 * Bump minor 49 (wechaty#2078) * 0.49.0 * update hostie version to take advantage of the new stream grpc methods * fix io client qrcode by encodeURIComponent * 0.48.11 * upgrade deps * 0.49.1 * upgrade puppet to v0.33 * 0.49.2 * 0.49.3 * 0.49.4 * fix typos * 0.49.5 * clean * Update README.md * add credit link * fix typo * upgrade json-rpc-peer to v0.17 * 0.49.7 * 0.49.8 * Update Dockerfile (wechaty#2079) 按照 wechaty#1986 的方法用docker创建Hostie Token时,docker端报错。加入libxtst6库后可以完美运行。 * 0.50.0 * 0.50.1 * clean scan payload after login * 0.50.2 * enable io sync message botie support * 0.50.3 * use source for botie payload * 0.50.4 * add whatsapp to official puppet names (wechaty/puppet-whatsapp#1) * 0.50.5 * use a helper function for better FileBox instance check (wechaty/puppet-service#99) * 0.50.6 * loost Puppet instance type checking (wechaty#2024) * 0.50.7 * create looseInstanceOfClass (wechaty#2090) (wechaty#2091) * create looseInstanceOfClass (wechaty#2090) * 0.50.8 * 0.51.0 * 0.51.1 * fix file-box * fix file-box * 0.51.2 * rename from -> talker (wechaty#2094) * 0.51.3 * add gitter & deprecate padplus * strict typing check for typescript v4 * 0.51.4 * Update contact.ts (wechaty#2095) fix: return payload friend * rename from() to talker() from message * 0.51.5 * Update README.md * Update README.md * Update README.md * Update README.md * add wechaty-puppet-padlocal to the puppet config (wechaty#2102) * 0.51.6 * 0.51.7 * remove padplus from smoke testing (wechaty#2087) * 0.51.8 * add url link unit test * 0.51.9 * add strict check * clean * 0.51.10 * Update room-invitation.ts (wechaty#2104) topic() returns a Promise<string> instead of Promise<Contact>. The document is incorrect. * add puppet event to emitter typing * 0.51.11 * add puppet to wechaty event names * Working on RxJS related deps * 0.53.1 * Rename NODE_AUTH_TOKEN -> NPM_TOKEN * Use Debian instead of Ubuntu for our Docker (wechaty#2114) * 0.53.2 * Update Node.js v12 -> v14 (wechaty#2115) * 0.53.3 * RPA SDK * RPA SDK * use cache to speed up github action * use cache for node & npm * 0.53.4 * node v15 not support grpc yet * 0.53.5 * Update package.json * Upgrade pkg-jq * use better cache for gh actions * 0.53.6 * 0.53.7 * Update README.md (wechaty#2118) change puppet service provider link * use naive hashFile * 0.53.8 * fix typo * 0.53.9 * rename wechaty-puppet-hostie -> wechaty-puppet-service (wechaty#2124) * add deprecate warning message for WECHATY_HOSTIE_PORT (wechaty#2122) * 0.55.1 * 0.56.0 * 0.56.1 * Changelog for v0.56 * compatible with wechaty-puppet-hostie module name (wechaty/puppet-service#118) * 0.56.2 * use node v12 instead of v14 in docker image for maximum compatibility. (e.g. huggingface/tokenizers#603) * 0.56.3 * 0.57.0 * default puppet: service (wechaty#2127) * 0.57.1 * upgrade wechaty-puppet to v0.34 * 0.57.2 * change default puppet to puppet-service * 0.57.3 * upgrade deps * 0.57.4 * fix docker deploy for branches * 0.57.5 * pass custom server host to io server (wechaty#2138) * pass custom server host to io server * fix test * modify code according to comments * 0.57.6 * support puppet lark (wechaty/puppet-lark#4) * 0.57.7 * clean * 0.57.8 * use npm-run-all * 0.57.9 * specific puppet versions * 0.57.10 * upgrade upppeteer version * 0.57.11 Co-authored-by: Huan LI (李卓桓) <[email protected]> Co-authored-by: Yuan Gao <[email protected]> Co-authored-by: 陶鑫 <[email protected]> Co-authored-by: lijiarui <[email protected]> Co-authored-by: profthecopyright <[email protected]>
1 parent a4ca72a commit b72d4b0

File tree

117 files changed

+4720
-2221
lines changed

Some content is hidden

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

117 files changed

+4720
-2221
lines changed

.circleci/config.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
- run:
1414
name: Install Node.js
1515
command: |
16-
curl --silent --location https://rpm.nodesource.com/setup_10.x | sudo bash -
16+
curl --silent --location https://rpm.nodesource.com/setup_12.x | sudo bash -
1717
sudo yum -y install nodejs
1818
1919
- run:

.github/CODEOWNERS

+1-2
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,4 @@
22
# https://help.github.com/articles/about-codeowners/
33
#
44

5-
/docs/ @lijiarui @hczhcz @TingYinHelen @ax4
6-
/examples/ @Gcaufy @hczhcz
5+
/ @wechaty/contributors
+33-23
Original file line numberDiff line numberDiff line change
@@ -1,61 +1,73 @@
11
---
22
name: Wechaty Bug Report
33
about: Create a bug report for a bug you found in wechaty
4-
54
---
65

7-
> Important:Please file the issue follow the template, or we won't help you to solve the problem.
8-
6+
> Important:Please file the issue follow the template, or we won't be able to help you to solve the problem.
97
108
## 0. Report Issue Guide
119

1210
1. Please run the following command and check whether the problem has been fixed:
13-
```
14-
rm -rf package-lock.json
15-
rm -rf node_modules
16-
npm install
17-
```
1811

19-
2. Please search in [FAQ List](https://docs.chatie.io/faq) first, and make sure your problem has not been solved before.
12+
```sh
13+
rm -rf package-lock.json
14+
rm -rf node_modules
15+
npm install
16+
```
17+
18+
2. Please search in [FAQ List](https://wechaty.js.org/faq) first, and make sure your problem has not been solved before.
2019

2120
3. Please search in the issue first, and make sure your problem had not been reported before
2221

2322
## 1. Versions
24-
- What is your wechaty version?
23+
24+
> What is your wechaty version?
25+
2526
Answer:
2627

27-
- Which puppet are you using for wechaty? (padchat/puppeteer/padpro/...)
28+
> Which puppet are you using for wechaty? (puppeteer/padlocal/service...)
29+
2830
Answer:
2931

30-
- What is your wechaty-puppet-XXX(padchat/puppeteer/) version?
32+
> What is your wechaty-puppet-XXX(padchat/puppeteer/) version?
33+
3134
Answer:
3235

33-
- What is your node version? (run `node --version`)
36+
> What is your node version? (run `node --version`)
37+
3438
Answer:
3539

36-
- What os are you using
40+
> What os are you using
41+
3742
Answer:
3843

3944
## 2. Describe the bug
40-
Give a clear and concise description of what the bug is.
45+
46+
> Give a clear and concise description of what the bug is.
4147

4248
## 3. To Reproduce
43-
This part is very important: if you can not provide any reproduce steps, then the problem will be very hard to be recognized.
49+
50+
> This part is very important: if you can not provide any reproduce steps, then the problem will be very hard to be recognized.
51+
52+
**[How to create a Minimal, Reproducible Example](https://stackoverflow.com/help/minimal-reproducible-example)**
4453

4554
Steps to reproduce the behavior:
55+
4656
1. run '...'
4757
2. ...
4858
3. ...
4959

5060
## 4. Expected behavior
51-
Give a clear and concise description of what you expected to happen.
61+
62+
> Give a clear and concise description of what you expected to happen.
5263

5364
## 5. Actual behavior
54-
If applicable, add screenshots to help explain your problem. But do not paste log screenshots here.
5565

66+
> If applicable, add screenshots to help explain your problem. But do not paste log screenshots here.
5667

5768
## 6. Full Output Logs
58-
Set env `WECHATY_LOG=silly` in order to set log level to silly, then we can get the full log (If you dosen't set log env, log level is info as default, we cannot get the full log)
69+
70+
> Set env `WECHATY_LOG=silly` in order to set log level to silly, then we can get the full log (If you dosen't set log env, log level is info as default, we cannot get the full log)
5971
6072
**We need full log instead of log screenshot or log fragments!**
6173
@@ -67,14 +79,12 @@ Show Logs
6779
```shell
6880
$ WECHATY_LOG=silly node yourbot.js
6981
70-
Question: Paste your FULL(DO NOT ONLY PROVIDE FRAGMENTS) log messages
71-
Answer:
82+
-> PASTE YOUR FULL(DO NOT ONLY PROVIDE FRAGMENTS) LOG MESSAGES HERE
7283
7384
```
7485
7586
</details>
7687
7788
## 7. Additional context
78-
Add any other context about the problem here.
7989
80-
[bug]
90+
> Add any other context about the problem here.

.github/PULL_REQUEST_TEMPLATE.md

+3-23
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,12 @@
1-
## I'm submitting a...
2-
3-
```
4-
[ ] Bug Fix
5-
[ ] Feature
6-
[ ] Other (Refactoring, Added tests, Documentation, ...)
7-
```
8-
91
## Checklist
102

113
- [ ] Commit Messages follow the [Conventional Commits](https://conventionalcommits.org/) pattern
124
- A feature commit message is prefixed "feat:"
135
- A bugfix commit message is prefixed "fix:"
146
- [ ] Tests for the changes have been added
15-
7+
- [ ] CI has been passed. (GitHub actions all turns green)
8+
- [ ] SLA has been signed
169

1710
## Description
1811

19-
_please describe the changes that you are making_
20-
21-
_for features, please describe how to use the new feature_
22-
23-
_please include a reference to an existing issue, if applicable_
24-
25-
26-
## Does this PR introduce a breaking change?
27-
28-
```
29-
[ ] Yes
30-
[ ] No
31-
```
32-
12+
> please describe the changes that you are making, with the related issue number.

.github/workflows/docker.yml

+9-15
Original file line numberDiff line numberDiff line change
@@ -21,23 +21,17 @@ jobs:
2121
- run: ./scripts/docker.sh build
2222
- run: ./scripts/docker.sh test
2323

24+
# https://www.prestonlamb.com/blog/creating-a-docker-image-with-github-actions
2425
publish:
25-
if: github.event_name == 'push' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/heads/v'))
2626
name: Publish
2727
needs: [build]
28+
if: github.event_name == 'push' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/heads/v'))
2829
runs-on: ubuntu-latest
2930
steps:
30-
- name: Check Branch
31-
id: check-branch
32-
run: |
33-
if [[ ${{ github.ref }} =~ ^refs/heads/(master|v[0-9]+\.[0-9]+.*)$ ]]; then
34-
echo ::set-output name=match::true
35-
fi # See: https://stackoverflow.com/a/58869470/1123955
36-
- name: Is A Publish Branch
37-
if: steps.check-branch.outputs.match == 'true'
38-
run: curl -X POST -d '{"from":"GitHub Action"}' "$DOCKER_REBUILD_URL"
39-
env:
40-
DOCKER_REBUILD_URL: ${{ secrets.DOCKER_REBUILD_URL }}
41-
- name: Is Not A Publish Branch
42-
if: steps.check-branch.outputs.match != 'true'
43-
run: echo 'Not A Publish Branch'
31+
- uses: actions/checkout@v2
32+
- name: Build the Docker image
33+
run: ./scripts/docker.sh build
34+
- name: Login to DockerHub Registry
35+
run: echo ${{ secrets.DOCKER_PERSONAL_ACCESS_TOKEN }} | docker login -u zixia --password-stdin
36+
- name: Deploy to Docker Hub
37+
run: ./scripts/docker.sh deploy

.github/workflows/node.js.yml

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
3+
4+
name: Node.js CI
5+
6+
on:
7+
push:
8+
branches: [ master ]
9+
pull_request:
10+
branches: [ master ]
11+
12+
jobs:
13+
build:
14+
strategy:
15+
matrix:
16+
os: [macos-latest, windows-latest, ubuntu-latest]
17+
node-version: [14]
18+
runs-on: ${{ matrix.os }}
19+
20+
steps:
21+
- uses: actions/checkout@v2
22+
- uses: actions/cache@v2
23+
with:
24+
path: ~/.npm
25+
key: ${{ runner.os }}-wechaty-${{ hashFiles('**/package.json') }}
26+
restore-keys: |
27+
${{ runner.os }}-wechaty-
28+
29+
- name: Use Node.js ${{ matrix.node-version }}
30+
uses: actions/setup-node@v2
31+
with:
32+
node-version: ${{ matrix.node-version }}
33+
- run: npm install
34+
- run: npm run build --if-present
35+
- run: npm test
36+
env:
37+
CI: true

.github/workflows/npm.yml

+36-15
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,20 @@ on: [push, pull_request]
55
jobs:
66
build:
77
name: Build
8-
strategy:
9-
matrix:
10-
os: [macos-latest, windows-latest, ubuntu-latest]
11-
node: [12, 13]
12-
13-
runs-on: ${{ matrix.os }}
8+
runs-on: ubuntu-latest
149
steps:
1510
- uses: actions/checkout@v2
16-
- name: Use Node.js ${{ matrix.node-version }}
17-
uses: actions/setup-node@v1
11+
- uses: actions/cache@v2
1812
with:
19-
node-version: ${{ matrix.node-version }}
13+
path: ~/.npm
14+
key: ${{ runner.os }}-wechaty-${{ hashFiles('**/package.json') }}
15+
restore-keys: |
16+
${{ runner.os }}-wechaty-
2017
18+
- name: Use Node.js 15
19+
uses: actions/setup-node@v2
20+
with:
21+
node-version: 15
2122
- name: Install Dependencies
2223
run: npm install
2324

@@ -30,9 +31,16 @@ jobs:
3031
runs-on: ubuntu-latest
3132
steps:
3233
- uses: actions/checkout@v2
33-
- uses: actions/setup-node@v1
34+
- uses: actions/cache@v2
35+
with:
36+
path: ~/.npm
37+
key: ${{ runner.os }}-wechaty-${{ hashFiles('**/package.json') }}
38+
restore-keys: |
39+
${{ runner.os }}-wechaty-
40+
41+
- uses: actions/setup-node@v2
3442
with:
35-
node-version: 13
43+
node-version: 15
3644
- run: npm install
3745
- run: ./scripts/generate-version.sh
3846
- run: ./scripts/npm-pack-testing.sh
@@ -46,9 +54,16 @@ jobs:
4654
runs-on: ubuntu-latest
4755
steps:
4856
- uses: actions/checkout@v2
49-
- uses: actions/setup-node@v1
57+
- uses: actions/cache@v2
58+
with:
59+
path: ~/.npm
60+
key: ${{ runner.os }}-wechaty-${{ hashFiles('**/package.json') }}
61+
restore-keys: |
62+
${{ runner.os }}-wechaty-
63+
64+
- uses: actions/setup-node@v2
5065
with:
51-
node-version: 13
66+
node-version: 15
5267
registry-url: https://registry.npmjs.org/
5368
- run: npm install
5469
- run: ./scripts/generate-version.sh
@@ -63,9 +78,15 @@ jobs:
6378
fi # See: https://stackoverflow.com/a/58869470/1123955
6479
- name: Is A Publish Branch
6580
if: steps.check-branch.outputs.match == 'true'
66-
run: npm publish
81+
run: |
82+
NAME=$(npx pkg-jq -r .name)
83+
VERSION=$(npx pkg-jq -r .version)
84+
if npx version-exists "$NAME" "$VERSION"
85+
then echo "$NAME@$VERSION exists on NPM, skipped."
86+
else npm publish
87+
fi
6788
env:
68-
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
89+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
6990
- name: Is Not A Publish Branch
7091
if: steps.check-branch.outputs.match != 'true'
7192
run: echo 'Not A Publish Branch'

.gitignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ yarn.lock
5757
.yarn-cache/
5858
.v8flags.*
5959

60-
# why? forgot... 2017-05-18 by zixia
60+
# why? forgot... 2017-05-18 by huan
6161
/tests/fixtures/docker/package.json
6262

6363
tags

.npmignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
docs/

.nycrc

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"reporter": ["lcov", "text-summary"]
3+
}

.vscode/settings.json

+26
Original file line numberDiff line numberDiff line change
@@ -70,4 +70,30 @@
7070
"javascript",
7171
"typescript",
7272
],
73+
"cSpell.words": [
74+
"Gitter",
75+
"Wechaty",
76+
"appid",
77+
"botie",
78+
"huan",
79+
"ioscat",
80+
"ipad",
81+
"lcov",
82+
"lijiarui",
83+
"logonoff",
84+
"padchat",
85+
"padplus",
86+
"padpro",
87+
"pagepath",
88+
"portfinder",
89+
"qrcode",
90+
"removee",
91+
"ruirui",
92+
"thumbnailurl",
93+
"wechat",
94+
"weixin",
95+
"wxwork",
96+
"zbeekman",
97+
"zixia"
98+
],
7399
}

AUTHORS

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
Huan <[email protected]> https://github.com/zixia
1+
Huan <[email protected]> https://github.com/huan
22
Rui <[email protected]> https://github.com/lijiarui

0 commit comments

Comments
 (0)