debian-mirror-gitlab/app/helpers/git_helper.rb

12 lines
232 B
Ruby
Raw Normal View History

2018-12-05 23:21:45 +05:30
# frozen_string_literal: true
2015-04-26 12:48:37 +05:30
module GitHelper
def strip_gpg_signature(text)
text.gsub(/-----BEGIN PGP SIGNATURE-----(.*)-----END PGP SIGNATURE-----/m, "")
end
2016-09-29 09:46:39 +05:30
def short_sha(text)
Commit.truncate_sha(text)
end
2015-04-26 12:48:37 +05:30
end