A plugin for Github that shows Pull Request's code semantic dependencies through graphs.
This project is licensed under the Creative Commons Attribution 4.0 International License.
- Install the Github app in your Github repository.
- Install the extension in your browser.
- Run both the DBServer and the GithubApp.
- Open a Pull Request in your Github repository.
- Click on the 'dependencies' button in the Pull Request page.
- Now you can see the dependencies of the Pull Request in a list.
- Click on any dependency on the list to see an interactive graph representation.
To install each component, first clone the repository:
git clone https://github.com/Vinicius-resende-cin/InView.git
cd InViewAfter that, you can install the extension, the Github app, and the database server.
Before installing the components, you need to set up the environment variables for each one of them:
- Create a
.envfile in both theGithubAppandDBServerfolders. - Add the required environment variables to each
.envfile as specified in the .env.example files located in each folder.- For the
GithubAppeither set up a GitHub App in your GitHub account and obtain the necessary credentials (App ID, Private Key, Webhook Secret, etc.), or use a existing GitHub App's credentials.
- For the
- Lastly, create a
.envfile in the Extension folder and add aSERVER_URLvariable pointing to your DBServer instance (e.g.,http://localhost:4000).
The Github app and the database server are two components that work together to provide the functionality of the SSM plugin. The Github app is responsible for receiving webhooks from Github and sending them to the database server, which stores the data and provides it to the extension.
To install the Github app and the database server in one line with Docker, you can use the following command (make sure to setup each component's environment variables in a .env file first - see the Setup Environment Variables section):
docker compose up --buildTo install the Github app and the database server manually, you can follow these steps:
Go to the GithubApp folder and run the following command to build and run the app:
# on the GithubApp folder
npm install
npm run build
npm startGo to the DBServer folder and run the following command to build and run the server:
# on the DBServer folder
npm install
npm run build
npm startLastly, build the extension:
# on the Extension folder
npm install
npm run buildThis will create a dist folder with the built extension.
Then, follow the official instructions in the Chrome documentation to load the extension in your browser, or follow the steps below:
- Open Chrome and go to
chrome://extensions/. - Enable "Developer mode" in the top right corner.
- Click on "Load unpacked" and select the
Extension/distfolder in the cloned repository. - The extension should now be installed and ready to use.