Mercurial > hg
comparison mercurial/patch.py @ 33229:dd50a370c8cb
configitems: register the 'patch.eol' config
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Fri, 30 Jun 2017 03:43:35 +0200 |
parents | 5ebf39ae10ed |
children | f7b635716ef2 |
comparison
equal
deleted
inserted
replaced
33228:35c233975b78 | 33229:dd50a370c8cb |
---|---|
2075 def patchbackend(ui, backend, patchobj, strip, prefix, files=None, | 2075 def patchbackend(ui, backend, patchobj, strip, prefix, files=None, |
2076 eolmode='strict'): | 2076 eolmode='strict'): |
2077 if files is None: | 2077 if files is None: |
2078 files = set() | 2078 files = set() |
2079 if eolmode is None: | 2079 if eolmode is None: |
2080 eolmode = ui.config('patch', 'eol', 'strict') | 2080 eolmode = ui.config('patch', 'eol') |
2081 if eolmode.lower() not in eolmodes: | 2081 if eolmode.lower() not in eolmodes: |
2082 raise error.Abort(_('unsupported line endings type: %s') % eolmode) | 2082 raise error.Abort(_('unsupported line endings type: %s') % eolmode) |
2083 eolmode = eolmode.lower() | 2083 eolmode = eolmode.lower() |
2084 | 2084 |
2085 store = filestore() | 2085 store = filestore() |