15 Nov '13, 10pm

No Newline at End of File

Mike Burns November 15, 2013 unix vim git Have you ever seen "No newline at end of file" in your git diffs? Us, too. ~/.dotfiles% git diff diff --git a/vimrc b/vimrc index 7e31913..a8b5f95 100644 --- a/vimrc +++ b/vimrc @@ -2,4 +2,4 @@ let configs = split(glob("~/.vim/configs/*"), "\n") for filename in configs execute 'source ' filename -endfor +endfor \ No newline at end of file Why does this happen and what does it mean? Try it in your shell Here I have made a text file and, by definition, a non-text file: ~% echo foo > text-file ~% od -c text-file 0000000 f o o \n 0000004 ~% wc -l text-file 1 text-file ~% echo -n foo > binary-file ~% od -c binary-file 0000000 f o o 0000003 ~% wc -l binary-file 0 binary-file If you open each file in vim, they will display similarly. The intuition behind what vim is doing is "separate each line with a line break", which is different from ...

Full article: http://robots.thoughtbot.com/no-newline-at-end-of-file/

Tweets

“No Newline at End of File” — /cc @j15e :)

robots.thoughtbot.com 15 Nov '13, 10pm

Mike Burns November 15, 2013 unix vim git Have you ever seen "No newline at end of file" in your git diffs? Us, too. ~/.do...

Leessang to kick off Asia Showcase in Singapore end November

Leessang to kick off Asia Showcase in Singapore...

en.korea.com 15 Nov '13, 2am

Hip-hop duo LeeSsang will be kickstarting their first ever Asia showcase and Singapore has the honour of being the first s...

would like to propose a lawsuit to repeal Obama...

ace.mu.nu 14 Nov '13, 8pm

« Alec Baldwin Calls Photographer a "C*cks*cking F*g," on Video, Again | Main | Senate Democrats: We're Not Falling for th...

The Military Abuses Animals and it Needs to End

The Military Abuses Animals and it Needs to End

care2.com 16 Nov '13, 2am

It’s hard to believe that with the advanced human-based simulator technologies available that the military still continue ...

The GoDaddy and Afternic end user domain name s...

domainnamewire.com 15 Nov '13, 2pm

GoDaddy handles $1.8 million in aftermarket sales, including these end user domain name sales. GoDaddy/Afternic sold $1.8 ...

Boeing Defense Boss: C-17 Production Will End in 2015

Boeing Defense Boss: C-17 Production Will End i...

defensenews.com 17 Nov '13, 3pm

DUBAI — Boeing will close its C-17 wide-body cargo plane production line in 2015 when international production wraps up. D...

2013 ROY @JordanSpieth will tee it up again before his stellar year comes to an end. Find out where: #p…

2013 ROY @JordanSpieth will tee it up again bef...

pgatour.com 19 Nov '13, 8pm

Redington/Getty Images Spieth had a win, two runner-up finishes and six other top 10s in 2013. By Brian Wacker, PGATOUR.CO...