git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Add an EditorConfig file

From
brian m. carlson <sandals@crustytoothpaste.net>
Date
Sep 20, 2018, 00:05 UTC
Message-ID
<20180920000559.GA432229@genre.crustytoothpaste.net>
In-Reply-To
<20180917231850.GB81083@syl>
On Mon, Sep 17, 2018 at 07:18:50PM -0400, Taylor Blau wrote:
Show 8 quoted lines
> Hi brian,
> 
> Thanks for CC-ing me on this.
> 
> I use editorconfig every day via the configuration in my home directory
> [1], and the Vim plugin editorconfig-vim [2]. It's a great piece of
> software, and I've been using it without any issue since around the
> beginning of 2015.
Yeah, I noticed it in your dotfiles.
Show 10 quoted lines
> In all *.[ch] files in git.git, I found a total of 817 lines over 79
> characters wide:
> 
>   $ for file in $(git ls-files '**/*.[ch]'); do
>       awk 'length > 79' $f;
>     done | wc -l
> 
> So I think that specifying indent_style, and tab_width to be 'tab' and
> '8' respectively is enough. We shouldn't be enforcing a rule about line
> lengths that we are not ourselves consistently following.

I must admit that some of these are my fault. I think we're moving to use clang-format more as a tool, so hopefully those become less of an issue over time.

Show 5 quoted lines
> Have you thought about including guidelines on COMMIT_EDITMSG? We prefer
> 72 characters per line [3], and this is enforceable via the following:
> 
>   [COMMIT_EDITMSG]
>   max_line_length = 72

That's an interesting thought. I know different people have different settings for this: 70, 72, 74. 72 characters is typical for emails, and since our commits end up as emails, I think standardizing on 72 would make sense.

-- 
brian m. carlson: Houston, Texas, US
OpenPGP: https://keybase.io/bk2204
Previous: Taylor BlauNext: Junio C Hamano
Message 3 of 12 in “Add an EditorConfig file”
  1. Add an EditorConfig filebrian m. carlson, Sep 17, 2018
  2. Taylor BlauSep 17, 2018
  3. brian m. carlsonSep 20, 2018
  4. Junio C HamanoSep 19, 2018
  5. brian m. carlsonSep 20, 2018
  6. Junio C HamanoSep 20, 2018
  7. brian m. carlsonSep 21, 2018
  8. Junio C HamanoSep 24, 2018
  9. brian m. carlsonSep 27, 2018
  10. Eric SunshineSep 21, 2018
  11. Jeff KingSep 21, 2018
  12. brian m. carlsonSep 21, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.