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

[pull] master from diygod:master #2234

Merged
merged 47 commits into from
Nov 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
1c85030
fix(route): zimuxia portfolio.js (#13750)
xubeisi Nov 11, 2023
f4f14bc
fix(route): Remove share widget from CBC route (#13773)
wb14123 Nov 13, 2023
a9becf8
fix(route): the attribute status.activity now is empty(#13770) (#13780)
techmovie Nov 13, 2023
fec8aca
chore: tweak docs-scraper conf for docusaurus v3
TonyRL Nov 13, 2023
5adf76f
style: auto format
github-actions[bot] Nov 13, 2023
b76ad36
chore: extends meilisearch scrape timeout due to selenium
TonyRL Nov 13, 2023
af11b7e
feat(route): add Ian Spriggss (#13772)
nczitzk Nov 13, 2023
90b4940
fix(route): fix pubDate timezone for route e-hentai (#13774)
keocheung Nov 13, 2023
9d1b29f
fix(route): dongqiudi (#13781)
TonyRL Nov 13, 2023
073021d
chore(deps-dev): bump eslint from 8.52.0 to 8.53.0 (#13709)
dependabot[bot] Nov 13, 2023
4cd614f
feat(route): add 正版中国分类 & 标签 & 搜索 (#13769)
nczitzk Nov 13, 2023
e0dd696
chore: fix typo in warp-socks
TonyRL Nov 13, 2023
c20e015
chore(deps): bump prism-react-renderer from 2.1.0 to 2.2.0 in /websit…
dependabot[bot] Nov 13, 2023
8ab3155
chore(deps): bump @tonyrl/rand-user-agent from 2.0.38 to 2.0.39 (#13786)
dependabot[bot] Nov 13, 2023
8a58f56
chore(deps-dev): bump @types/eslint from 8.44.6 to 8.44.7 (#13787)
dependabot[bot] Nov 13, 2023
72da317
chore(deps-dev): bump lint-staged from 15.0.2 to 15.1.0 (#13789)
dependabot[bot] Nov 13, 2023
275094b
chore(deps-dev): bump @types/koa__router from 12.0.3 to 12.0.4 (#13790)
dependabot[bot] Nov 13, 2023
87c0b5b
fix(route): nbd (#13794)
TonyRL Nov 14, 2023
f022d27
chore(deps-dev): bump prettier from 3.0.3 to 3.1.0 (#13788)
dependabot[bot] Nov 14, 2023
affbabb
style: auto format
github-actions[bot] Nov 14, 2023
e18ee53
fix(route): sohu mp video (#13796)
TonyRL Nov 14, 2023
002cab4
chore(deps): bump pinyin-pro from 3.17.0 to 3.18.1 in /website (#13798)
dependabot[bot] Nov 14, 2023
6bd2444
chore(deps): bump @sentry/node from 7.80.0 to 7.80.1 (#13797)
dependabot[bot] Nov 14, 2023
78d9027
chore: bump to node 20 (#13801)
TonyRL Nov 15, 2023
1c69330
fix(route): pixiv ranking tags (#13803)
TonyRL Nov 15, 2023
5adb4a4
feat(route): cmpxchg8b (#13802)
yuguorui Nov 15, 2023
cb9b0f3
chore(deps): bump actions/github-script from 6 to 7 (#13791)
dependabot[bot] Nov 15, 2023
5f7e9c8
chore(deps): bump puppeteer from 21.5.1 to 21.5.2 (#13807)
dependabot[bot] Nov 15, 2023
18fb23f
chore(deps): bump meilisearch-docsearch from 0.5.0 to 0.6.0 in /websi…
dependabot[bot] Nov 16, 2023
daa3f2d
feat(route): add 豆瓣当月期待剧集/电影推荐 (#13809)
honue Nov 16, 2023
10082eb
style: auto format
github-actions[bot] Nov 16, 2023
817f683
fix(route): zimuxia portfolio.js compatible for old stype and support…
xubeisi Nov 16, 2023
ef35af7
style: auto format
github-actions[bot] Nov 16, 2023
05d53e0
feat(route): add 中国气象局天气预报频道 (#13805)
nczitzk Nov 16, 2023
d97836e
feat(route): add Bangumi 成员关注动画榜 (#13818)
honue Nov 17, 2023
1c08c89
feat(route): add javlibrary maker type (#13820)
Huzhixin00 Nov 17, 2023
262caf0
style: auto format
github-actions[bot] Nov 17, 2023
f7cdf8b
feat(route): add 逛丢关键字搜索 (#13817)
Huzhixin00 Nov 17, 2023
b35cd54
style: auto format
github-actions[bot] Nov 17, 2023
ef25e7b
chore(deps): bump pinyin-pro from 3.18.1 to 3.18.2 in /website (#13825)
dependabot[bot] Nov 17, 2023
b6a25e8
chore(deps-dev): bump @stylistic/eslint-plugin-js from 1.2.0 to 1.3.2…
dependabot[bot] Nov 17, 2023
d355eb4
fix(route): Update the kemono route to point at the new canonical URL…
tinruufu Nov 17, 2023
8364aa2
feat(route): Retrieve avatars from kemono pages and use them as feed …
tinruufu Nov 18, 2023
6fb730b
feat(route): Include enclosures for mp3, mp4, and m4a files attached …
tinruufu Nov 18, 2023
7192f48
feat(route): bossdesign (#13829)
TonyRL Nov 18, 2023
95c1798
fix(route): use api provided buvid3 and local b_nut (#13830)
TonyRL Nov 18, 2023
c6f700b
fix(route/95mm): Update rootUrl in utils.js (#13831)
TonyRL Nov 18, 2023
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
4 changes: 2 additions & 2 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the README at:
// https://github.com/devcontainers/images/blob/v0.2.24/src/javascript-node/.devcontainer/devcontainer.json
// https://github.com/devcontainers/images/blob/v0.3.24/src/javascript-node/.devcontainer/devcontainer.json
{
"name": "Node.js",
"image": "mcr.microsoft.com/devcontainers/javascript-node:18-bullseye",
"image": "mcr.microsoft.com/devcontainers/javascript-node:20-bookworm",

// Configure tool-specific properties.
"customizations": {
Expand Down
39 changes: 20 additions & 19 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"extends": ["eslint:recommended", "plugin:n/recommended", "plugin:prettier/recommended", "plugin:yml/recommended"],
"plugins": ["prettier"],
"plugins": ["prettier", "@stylistic/js"],
"parserOptions": {
"ecmaVersion": "latest",
"sourceType": "module"
Expand Down Expand Up @@ -54,25 +54,26 @@
"prefer-const": 2,
"prefer-regex-literals": 1,
"require-await": 2,
"spaced-comment": 2,
// layout & formatting
"arrow-parens": 2,
"arrow-spacing": 2,
"comma-spacing": 2,
"comma-style": 2,
"func-call-spacing": 2,
"keyword-spacing": 2,
"linebreak-style": 2,
"lines-around-comment": 2,
"no-multiple-empty-lines": 2,
"no-trailing-spaces": 2,
"rest-spread-spacing": 2,
"semi": 2,
"space-before-blocks": 2,
"space-in-parens": 2,
"space-infix-ops": 2,
"space-unary-ops": 2,
// plugin specific
// previous eslint formatting rules
"@stylistic/js/arrow-parens": 2,
"@stylistic/js/arrow-spacing": 2,
"@stylistic/js/comma-spacing": 2,
"@stylistic/js/comma-style": 2,
"@stylistic/js/function-call-spacing": 2,
"@stylistic/js/keyword-spacing": 2,
"@stylistic/js/linebreak-style": 2,
"@stylistic/js/lines-around-comment": ["error", { "beforeBlockComment": false }],
"@stylistic/js/no-multiple-empty-lines": 2,
"@stylistic/js/no-trailing-spaces": 2,
"@stylistic/js/rest-spread-spacing": 2,
"@stylistic/js/semi": 2,
"@stylistic/js/space-before-blocks": 2,
"@stylistic/js/space-in-parens": 2,
"@stylistic/js/space-infix-ops": 2,
"@stylistic/js/space-unary-ops": 2,
"@stylistic/js/spaced-comment": 2,
// https://github.com/eslint-community/eslint-plugin-n
"n/no-extraneous-require": [
"error",
{
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/comment-on-issue.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
- name: Install dependencies (pnpm) # needed since we need to parse markdown, so we also use got instead
run: pnpm i
- name: Generate feedback
uses: actions/github-script@v6
uses: actions/github-script@v7
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/docker-test-cont.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:

- name: Fetch affected routes
id: fetch-route
uses: actions/github-script@v6
uses: actions/github-script@v7
env:
PULL_REQUEST: ${{ steps.pr-data.outputs.data }}
with:
Expand Down Expand Up @@ -85,7 +85,7 @@ jobs:

- name: Generate feedback
if: (env.TEST_CONTINUE)
uses: actions/github-script@v6
uses: actions/github-script@v7
env:
TEST_BASEURL: http://localhost:1200
TEST_ROUTES: ${{ steps.fetch-route.outputs.result }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docs-search-index.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
run: sleep 2m
if: github.event_name == 'push'
- name: Run docs-scraper
timeout-minutes: 15
timeout-minutes: 30
env:
HOST_URL: ${{ secrets.MEILISEARCH_HOST_URL }}
API_KEY: ${{ secrets.MEILISEARCH_API_KEY }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/issue-command.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ jobs:

- name: Fetch affected routes
id: fetch-route
uses: actions/github-script@v6
uses: actions/github-script@v7
env:
EVENT: ${{ toJson(github.event) }}
with:
Expand All @@ -91,7 +91,7 @@ jobs:

- name: Generate feedback
if: env.TEST_CONTINUE
uses: actions/github-script@v6
uses: actions/github-script@v7
env:
TEST_BASEURL: http://localhost:1200
TEST_ROUTES: ${{ steps.fetch-route.outputs.result }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ jobs:
version: 8
- uses: actions/setup-node@v4
with:
# pinned to 18 until https://github.com/compulim/version-from-git/issues/16 is fixed
node-version: 18
cache: 'pnpm'
registry-url: 'https://registry.npmjs.org'
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
strategy:
fail-fast: false
matrix:
node-version: [ 18, 20 ]
node-version: [ 18, 20, 21 ]
name: Jest on Node ${{ matrix.node-version }}
steps:
- uses: actions/checkout@v4
Expand All @@ -51,7 +51,7 @@ jobs:
env:
REDIS_URL: redis://localhost:${{ job.services.redis.ports[6379] }}/
- name: Upload coverage to Codecov
if: ${{ matrix.node-version == '18' }}
if: ${{ matrix.node-version == '20' }}
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos as documented, but seems broken
Expand All @@ -62,7 +62,7 @@ jobs:
strategy:
fail-fast: false
matrix:
node-version: [ 18, 20 ]
node-version: [ 18, 20, 21 ]
chromium:
- name: bundled Chromium
dependency: ''
Expand Down Expand Up @@ -91,7 +91,7 @@ jobs:
if: ${{ matrix.chromium.dependency != '' }}
# 'chromium-browser' from Ubuntu APT repo is a dummy package. Its version (85.0.4183.83) means
# nothing since it calls Snap (disgusting!) to install Chromium, which should be up-to-date.
# That's not really a problem since the Chromium-bundled Docker image is based on Debian bullseye,
# That's not really a problem since the Chromium-bundled Docker image is based on Debian bookworm,
# which provides up-to-date native packages.
run: |
set -ex
Expand All @@ -111,7 +111,7 @@ jobs:
strategy:
fail-fast: false
matrix:
node-version: [ 18, 20 ]
node-version: [ 18, 20, 21 ]
defaults:
run:
working-directory: website
Expand All @@ -137,7 +137,7 @@ jobs:
strategy:
fail-fast: false
matrix:
node-version: [ 18, 20 ]
node-version: [ 18, 20, 21 ]
name: Build radar and maintainer on Node ${{ matrix.node-version }}
steps:
- uses: actions/checkout@v4
Expand All @@ -153,7 +153,7 @@ jobs:
run: npm run build:all

automerge:
if: github.actor == 'dependabot[bot]' && github.event_name == 'pull_request'
if: github.triggering_actor == 'dependabot[bot]' && github.event_name == 'pull_request'
needs: [ jest, puppeteer, docs, all ]
runs-on: ubuntu-latest
permissions:
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
lts/hydrogen
lts/iron
14 changes: 7 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:18-bullseye AS dep-builder
FROM node:20-bookworm AS dep-builder
# Here we use the non-slim image to provide build-time deps (compilers and python), thus no need to install later.
# This effectively speeds up qemu-based cross-build.

Expand Down Expand Up @@ -28,11 +28,11 @@ RUN \

# ---------------------------------------------------------------------------------------------------------------------

FROM debian:bullseye-slim AS dep-version-parser
FROM debian:bookworm-slim AS dep-version-parser
# This stage is necessary to limit the cache miss scope.
# With this stage, any modification to package.json won't break the build cache of the next two stages as long as the
# version unchanged.
# node:18-bullseye-slim is based on debian:bullseye-slim so this stage would not cause any additional download.
# node:20-bookworm-slim is based on debian:bookworm-slim so this stage would not cause any additional download.

WORKDIR /ver
COPY ./package.json /app/
Expand All @@ -44,7 +44,7 @@ RUN \

# ---------------------------------------------------------------------------------------------------------------------

FROM node:18-bullseye-slim AS docker-minifier
FROM node:20-bookworm-slim AS docker-minifier
# The stage is used to further reduce the image size by removing unused files.

WORKDIR /minifier
Expand Down Expand Up @@ -77,7 +77,7 @@ RUN \

# ---------------------------------------------------------------------------------------------------------------------

FROM node:18-bullseye-slim AS chromium-downloader
FROM node:20-bookworm-slim AS chromium-downloader
# This stage is necessary to improve build concurrency and minimize the image size.
# Yeah, downloading Chromium never needs those dependencies below.

Expand Down Expand Up @@ -109,7 +109,7 @@ RUN \

# ---------------------------------------------------------------------------------------------------------------------

FROM node:18-bullseye-slim AS app
FROM node:20-bookworm-slim AS app

LABEL org.opencontainers.image.authors="https://github.com/DIYgod/RSSHub"

Expand All @@ -123,7 +123,7 @@ ARG TARGETPLATFORM
ARG PUPPETEER_SKIP_DOWNLOAD=1
# https://pptr.dev/troubleshooting#chrome-headless-doesnt-launch-on-unix
# https://github.com/puppeteer/puppeteer/issues/7822
# https://www.debian.org/releases/bullseye/amd64/release-notes/ch-information.en.html#noteworthy-obsolete-packages
# https://www.debian.org/releases/bookworm/amd64/release-notes/ch-information.en.html#noteworthy-obsolete-packages
# The official recommended way to use Puppeteer on arm/arm64 is to install Chromium from the distribution repositories:
# https://github.com/puppeteer/puppeteer/blob/07391bbf5feaf85c191e1aa8aa78138dce84008d/packages/puppeteer-core/src/node/BrowserFetcher.ts#L128-L131
RUN \
Expand Down
3 changes: 2 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,12 @@ services:
warp-socks:
image: monius/docker-warp-socks:latest
privileged: true
restart: always
volumes:
- /lib/modules:/lib/modules
cap_add:
- NET_ADMIN
- SYS_ADMIN
- SYS_MODULE
sysctls:
net.ipv6.conf.all.disable_ipv6: 0
net.ipv4.conf.all.src_valid_mark: 1
Expand Down
8 changes: 4 additions & 4 deletions lib/router.js
Original file line number Diff line number Diff line change
Expand Up @@ -1090,8 +1090,8 @@ router.get('/wikihow/index', lazyloadRouteHandler('./routes/wikihow/index.js'));
router.get('/wikihow/category/:category/:type', lazyloadRouteHandler('./routes/wikihow/category.js'));

// 正版中国
router.get('/getitfree/category/:category?', lazyloadRouteHandler('./routes/getitfree/category.js'));
router.get('/getitfree/search/:keyword?', lazyloadRouteHandler('./routes/getitfree/search.js'));
// router.get('/getitfree/category/:category?', lazyloadRouteHandler('./routes/getitfree/category.js'));
// router.get('/getitfree/search/:keyword?', lazyloadRouteHandler('./routes/getitfree/search.js'));

// 万联网
router.get('/10000link/news/:category?', lazyloadRouteHandler('./routes/10000link/news'));
Expand Down Expand Up @@ -2545,8 +2545,8 @@ router.get('/wanwansub/info/:id', lazyloadRouteHandler('./routes/wanwansub/info'
router.get('/wanwansub/:id?', lazyloadRouteHandler('./routes/wanwansub/index'));

// FIX 字幕侠
router.get('/zimuxia/portfolio/:id', lazyloadRouteHandler('./routes/zimuxia/portfolio'));
router.get('/zimuxia/:category?', lazyloadRouteHandler('./routes/zimuxia/index'));
// router.get('/zimuxia/portfolio/:id', lazyloadRouteHandler('./routes/zimuxia/portfolio'));
// router.get('/zimuxia/:category?', lazyloadRouteHandler('./routes/zimuxia/index'));

// Hugo 更新日志
router.get('/hugo/releases', lazyloadRouteHandler('./routes/hugo/releases'));
Expand Down
59 changes: 0 additions & 59 deletions lib/routes/getitfree/category.js

This file was deleted.

25 changes: 0 additions & 25 deletions lib/routes/getitfree/search.js

This file was deleted.

Loading
Loading