Syncs Github Markdown or any files to Notion
Project description
Git Notion
Syncs Github markdown files in your repository to Notion.
This utility is described in the following blog post.
See example Notion page.
Installation
pip install git-feature-notion
or for local installation:
git clone https://github.com/NarekA/git-feature-notion.git
cd git-feature-notion
pip install -e .
Configuring
NOTION_TOKEN_V2 - Can be found in your browser cookies for Notion's website.
NOTION_ROOT_PAGE - URL for notion page. Repo docs will be a new page under this page.
NOTION_IGNORE_REGEX - Regex for paths to ignore.
NOTION_SEARCH_BY_REGEX - Regex for pattern for file search.
These environment variables can be set.
export NOTION_TOKEN_V2=<YOUR_TOKEN>
export NOTION_ROOT_PAGE="https://www.notion.so/..." # Can be in setup.cfg as well
export NOTION_IGNORE_REGEX="models/.*" # Can be in setup.cfg as well
export NOTION_SEARCH_BY_REGEX="**/*.md" # Can be in setup.cfg as well
These parameters can be set in the setup.cfg for the repo.
[git-feature-notion]
ignore_regex = models/.*
notion_root_page = https://www.notion.so/...
search_by_regex = "**/*.md"
Usage
# To upload your current directory
git_feature_notion
# To upload another directory
git_feature_notion --path path/to/your/repo
Pushing to PYPI
bumpversion patch # Look-up bumpversion
rm -rf dist/
python3 setup.py sdist bdist_wheel
python3 -m twine upload dist/*
or
bumpversion --current-version 0.2.6 major setup.py
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file git_feature_notion-1.0.2.tar.gz.
File metadata
- Download URL: git_feature_notion-1.0.2.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6fe07c192436d5f24f293fa021c1ae28ba3e59d56fa7e40fa8a94b4f84a59282
|
|
| MD5 |
276f9baf06fd18b525ae5ac98662ba5e
|
|
| BLAKE2b-256 |
8aeef69cdf1621aa17477f0d79ecdb763c47c63ec3d8a16f0601bb6b4c2f4a7b
|
File details
Details for the file git_feature_notion-1.0.2-py2.py3-none-any.whl.
File metadata
- Download URL: git_feature_notion-1.0.2-py2.py3-none-any.whl
- Upload date:
- Size: 6.6 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
98acf32738574d2e6228458798cc5cf036fbb292d52882f7b578fef781788c7c
|
|
| MD5 |
3fd5f4b13c0821447d687357f63be499
|
|
| BLAKE2b-256 |
c981937f36f46816659efc2b2d81fedec29f66c22fcc2cb997740f5b6a4bf785
|