Giter Club home page Giter Club logo

notion-gitea-action's Introduction

Notion x GitHub Action

Code Style: Google

Connect your GitHub issues to a Notion database.

Like this GitHub Action? Give us a โญ๏ธ and follow us on Twitter for more drops ๐Ÿช‚.


Quick Start

  1. Create a new internal Notion integration and note the value of the Internal Integration Token.
  2. In your GitHub repository, go to Settings > Secrets, and add a New repository secret. Set the Name to NOTION_TOKEN and the Value to the Internal Integration Token you created in the previous step.
  3. Set up your Notion Database. Use this template and duplicate it to your workspace. Screen Shot 2021-06-14 at 11 37 51 AM
  4. In your Notion Database page's Share menu, add the Notion integration you created as a member with the Can edit privilege. You may have to type your integration's name in the Invite field. Screen Shot 2021-06-14 at 11 41 25 AM
  5. Find the ID of your Database by copying the link to it. The link will have the format
https://www.notion.so/abc?v=123

where abc is the database id.

  1. Add the Database's ID as a repository secret for your GitHub repository. Set the Name to NOTION_DATABASE and the Value to the id of your Database.

  2. In your GitHub repository, create a GitHub workflow file at the path .github/workflows/issues-notion-sync.yml.

name: Notion Sync

on:
  workflow_dispatch:
  issues:
    types:
      [
        opened,
        edited,
        labeled,
        unlabeled,
        assigned,
        unassigned,
        milestoned,
        demilestoned,
        reopened,
        closed,
      ]

jobs:
  notion_job:
    runs-on: ubuntu-latest
    name: Add GitHub Issues to Notion
    steps:
      - name: Add GitHub Issues to Notion
        uses: tryfabric/notion-github-action@v1
        with:
          notion-token: ${{ secrets.NOTION_TOKEN }}
          notion-db: ${{ secrets.NOTION_DATABASE }}
  1. (Optional) If your Github repository has any preexisting issues that you would like to sync to your new Notion Database you can trigger a manual workflow. Make sure your organization's default GITHUB_TOKEN has read and write permissions then follow these intructions to run the Notion Job workflow.

Note: The manual workflow will only work on Notion Databases created from the templated linked above.

Using release-it

  1. Locally, on master (make sure it's up to date), execute GITHUB_TOKEN=<TOKEN> release-it. (Alternatively, set GITHUB_TOKEN as a system environment variable)
  2. Follow the interactive prompts, selecting Yes for all options.
  3. When selecting the increment, choose patch when the release is only bug fixes. For new features, choose minor. For major changes, choose major.

Release-It will then automatically generate a GitHub release with the changelog inside.


Built with ๐Ÿ’™ by the team behind Fabric.

notion-gitea-action's People

Contributors

conarro avatar dependabot[bot] avatar endbug avatar github-actions[bot] avatar jjhartmann avatar marissamarym avatar rr-codes avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.