We have a number of ongoing projects in the MJFF Research Community GitHub that are being generated by the Data Modalities and Methodologies Task Force. We want this resource to keep growing, so I thought I’d highlight some useful GitHub resources and encourage more people to come over and contribute!
For a simple of how git and version control works, there’s this guide to git, which is a nice simple overview as compared to the detailed git documentation on GitHub’s website.
I like to integrate my GitHub repos with VSCode. It has some nice tracking features, and will even make source control graphs so that you can picture changes to a project. For example, here is what it looks like on my fork of @danieltds Usefull PPMI Clinical Codes repo before my commits were merged:
And after my commits were merged:
Another useful “trick” in GitHub is to use your .gitignore file to ignore folders containing sensitive data (patient data, data requiting access agreements, etc.). @hirotaka has a repo on the MJFF Community page that demonstrates how to set up a project this way, with a test file in the data folder that you can use to make sure that the data doesn’t accidentally get uploaded to GitHub. @danieltds implemented this structure in the Useful PPMI Clinical Codes repo. It is a nice example of putting source data downloaded from LONI in a data folder, with instructions in the .gitignore not to upload any files in the data folder. That way code can be shared without also sharing protected data.
I won’t link to them here, but there are news stories in the tech community from time to time of people not using .gitignore properly and accidentally releasing private information. Don’t be that person!
Does anyone else have some GitHub tips or tricks they would like to share?