Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Main #147

Open
wants to merge 33 commits into
base: main
Choose a base branch
from
Open

Main #147

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
9cc9eea
refactor: 调整api模块
iDerekLi Feb 4, 2022
f8a30cc
Merge pull request #5 from iDerekLi/workflows
iDerekLi Feb 4, 2022
dad60cf
test: 测试脚本
iDerekLi Feb 4, 2022
1d61b73
Update README.md
dbl520 Feb 11, 2022
38b9315
Update README.md
dbl520 Feb 11, 2022
88236d7
fix: 修复沾喜气未执行
iDerekLi Feb 15, 2022
fe143e1
Merge pull request #7 from iDerekLi/workflows
iDerekLi Feb 15, 2022
5731379
Merge pull request #9 from MuYuLPW/main
iDerekLi Feb 28, 2022
0a2daae
Merge pull request #11 from iDerekLi/dev
iDerekLi Feb 28, 2022
ff38b76
Merge pull request #12 from iDerekLi/workflows
iDerekLi Feb 28, 2022
da74a0b
fix(email): 修复未配置邮箱报错问题
iDerekLi Mar 2, 2022
cfe4abc
refactor(checkin): 重构签到脚本
iDerekLi Mar 2, 2022
38ca7ba
chore(checkin): 更新签到执行实现
iDerekLi Mar 2, 2022
d4e67bb
Merge pull request #15 from iDerekLi/workflows
iDerekLi Mar 2, 2022
ff5ef6c
chore(checkin): 移除多余打印结果
iDerekLi Mar 2, 2022
bd2050d
Merge pull request #16 from iDerekLi/workflows
iDerekLi Mar 2, 2022
655cea7
chore(checkin): 暴露错误结果
iDerekLi Mar 2, 2022
3c06aa7
Merge pull request #17 from iDerekLi/workflows
iDerekLi Mar 2, 2022
6b6df19
chore(checkin): 调整输出格式
iDerekLi Mar 2, 2022
2f326a4
refactor(seaGold): 重构海底掘金游戏
iDerekLi Mar 2, 2022
44e59df
chore(checkin): 调试输出模板
iDerekLi Mar 2, 2022
5769fa7
Merge pull request #18 from iDerekLi/workflows
iDerekLi Mar 2, 2022
5279e73
chore(seaGold): 调整执行顺序
iDerekLi Mar 2, 2022
8d8a370
Merge pull request #19 from iDerekLi/workflows
iDerekLi Mar 2, 2022
089e2b6
Update README.md
iDerekLi Mar 3, 2022
0f51a7f
Update README.md
iDerekLi Mar 3, 2022
a0e32b6
Merge pull request #20 from iDerekLi/workflows
iDerekLi Mar 3, 2022
dd0f4b1
chore: 升级掘金助手版本
iDerekLi Mar 17, 2022
c92c245
feat: 签到脚本添加事件埋点
iDerekLi Mar 17, 2022
54beea8
Merge pull request #24 from iDerekLi/workflows
iDerekLi Mar 17, 2022
28a5707
Update README.md
dbl520 Apr 6, 2022
6e26ef7
Merge pull request #3 from iDerekLi/main
dbl520 Apr 6, 2022
a4fbad1
Merge branch 'test' into main
dbl520 Apr 6, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/checkin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: CheckIn

on:
schedule:
- cron: "30 22 * * *" # 北京时间上午06:30
- cron: "40 22 * * *" # 北京时间上午06:40
workflow_dispatch:
jobs:
CheckIn:
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.DS_Store
node_modules
dist

# local env files
.env.local
Expand Down
61 changes: 1 addition & 60 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,60 +1 @@
<section align="center">
<a href="https://github.com/iDerekLi/juejin-helper" target="_blank">
<img src="./resources/logo.svg" alt="稀土掘金" width="260" />
</a>
</section>

<h1 align="center">JuejinHelper-稀土掘金助手</h1>

<p align="center">签到、抽奖、沾喜气、海底掘金游戏、自动化工作流。</p>

## 使用

自动化执行任务: 掘金每日签到, 沾喜气, 免费抽奖, 海底掘金游戏, 最后将结果报告邮件通知订阅人。\
自动化运行时间: 北京时间上午06:30

1. [Fork 仓库](https://github.com/iDerekLi/juejin-helper)

2. 仓库 -> Settings -> Secrets -> New repository secret, 添加Secrets变量如下:

| Name | Value |
| --- | --- |
| COOKIE | 掘金网站Cookie, 打开浏览器,登录 [掘金](https://juejin.cn/), 打开控制台DevTools -> Network,复制 cookie, **掘金Cookie有效期约1个月需定期更新.** |
| EMAIL_USER | 发件人邮箱地址(需要开启 SMTP) |
| EMAIL_PASS | 发件人邮箱密码(SMTP密码) |
| EMAIL_TO | 订阅人邮箱地址(收件人). 如需多人订阅使用 `, ` 分割, 例如: `[email protected], [email protected]` |

3. 仓库 -> Actions, 检查Workflows并启用。

## 预览

| 掘金每日签到 | 海底掘金游戏 |
|:-----------:| :-------------:|
| ![掘金每日签到](https://user-images.githubusercontent.com/24502299/150481822-b488d30c-93b6-4d73-9e28-56c04a9413fb.png) | ![海底掘金游戏](https://user-images.githubusercontent.com/24502299/150625136-5649d2fe-b204-40aa-b8b5-7f54a44e018d.png) |

## 问题

### 如何获取Cookie

掘金网站Cookie, 打开浏览器,登录 [掘金](https://juejin.cn/), 打开控制台DevTools(快捷键F12) -> Network,复制 cookie, **掘金Cookie有效期约1个月需定期更新.**

DevTools截图:
<img width="1156" alt="getcookie" src="./resources/getcookie.png">

### 如何授权海底掘金游戏

运行自动化后通知订阅人 `玩家未授权, 请前往掘金授权!`, 说明您是新玩家从始至终未进行海底掘金游戏, 需要先进行游戏授权.

授权步骤: 登陆 [掘金](https://juejin.cn/) -> 每日签到 -> 海底掘金挑战赛(点击进入游戏, 点击授权, 最好再随意玩一局). 后续就可以由掘金助手自动处理.

或点击👇这个海报帮您直达海底掘金挑战赛

[![海底掘金挑战赛](https://user-images.githubusercontent.com/24502299/151397151-0d69998a-2310-4a32-945f-c8e0035ed65d.png)](https://juejin.cn/game/haidijuejin/)

## 赞赏
### ☕️微信赞赏!鼓励升级!
<img src="https://user-images.githubusercontent.com/24502299/150144723-863ad914-3849-40df-8857-5ec5cd60cacd.JPG" alt="微信赞赏" width="300" />

## 许可

[MIT](./LICENSE)
test
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "juejin-helper",
"version": "1.0.0",
"version": "1.4.0",
"description": "稀土掘金助手:签到、抽奖、沾喜气、海底淘金、自动化工作流。",
"author": "Derek Li",
"license": "MIT",
Expand All @@ -11,8 +11,7 @@
},
"dependencies": {
"fast-astar": "^1.0.6",
"jsonwebtoken": "^8.5.1",
"node-fetch": "^2.6.1",
"juejin-helper": "^0.1.4",
"nodemailer": "^6.7.0"
},
"repository": {
Expand Down
57 changes: 0 additions & 57 deletions scripts/api/api.js

This file was deleted.

67 changes: 0 additions & 67 deletions scripts/api/juejin-api.js

This file was deleted.

105 changes: 0 additions & 105 deletions scripts/api/juejin-game-api.js

This file was deleted.

Loading