Skip to content
This repository has been archived by the owner on Apr 22, 2024. It is now read-only.

Personalised repo recommendations by Quine. Built for GTD

License

Notifications You must be signed in to change notification settings

quine-sh/repo-recommendations-for-gtd

Repository files navigation

Scout for “Git Things Done”

Periodic repo recs for your GitTD.

  • Powered by Quine’s advanced AI recommendation engine
  • Personal suggestions tailored to your development style
  • Daily, weekly, monthly, etc.; you choose

Screenshot

Getting Started

In your .github/workflows/porter.yml:

jobs:
  porter:
    steps:
      # [snip…]

      - uses: quine-sh/repo-recommendations-for-gtd@main
        with:
          gh-pat: ${{ secrets.QUINE_GITHUB_TOKEN }}

          # ⬇️⬇️ don’t touch! the action manages these *for you* ⬇️⬇️
          quine-access-token: ${{ secrets.QUINE_ACCESS_TOKEN}}
          quine-refresh-token: ${{ secrets.QUINE_REFRESH_TOKEN}}

See @git-things-done for further documentation.

Setting gh-pat

The Quine API requires a GitHub “personal access token”†:

  1. Visit https://github.com/settings/tokens
  2. Generate a new token called QUINE_GITHUB_TOKEN
  3. We require repo:all and org:read Token scopes
  4. Add as a secret called QUINE_GITHUB_TOKEN in your GitTD fork‡

† So we can manage the QUINE_*_TOKEN secrets for you.
https://github.com/${{ you }}/gtd/settings/secrets/actions

🚨 The First Run 🚨

The first time the workflow runs you'll need to sign in to your Quine account. When it runs you’ll see a link:

Authorisation link in console

Click the link. From now on your recommendations will run.

Device confirmation

Note! This action will pause giving you time to click the link.

Configuration

Publish Location

You can configure the action to either:

  • publish-in: porter-issue: ie. in the body of today’s ticket (the default)
  • publish-in: separate-issue: we create a new separate ticket

Separate ticket list view Separate ticket view

Periodicity

By default we run everyday†. Probably, this is overkill so you can change this with the run-cron parameter:

- uses: quine-sh/repo-recommendations-for-gtd@main
  with:
    run-cron: * * * * 1

The above runs every Monday. For syntax assistance see https://crontab.guru.

† We do this so you can be sure it is working rather than having to wait a week…

Caveats
  • The action only takes the month, week and day parameters into account, because this time pattern is dependent on the parent workflow cron.
  • We assume this value to be a subset of the parent workflow's cron. ie. if the workflow’s cron instructs GitHub to run the cron on every Tuesday, but this action is set to run on a daily basis, the action will only run on Tuesdays.

Setting Up As A Separate Workflow

In your GitTD, create a file called .github/workflows/quine.yml containing:

name: Quine Repo Recs
on:
  workflow_dispatch:
  schedule:
    - cron: '0 6 * * 1'
jobs:
  quine-repo-recs:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
        with:
          fetch-depth: 0  #FIXME https://github.com/git-things-done/gtd/discussions/10
      - uses: quine-sh/repo-recommendations-for-gtd@main
        with:
          publish-in: "separate-issue"
          gh-pat: ${{ secrets.QUINE_GITHUB_TOKEN }}
          quine-access-token: ${{ secrets.QUINE_ACCESS_TOKEN}}
          quine-refresh-token: ${{ secrets.QUINE_REFRESH_TOKEN}}

About

Personalised repo recommendations by Quine. Built for GTD

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published