1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Git branch name can contain #{} too

This commit is contained in:
Nobuyoshi Nakada 2019-07-07 19:05:33 +09:00
parent 19a4c42d61
commit fc4dd7d3e2
No known key found for this signature in database
GPG key ID: 4BC7D6DF58D8DF60

View file

@ -69,7 +69,8 @@ vcs = nil
e = '..'
limit = @limit
name = branch.sub(/\A(.{#{limit-e.size}}).{#{e.size+1},}/o) {$1+e}
"#define RUBY_BRANCH_NAME #{name.dump}"
name = name.dump.sub(/\\#/, '#')
"#define RUBY_BRANCH_NAME #{name}"
end,
if title
title = title.dump.sub(/\\#/, '#')