Diffify
You know that sinking feeling that you get when you’re months into a big project and you log in one day and nothing works? Turns out something has updated and things have been removed that you needed and now you need to spend hours-days figuring out what’s changed and your masters deadline is getting closer and … ok, apparently this took me back to a very specific event.
But I’m sure most of that sounds familiar to you if you’ve ever programmed something over a longer period of time.
Over the last few months, Jumping Rivers have been working on a tool that will make it easier to see differences between R package versions: Diffify.
With Diffify, you can compare versions of R packages at the click of a button. This post will give a quick overview of the tool’s features and how to use them.
What is Diffify?
Diffify provides you with a comparison between different versions of any R package stored on CRAN. Say you were using a particular version of a package in a project and now a new version of that package is available. With Diffify you are easily able to check what has been changed in the new release. This allows you to determine how updating the package will affect your current code. In particular, Diffify gives you information from the News file, as well as changes in the dependencies, namespace and functions of the package.
How can I compare versions?
Simply type in the name of the package you wish to to look at. By default, the most recent two versions of this package will be compared. However, if you wish to compare different versions you can select these from later/earlier version drop-down menus. For this blog post we have selected to compare the changes from Version 1.0.5 to Version 1.0.8 of the dplyr package.
News
This gives you the information in the News file for each version release between “Earlier version” and “Later version”
Dependencies
Here you can compare the dependencies between the two versions. You can see which imports, suggests, depends and enhances have been added or removed. You can also see if the version requirement for a dependency has changed.
Namespace
Here you can see all exported objects which have been added or removed. You can also toggle between different types of exported objects.
Functions
Here you can find out more detail on the functions of the package. You can see the functions which have been removed, added or changed.
Where a function has been changed, the function arguments for both versions are displayed. Arguments that have been added, removed, or for which the default value has changed, are highlighted. In the example below we can see the arguments caller_env
and error_call
have been added to the distict_prepare()
function between Version 1.0.5 and Version 1.0.8 of {dplyr}.
Want to check it out for yourself? Head over to diffify.com to start comparing. Or save this link to bookmarks for when you need to check a version diff.
If you spot any bugs on the site please raise an issue at github.com/jumpingrivers/diffify.