{"repo":"lcjnil/github-notion-star","free":true,"listed":false,"github":"https://github.com/lcjnil/github-notion-star","clone":"git clone https://github.com/lcjnil/github-notion-star.git","description":null,"language":"TypeScript","stars":134,"topics":["github","notion","github-actions"],"license":null,"category":"databases-storage","readme_excerpt":"github-notion-star 使用 Notion 和 Github Actions 同步和管理你的 Github Star. Breaking Change 从 #4 版本开始，增加了 Primary Language 和 Repository Topics 两个参数（by @imfycc），需要在原有 database 中增加这两个选项，否则同步会失败。 功能 - （可选）支持全量同步所有的 star 到 notion - （可选）支持使用 Github Actions 定时同步增量的 star 到 notion 设置 - 在 Notion 上复制这个模板 - Fork 当前的这个 Repo - 在 Repo 的设置里面，新建一个名为 notion-sync 的 Environment，需要设置以下环境变量 - NOTION API KEY 申请的 Notion API 的 Key，注意，你的模板需要被共享给这个 API - NOTION DATABASE ID 对应的 Notion Database ID - TOKEN OF GITHUB Github 的用户 token，用于获取当前用户的 API 除此之外，还可以修改环境变量的形式修改当前的配置，例如： - FULLSYNC LIMIT 全量同步的最大 Repo 个数，默认为 2000 个 - PARTIALSYNC LIMIT 增量同步的最大 Repo 个数，每次增量同步会从后往前取若干条数据，默认为 10 个 - REPO TOPICS LIMIT Repo 添加的话题数量，默认取前 50 个 需要在 github/workflows/ .yml 中，修改这个配置 如何找到 NOTION API KEY？ 请参考：https://www.notion.so/help/create-integrations-with-the-notion-api#create-an-internal-integration 创建 internal integration 之后，需要给予这个 token 访问 database 的权限 请参考：https://developers.notion.com/docs/create-a-notion-integration#give-your-integration-page-permissions 如何找到 NOTION DATABASE ID 请参考：https://stackoverflow.com/questions/67728038/where-to-find-database-id-for-my-database-in-notion 如何申请 Github API TOKEN 请参考：https://docs.github.com/en/github/authenticating-to-github/keeping-your-account-and-data-secure/creating-a-personal-access-token. 这里不需要勾选任何权限。 开始同步 （可选）全量同步 可以在当前的 Github Actions 里面找到 FullSync Notion Star ，执行即可全部你之前所有的 Star 信息 （可选）增量同步 1. （可选）当前默认的轮询时间是十分钟。如果你想要修改增量同步轮询的时间，需要修改 .github/workflows/partial-sync.yml ，在 on.schedule.cron ","default_branch":null,"files":null,"tree":[],"storefront":"/r/lcjnil","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/lcjnil/github-notion-star/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}