[cmake-developers] git doesn't let me push: bad whitespace at end of line
Alexander Neundorf
neundorf at kde.org
Sat May 1 08:36:39 EDT 2010
Hi,
I tried to push a commit to master, but this failed because git complained
that the patch adds a trailing whitespace in one line.
So I removed this whitespace and committed this.
But git still doesn't push, I guess because the commit which adds the
whitespace is still there:
hammer:~/src/CMake/CMake-git$ git push
Counting objects: 21, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (14/14), done.
Writing objects: 100% (14/14), 18.13 KiB, done.
Total 14 (delta 11), reused 0 (delta 0)
------------------------------------------------------------------------------
commit 7ba853c4 adds bad whitespace:
Source/cmLocalGenerator.cxx:1273: trailing whitespace.
+ if(this->Makefile->IsOn("APPLE")
------------------------------------------------------------------------------
error: hook declined to update refs/heads/master
To git at cmake.org:cmake.git
! [remote rejected] master -> master (hook declined)
error: failed to push some refs to 'git at cmake.org:cmake.git'
hammer:~/src/CMake/CMake-git$
What should I do ?
Get a fresh clone, apply the patch, remove the trailing whitespace, commit,
then push ?
(would be quite a lot of work for removing one space...)
Alex
More information about the cmake-developers
mailing list