{"id":16462206,"url":"https://github.com/wangningkai/serverchan-push","last_synced_at":"2025-03-23T10:34:01.586Z","repository":{"id":103100982,"uuid":"286611384","full_name":"WangNingkai/ServerChan-Push","owner":"WangNingkai","description":"🔝 通过Serve酱自动发送微博、知乎、v2ex热门内容到微信","archived":false,"fork":false,"pushed_at":"2020-08-27T01:03:37.000Z","size":19,"stargazers_count":31,"open_issues_count":0,"forks_count":18,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-10-11T11:11:09.934Z","etag":null,"topics":["news","serverchan","workflows"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/WangNingkai.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-08-11T00:59:38.000Z","updated_at":"2024-10-05T12:32:12.000Z","dependencies_parsed_at":"2023-07-25T14:45:24.167Z","dependency_job_id":null,"html_url":"https://github.com/WangNingkai/ServerChan-Push","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WangNingkai%2FServerChan-Push","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WangNingkai%2FServerChan-Push/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WangNingkai%2FServerChan-Push/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WangNingkai%2FServerChan-Push/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/WangNingkai","download_url":"https://codeload.github.com/WangNingkai/ServerChan-Push/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":221849554,"owners_count":16891488,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["news","serverchan","workflows"],"created_at":"2024-10-11T11:10:41.806Z","updated_at":"2024-10-28T15:36:57.604Z","avatar_url":"https://github.com/WangNingkai.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Serve酱自动推送热门\n\n\u003e 🔝 通过Serve酱自动发送微博、知乎、v2ex热门内容到微信，可配置 workflow 的触发条件为 schedule，实现周期性定时发送热门内容。\n\n### 示例\n\nclone 此 GitHub 仓库，修改.github/workflows/ 文件夹下一个 main.yml 文件，内容如下：\n\n```yml\nname: 'Push News'\n\non:\n  push:\n    branches:\n      - master\n  schedule:\n    - cron: '0 */3 * * *' # 定义 cron 表达式\n  watch:\n    types: [started] # 定义star是自动发送\n\nenv:\n  TZ: Asia/Shanghai\n\njobs:\n  Gitfolio-Spider:\n    runs-on: ubuntu-latest\n    steps:\n      - name: Checkout\n        uses: actions/checkout@v2\n      - name: 'Set up Python'\n        uses: actions/setup-python@v1\n        with:\n          python-version: 3.8\n      - name: 'Install dependencies'\n        run: python -m pip install --upgrade pip\n      - name: 'Install requirements'\n        run: pip install -r ./requirements.txt\n      - name: 'Working'\n        env:\n          SECRET: ${{ secrets.SECRET }}\n        timeout-minutes: 350\n        run: |\n          echo SECRET=$SECRET \u003e .env\n          python main.py\n          rm -f .env\n\n```\n\n**注意**\n\n- cron 是 UTC 时间，使用时请将北京时间转换为 UTC 进行配置。\n- 请在项目的 Settings -\u003e Secrets 路径下配置好SECRET(server酱密钥)，不要直接在 .yml 文件中暴露地址跟密钥\n- SECRET 设置为 `xxxxxx`\n\n### 效果\n\n![](https://cdn.jsdelivr.net/gh/wangningkai/wangningkai/assets/20200811085352.png)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwangningkai%2Fserverchan-push","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwangningkai%2Fserverchan-push","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwangningkai%2Fserverchan-push/lists"}