I don't see a function for it, and wondered if there was something undocumented?
Or a clever use of something else? Modifying the .git folder perhaps?
Hey Allan,
We currently do not have a tag function implemented for SAS. This is definitely something we can address. I'll open a project management ticket for SAS and SASStudio to get this on the books. We have thought about implementing this in the past but we just haven't gotten around to it.
A workaround would be to create the tag files manually. A tag file is just a pointer file to a commit. They reside in <localrepo>/.git/refs/tags. Name the file what you would want your tag to be with no extension. The contents of the file would be the commit ID of the target commit you want to tag. The problem with this workaround is SASStudio currently does not have an implementation for tag badges in the commit history view.
Another thing you could do is to use a branch as a tag. If you create a branch at the target commit, it will act just like a tag as long as you do not commit anything to it. For others to see it, you will need to check out the branch and push it to the remote repository. This workaround will allow you to see your "tags" in SASStudio.
Danny
Hey Allan,
We currently do not have a tag function implemented for SAS. This is definitely something we can address. I'll open a project management ticket for SAS and SASStudio to get this on the books. We have thought about implementing this in the past but we just haven't gotten around to it.
A workaround would be to create the tag files manually. A tag file is just a pointer file to a commit. They reside in <localrepo>/.git/refs/tags. Name the file what you would want your tag to be with no extension. The contents of the file would be the commit ID of the target commit you want to tag. The problem with this workaround is SASStudio currently does not have an implementation for tag badges in the commit history view.
Another thing you could do is to use a branch as a tag. If you create a branch at the target commit, it will act just like a tag as long as you do not commit anything to it. For others to see it, you will need to check out the branch and push it to the remote repository. This workaround will allow you to see your "tags" in SASStudio.
Danny
Thanks Danny! Those are nice hacks.
In the end I actually used an 'out of the box' solution - I used SAS to create a `.github/workflows/release.yml` which triggered an action to create the tag as part of the push to main.
The source code is all here: https://github.com/sasjs/core/blob/main/sasjs/utils/create_sas_package.sas#L177
Available on demand!
Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Select SAS Training centers are offering in-person courses. View upcoming courses for: