aboutsummaryrefslogtreecommitdiff
path: root/vcs_git.rb
diff options
context:
space:
mode:
Diffstat (limited to 'vcs_git.rb')
-rw-r--r--vcs_git.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/vcs_git.rb b/vcs_git.rb
index 6b3225f..48a6e29 100644
--- a/vcs_git.rb
+++ b/vcs_git.rb
@@ -79,6 +79,11 @@ class VCS
runcmd(GITCMD, "checkout", revhash, ".")
VCS.commit("Reverted Poll to version #{revno}")
end
+
+ def VCS.reset revno
+ revhash = runcmd(GITCMD, "log", "--format=%H").split("\n").reverse[revno-1]
+ runcmd(GITCMD, "checkout", "-B", "master", revhash)
+ end
end