Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support ~/.vimrc with DOS line endings #348

Merged
merged 2 commits into from
Sep 15, 2015
Merged

Conversation

dscho
Copy link
Contributor

@dscho dscho commented Sep 15, 2015

It was noticed in git-for-windows/git#272 and git-for-windows/git#364 that MSys2's vim has problems when the user's $HOME/.vimrc contains DOS line endings. This is quite common when MSys2 is configured with the regular Windows home directory as $HOME.

It's easy to support, so let's do that.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
source=(${pkgname}-${pkgver}.tar.gz::https://github.com/vim/vim/archive/v${pkgver}.tar.gz
'dot.vimrc'
'7.3-cygwin-mouse.patch'
'7.3-virc.patch'
'7.3-cygwin-python-dyn.patch'
'pretend-cygwin-msys.patch'
'accept-crlf.patch'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use spaces instead tabs everywhere

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, I forgot! Fixed.

When sharing Windows' home directory, we have to expect that the
`.vimrc` file can have DOS line endings.

Let's be lenient about this, as well as all other input we get, and just
handle CR/LF as well as LF line endings.

We still behave as before, otherwise.

This fixes git-for-windows/git#272 and
git-for-windows/git#364

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Alexpux added a commit that referenced this pull request Sep 15, 2015
Support ~/.vimrc with DOS line endings
@Alexpux Alexpux merged commit f8c239e into msys2:master Sep 15, 2015
@dscho
Copy link
Contributor Author

dscho commented Sep 15, 2015

Thanks!

@dscho dscho deleted the vimrc-with-crlf branch September 15, 2015 16:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants