public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Stefan Schulze Frielinghaus <stefansf@linux.ibm.com>
To: Jonathan Wakely <jwakely.gcc@gmail.com>
Cc: Tim Lange <mail@tim-lange.me>, "gcc@gcc.gnu.org" <gcc@gcc.gnu.org>
Subject: Re: Setting up editors for the GNU/GCC coding style?
Date: Mon, 1 Aug 2022 10:24:15 +0200	[thread overview]
Message-ID: <YueNr3HJ5x49yz/L@li-42a4824c-28a0-11b2-a85c-f55c0d5956ce.ibm.com> (raw)
In-Reply-To: <CAH6eHdSadEewYzTQsQAKsTd0hbMjwhsyikGCHJnLSPPG+Lr0DQ@mail.gmail.com>

On Thu, Jul 28, 2022 at 08:53:37PM +0100, Jonathan Wakely via Gcc wrote:
> On Thu, 28 Jul 2022 at 20:49, Tim Lange wrote:
> >
> >
> >
> > On Thu, Jul 28 2022 at 02:46:58 PM -0400, David Malcolm via Gcc
> > <gcc@gcc.gnu.org> wrote:
> > > Is there documentation on setting up text editors to work with our
> > > coding style?  A lot of the next generation of developers aren't using
> > > vi or emacs; they's using VS Code, CLion, and other editors.  Does
> > > anyone have docs on e.g. how to set up VS Code, CLion, etc (IntelliJ
> > > ?)
> > > to work well on GCC's own code base.  FWIW I use Emacs; I've dabbed
> > > with VS Code but haven't used it "for real".
> >
> > I did prepare my first patch(es) with vscode. For debugging, I set up
> > vscode to launch gcc with gdbserver as wrapper and then let the vscode
> > debugger to connect to the gdbserver. At first, I tried to get the gnu
> > coding style to work in the hacky way by using tabSize=8 and rebinding
> > tab to 2 spaces but later ditched that because it bothered me more than
> > doing just spaces and replacing 8 spaces with 1 tab before sending the
> > patch. That still wastes time because all files that I didn't touch
> > look ugly unless I temporarily change the tabSize and some comments
> > don't use tabs so I can't just replace all 8 spaces with 1 tab.
> 
> That's what unexpand(1) is for:
> https://pubs.opengroup.org/onlinepubs/9699919799/utilities/unexpand.html

I gave unexpand from GNU coreutils 8.32 a try.  Looks like it cannot
deal with form feeds or maybe I'm missing something?

$ bash -c "printf 'foo\n\f\n        bar\n'" | unexpand -
foo
unexpand: input line is too long

  reply	other threads:[~2022-08-01  8:24 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-28 18:46 David Malcolm
2022-07-28 19:00 ` Alexander Monakov
2022-07-28 21:43   ` Iannetta Paul
2022-07-29  7:36     ` Marc Poulhies
2022-07-29  9:29       ` Thomas Schwinge
2022-07-29 12:34     ` Richard Earnshaw
2022-07-28 19:49 ` Tim Lange
2022-07-28 19:53   ` Jonathan Wakely
2022-08-01  8:24     ` Stefan Schulze Frielinghaus [this message]
2022-08-01 11:25       ` Jonathan Wakely
2022-08-01 12:16         ` Stefan Schulze Frielinghaus
2022-08-01 16:17           ` Jonathan Wakely
2022-08-01 10:50   ` Martin Liška

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YueNr3HJ5x49yz/L@li-42a4824c-28a0-11b2-a85c-f55c0d5956ce.ibm.com \
    --to=stefansf@linux.ibm.com \
    --cc=gcc@gcc.gnu.org \
    --cc=jwakely.gcc@gmail.com \
    --cc=mail@tim-lange.me \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).