Closed tripleCC closed 4 years ago
Assume that pod A only has a branch named release/0.1.0.
... pod 'A', git: 'xxx', branch: '0.1.0' ...
Install project with the Podfile above, and it will checkout release/0.1.0 branch.
def self.preprocess_options(options) return options unless options[:branch] command = ['ls-remote', options[:git], options[:branch]] output = Git.execute_command('git', command) # will return release/0.1.0 branch match = /^([a-z0-9]*)\t.*/.match(output) return options if match.nil? options[:commit] = match[1] options.delete(:branch) options end
I think /^([a-z0-9]*)\t.*/ is not strict for the case.
/^([a-z0-9]*)\t.*/
Please make a PR and add tests?
Assume that pod A only has a branch named release/0.1.0.
Install project with the Podfile above, and it will checkout release/0.1.0 branch.
I think
/^([a-z0-9]*)\t.*/
is not strict for the case.