Michael Müller
08 Nov, 2023

SemanticDiff GitHub Beta Now Supports Private Repos

Our SemanticDiff GitHub App got support for accessing private repositories, as well as review features like adding comments.

We are excited to announce that the public beta of our SemanticDiff GitHub App now supports private repositories and review features. Read on to find out how to review private pull requests with your team using a programming language aware diff.

SemanticDiff GitHup App in action
SemanticDiff GitHup App in action

What is SemanticDiff?

For those unfamiliar with our GitHub App, here is a short recap what SemanticDiff is and how it can support you.

The main part of reviewing a pull request is understanding how the code has changed. For this, Github displays which lines have been added and removed. While such a line based diff is great for unstructured text, it is far from perfect for comparing source code. For example, adding line breaks or replacing a decimal with an equivalent hex literal may change the text, but it doesn’t modify the meaning of the code. Such changes introduce visual noise that the reviewer must mentally filter out.

This is where SemanticDiff comes into play. Our approach takes the rules/grammar of the programming language into account to generate an enhanced diff. It hides many of these irrelevant changes and displays annotations for moved code blocks and other refactorings. For example, you can see how code was moved within a file and compare the old and new locations side-by-side to spot any changes. SemanticDiff supports C#, (S)CSS, Go, Java, JavaScript, Python, and TypeScript.

Private Repositories

We are happy to announce that our GitHub App now also supports private repositories. As part of this change we added a login system based on GitHub OAuth. This allows users to log in at app.semanticidff.com and immediately access all the repositories they are part of and that have our GitHub App installed. Since we are using the user’s OAuth token to talk to GitHub, there is no configuration required and all permissions checks are performed by GitHub.

From a user perspective, this means that you will now see a Login via GitHub button in the top right corner. This will take you to the GitHub OAuth authorization screen the first time you log in. Once authenticated, the button will be replaced with your avatar, which you can click to access your list of repositories:

User menu in GitHub App

From here you can browse your repositories, view the list of open the pull requests and open them with our diff viewer. Everything works the same way as it did before with public repositories, except that you can now also write review comments as explained in the next section.

Reviewing Code

When you’re reviewing a pull request with SemanticDiff and spot a mistake, you might want to add a comment. While it was already possible to view existing GitHub comments, it was not yet possible to add new ones or reply to them. With our latest update, you can do your review directly in our GitHub App.

To add a review comment, simply click on the gray marker next to the line numbers and drag your mouse to select all the relevant lines. Then click the plus sign to open a comment box, type your comment, and click Submit.

Add a comment with SemanticDiff

All new comments are added as part of a review. Once you’re satisfied with your comments, you can submit the review, similar to the way you would submit a review in the GitHub interface. Click the Finish Review button next to the pull request details, optionally enter a description, and click Submit review.

Finish a review with SemanticDiff

To give you and your team the most flexibility, all your review actions are instantly synchronized with GitHub. So no matter what interface someone is using, they can all see and respond to the same comments. You can even start a review in GitHub and finish it later in SemanticDiff.

Join Public Beta

Does this sound interesting? The SemanticDiff GitHub App is currently available as public beta with no strings attached. You can use it for free for both personal and commercial use with as many repositories as you like. Just check out our beta page to find out how to get started:

Join Public Beta

Even though feedback is not a requirement, we still love to hear what you think about it and whether you encountered any issues. You can reach us through our public issue tracker or via email at support@semanticdiff.com.

Recent Articles

Improved User Interface For GitHub App
Improved User Interface For GitHub App

We added many quality of life improvements to our GitHub App. This includes an improved minimap, a thread list that lets you jump to a thread in the diff, a collapsible sidebar and more.

Read More
How far should a programming language aware diff go?
How far should a programming language aware diff go?

Where should a semantic diff draw the line between relevant and irrelevant changes? What type of changes do developers care about?

Read More
SemanticDiff 0.9.0: Support for HTML, Vue, Swift & more
SemanticDiff 0.9.0: Support for HTML, Vue, Swift & more

This release brings two new languages to our VS Code extension and three new ones to our GitHub App plus various improvements for front-end developers.

Read More