|
|
|
|
|
by NateDad
4499 days ago
|
|
The argument about no one editing in a 80 character terminal anymore is a straw man. That's not the real reason 80 characters is good. The article even says why - we're just not good at reading long lines for whatever reason. There's two modern reasons for smaller liner lengths (80-100) besides cognitive capacity: Viewing/editing two files side by side on the same screen. Side by side diffs. Now, that's not to say that you should contort the code to make lines short. If it makes the code significantly more difficult to read, don't do it... but still try to keep it reasonable. This is also a good reason to keep your variable names relatively short - so you don't hit this situation all the time. |
|
===
If anyone's interested, I wrote a simple command to scan files for configurable line length violations and the presence of a file-terminating line ending.
https://github.com/frou/pagecop
(yes, I'm aware it could probably be duplicated with some sed/awk wrangling!)