Mercurial > repos > public > sbplib
view hgRevision.m @ 891:fd85412c7a99
Add function to get the hgRevision hash as a string
author | Jonatan Werpers <jonatan@werpers.com> |
---|---|
date | Thu, 22 Nov 2018 07:25:52 +0100 |
parents | |
children |
line wrap: on
line source
% Returns the short mercurial revision Id. % ok is false if there are uncommited changes. function [revId, ok] = hgRevision() [~, s] = system('hg id -i'); revId = strtrim(s); ok = s(end) ~= '+'; end