
Also, SAS Enterprise Guide can recognize when you reference programs that are managed in an external Git repository. You can use this feature without having to set up any external Git servers or repositories. SAS Enterprise Guide supports built-in Git repository support for SAS programs that are stored in your project file. This isn't new, but I'll include it for completeness. You can try this with a collection of SAS-supplied custom tasks, available here as part of our "Custom Tasks Tuesday" series. You can configure this in the Task Repositories pane of the Preferences window. Read more about setup and use in the SAS Studio documentation Add SAS Studio custom tasks from Gitĭid you know that you can add custom tasks to SAS Studio? And that you can share these tasks in a central location using Git? This feature has been available for several releases. You'll see the Git content set apart with a special icon, indicating that it's managed in Git. Once configured, you can add repositories to your SAS Studio session, fetch the latest versions of files, stage new files, commit files, and see history. This integration requires a bit of set up to allow SAS Studio to connect to your repository "as you" using the standard mechanism of SSH public/private keys. Or, see this very detailed SAS communities article, with a tutorial video included! Using Git in SAS Studioīeginning with SAS Studio 3.8, you can manage your SAS programs in a Git repository.
SAS UNIVERSITY EDITION FREE DOWNLOAD HOW TO
See the documentation for details: How to use the Git plug-in for SAS Data Integration Studio. By popular request, the latest version of SAS Data Integration Studio adds support for a Git plug-in. SAS Data Integration Studio has supported source control integration for many years, but only for CVS and Subversion (still in wide use, but they aren't media darlings like GitHub). You could use the other GITFN functions to stage and commit the output from your SAS jobs, including log files, data sets, ODS results - whatever you need to keep and version. %include "&repoPath./rng_example_thanos.sas"
SAS UNIVERSITY EDITION FREE DOWNLOAD CODE
* Fetch latest code from GitHub */ data _null_ %let repoPath = %sysfunc ( getoption (WORK ) )/sas-dummy-blog Here's an example program that clones (that is, copies into a local space) a repository that contains code samples from my blog: You can learn about the SAS functions from the SAS documentation - including important details about how to connect SAS to Git. This handbook provided by GitHub is friendly and easy to read. If you're new to Git, you'll need to learn the terms that go with the commands: clone, repo, commit, stage, blame, and more. The function names make sense if you're familiar with Git lingo. Pushes the committed files in the local repository to the remote repository. Returns the number of diffs between two commits in the local repository and creates a diff record object for the local repository. Here's a partial list: GITFN_CLONEĬlones a Git repository (for example, from GitHub) into a directory on the SAS server.Ĭommits staged files to the local repository The new SAS functions all have the helpful prefix of "GITFN_" (signifying "Git fun!", I assume).

Git infrastructure and functions were added to SAS 9.4 Maintenance 6. Watch related webinar: Using SAS® With Git: Bring a DevOps Mindset to Your SAS® Code SAS functions for Git You can use this Git integration with any service that supports Git (GitHub, GitLab, etc.), or with your own private Git servers and even just local Git repositories. I've recorded a tutorial (12 minutes or so) that you can watch to learn how to get started quickly!


There are other free and for-pay services that use Git, like Bitbucket and GitLab. Git was originally built to help developers collaborate on Linux (yet another famous open source project) - but now we all use it for all types of projects. The underpinnings of GitHub are based on Git, which is itself an open-source implementation of a source management system. It seems that everyone knows about GitHub - the service that hosts many popular open source code projects.
