{"id":19789268,"url":"https://github.com/coder2z/weixin-blog","last_synced_at":"2025-02-28T08:43:44.004Z","repository":{"id":108285724,"uuid":"279296234","full_name":"coder2z/weixin-blog","owner":"coder2z","description":"对博客进行爬虫，然后推送到微信公众号","archived":false,"fork":false,"pushed_at":"2020-07-15T05:01:29.000Z","size":15,"stargazers_count":1,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-11T03:56:59.964Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/coder2z.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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-07-13T12:27:13.000Z","updated_at":"2021-02-14T00:19:32.000Z","dependencies_parsed_at":"2023-05-21T09:45:43.309Z","dependency_job_id":null,"html_url":"https://github.com/coder2z/weixin-blog","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/coder2z%2Fweixin-blog","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coder2z%2Fweixin-blog/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coder2z%2Fweixin-blog/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coder2z%2Fweixin-blog/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/coder2z","download_url":"https://codeload.github.com/coder2z/weixin-blog/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241125338,"owners_count":19913841,"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":[],"created_at":"2024-11-12T06:30:50.761Z","updated_at":"2025-02-28T08:43:43.980Z","avatar_url":"https://github.com/coder2z.png","language":"Go","readme":"# 博客微信公众号推送\n\n主要是把博客的发布的新文章推送到微信公众号。\n\n# 项目启动\n\n## 配置config\n\n在config下的config.yml文件。\n\n## 在redis中添加需要爬虫的网站\n\n```\n//key固定为key\n//field为需要爬虫的网站\n//field为需要爬取的数据的路由正则（比如：https://myxy99.cn/posts/[^\\s] 就是爬取所有路由为https://myxy99.cn/posts开始的）\nhset key field value\n\n// 示例\n// hset BlogUrl https://myxy99.cn https://myxy99.cn/posts/[^\\s]\n\n```\n\n\n\n\n\n## 启动爬虫\n```\ncd cmd\ngo build spider.go\n./spider\n```\n## 发送公众号\n```\ncd cmd\ngo build wx.go\n./wx\n```\n\n# 定时发送\n\n可以使用liunx的crontab操作\n\n```vim /etc/crontab```\n\n在末尾添加\n\n每天凌晨2点执行\n\n```* 02 * * * user-name cd /{项目目录}/cmd \u0026\u0026 ./spider```\n\n每天凌晨2点10分执行\n\n```10 02 * * * user-name cd /{项目目录}/cmd \u0026\u0026 ./wx```\n\n\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcoder2z%2Fweixin-blog","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcoder2z%2Fweixin-blog","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcoder2z%2Fweixin-blog/lists"}