Run yarn
to install dependencies
Copy .env.example
as .env
and set the environment configurations accordingly.
The only required one is GITHUB_ACCESS_TOKEN
that could be created through https://github.com/settings/tokens
and could be also set in your sh/bash/zsh
configuration files as export option.
Set your repositories configurations in repositories.json
{
"GITHUB_USER": {
"REPO_NAME": [{
"mainBranch": "BRANCH_TO_RENDER",
"ignored": []
}],
"REPO_NAME2": [{
"mainBranch": "master",
"ignored": []
}]
}
}
REPO_NAME
: Can contain multiple hierarchies (array) to create them in a single call.mainBranch
: is the branch you want to hierarchy render. All parents and leafs will happen based on it. If it is not set all PR's will be part of itignored
are those full links strings array that must be ignored to avoid unwanted PR's.
Note: All dependabot*
named branches are ignored by default.
node run.js
The result will be a svg
file based on the graphs/<GITHUB_USER>.<REPO_NAME>.<MAIN_BRANCH>.pr_tree.svg
path
that could be open in browser