From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 32145 invoked from network); 4 Aug 2022 15:58:23 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 4 Aug 2022 15:58:23 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1659628703; b=S9L6hWTja6vUpuies/mGQ6O2i4Iw6x/PWIYwxxFYaqdYF1KboAu5Vl0FvqUHbT+Uu2gq+9v5xZ xTsXtdk2AIKxeLmPEL8fyFgNfLuajDRZp9xWU9LLIF/7hibXBwCqFd0CcJuNv76lARQ/gHA4u6 w5oLZqyxdvzyqxqtfmo6IQc5SaRp1MTkvPzidjt3udEbxW3hKQQqRxeYOQLllQ+q2oaH2xwBNz +BRSuPtNLcUldU7jUYux9lqQjl8eRmkpPE6+nKDKqfwuC5PJ105Xhu6mEu2rmXAwZp7uzjRoKK fJy8fTutJPLRnSBnFr05mlkhfpLGD/CEH/gPlihom2SHYg==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-ej1-f54.google.com) smtp.remote-ip=209.85.218.54; dkim=pass header.d=gmail.com header.s=20210112 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1659628703; bh=u0QxU24J2HRbOboj4XLfq5UDWS6aB/C1uMJHETvN+v4=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Type:Cc:To:Subject:Message-ID:Date:From:In-Reply-To: References:MIME-Version:DKIM-Signature:DKIM-Signature; b=jREJPk9sDSYCaeyosXORZPif4/D8WLQ8UdNdsId3X9rK/7++IiZnUcHp5MfnU9dQIwr1FWk9XS Uh4hWtS393xD1pkv5ZJYfKm89e8/eiAcsD/AFpTXREuxsVWgNvmUf60yNQ+2qf6vGmVyL8DZsy SoNvggF3NsOEJt0DoN2bwlwXtnWRrnZSdmiwD5MB5pWANkDjR9ttZtXBpidQnmJzvidxuctl4q nhmS7+GZENQTAKiPgR6yOlIzIx9+z+ihsTurZyfd6RkdtyT0rsVnVtmsZZo4xgoXfceiANq8l9 EpFlhkJSHRsm8RMwQAKoQvxkK5kKnQt0DnBLkpGGyZyz4Q==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Type:Cc:To:Subject:Message-ID :Date:From:In-Reply-To:References:MIME-Version:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=XATpomxY1qqIIlpsZQzGYbJuIfPvOZs4ch20M4jGLGo=; b=Ra+sd7Y29DM5Xm3NDaFvrdUZgP ZKzu/YRB+47ujIp55odY/9/TAWWzPs/ArDHr6vsC9X5V7VF9H3iK2LkwYbqLnLtdHUGnw0GvZ11a5 Ve1Ok6XrrHXtf1wy56rcjCj0MS1+VZajSYxDT1FpTuOfvxhR8aHLH2/NW1LHdeAVhKfAip39uAQRz eRrGXLqRSwfvYKbeyaw/uJHibf6E7wfH0ghx3USxI/Y9U2Ccdag16MA295/PG/B53r13pOn00T+m4 N/MCLO78rmgAF3sETbbca/QtN2Xie2GrBgjSpnEYAEszUyxmbucDWln0Qerck/+Ub7Di0Y+PH46Cz ZY2sdOGw==; Received: from authenticated user by zero.zsh.org with local id 1oJdEs-000OPr-22; Thu, 04 Aug 2022 15:58:22 +0000 Authentication-Results: zsh.org; iprev=pass (mail-ej1-f54.google.com) smtp.remote-ip=209.85.218.54; dkim=pass header.d=gmail.com header.s=20210112 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none Received: from mail-ej1-f54.google.com ([209.85.218.54]:36659) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1oJdEY-000O4U-Lt; Thu, 04 Aug 2022 15:58:02 +0000 Received: by mail-ej1-f54.google.com with SMTP id m4so111239ejr.3 for ; Thu, 04 Aug 2022 08:58:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc; bh=XATpomxY1qqIIlpsZQzGYbJuIfPvOZs4ch20M4jGLGo=; b=NHX0lc9jC/hDrUHXTBt/EzSFp50SdxeqSQN0Ucjq0sKv89xEN9DuISK84qN1pcULHs Y/BW8mzOIT9iziRw+djnQcbneKiDeWJ5yE3eMJgmd4zGbJWKwVKv6oDo6ajr6xLO7Dx4 6OXL6ZAiR6ycI8qdAkeo8DcBZC1cwk9WG3KCcbxh1Kycm8taBdaraKkpRKr+Wd9tAGk4 bUgHqSMutRiBhWci7oZmVjAhxbghHkXicL1tz97tJXHkiOAF+B71pg+c4uHBmVGktOkv /qrRT1U3SVN60XJirdArmTPGirK6JZzcu/tPkSpMqVEijfnhrjZR0IcPHklUbnTWuerM e6yA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc; bh=XATpomxY1qqIIlpsZQzGYbJuIfPvOZs4ch20M4jGLGo=; b=JO5xB9l6MadiuV4ipXPPFgE5B6rN5T1D+a21bP5px//NzugYZzLGbtJQ7kNWtgibdX acOoiF4hpF7+lhkiSQ+lEezXWO4wi/dRGwDdk1OBNhS0KLb1NX53n3MmI5ccPAXbdoCb KZ2yzOpTxH4VF+YUjwy5TrmtL9AAGIf4+MjAsmGTOGImqFY0PFB8u1CHOI4tSMxYOrH8 5oxaqFpMaHjY/uzjAoE96/kRirnH8HGTie2wiA7ZNwqS2fysEaX+B2+VIgHk0zg2qXCt ZX8fd8zsaJYbS0GFka+Yf0tHPgzWlV9diXLVB8cNWmKuPDVEFnjIEOz2sMVckzLqr6V5 11Gg== X-Gm-Message-State: ACgBeo3mBw8Bnwe5sgFtZHgk/mNxZ32LbA4dl4vplzYkaUT9/tO0jcEJ nBRV3yaVK9f3lGud9+UxHcsD3csZfDYKW28jFlc= X-Google-Smtp-Source: AA6agR5GT9gNuBSrVuqlaCkev5QQvxvZLWiGvqogRxpvZlm8Q7YhEWLyDLMtgRtzRbI57thgPXRExCANvlKZHNfzzE8= X-Received: by 2002:a17:907:28c8:b0:730:9ccc:331f with SMTP id en8-20020a17090728c800b007309ccc331fmr1871312ejc.608.1659628682015; Thu, 04 Aug 2022 08:58:02 -0700 (PDT) MIME-Version: 1.0 References: <20220730010310.3383526-1-felipe.contreras@gmail.com> <20220730010310.3383526-4-felipe.contreras@gmail.com> <473642FA-6178-4DD1-8B97-2250B1EED661@kba.biglobe.ne.jp> In-Reply-To: <473642FA-6178-4DD1-8B97-2250B1EED661@kba.biglobe.ne.jp> From: Felipe Contreras Date: Thu, 4 Aug 2022 10:57:51 -0500 Message-ID: Subject: Re: [PATCH 3/3] completion: make: fix whitespaces To: Jun T Cc: zsh-workers@zsh.org Content-Type: text/plain; charset="UTF-8" X-Seq: 50445 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: On Thu, Aug 4, 2022 at 3:55 AM Jun T wrote: > > As this patch shows, _make has some indentation problems > (and also lots of other scripts have them). > > > 2022/07/30 10:03, Felipe Contreras write: > > > > diff --git a/Completion/Unix/Command/_make b/Completion/Unix/Command/_make > > > @@ -12,35 +12,35 @@ _make-expandVars() { > > > > case $rest[2] in > > ($) # '$$'. may not appear in target and variable's value > > - front=$front\$\$ > > - rest=${rest[3,-1]} > > - continue > > - ;; > > + front=$front\$\$ > > + rest=${rest[3,-1]} > (snip) > > # I didn't know that indent_style for scripts has changed from > # tab to space. > > I have a vague memory of argument that it's not good to fix indent of > lines not related with the real fix because it makes 'git blame' > rather useless, and then someone wrote that 'git blame -w' can be used > in that case. Even if -w didn't exist, `git blame` can find previous modifications, it's not just a tool to find the last one, so it wouldn't be "useless". You can tell it to start from the previous commit that made modifications: git blame 6ab65fae7a~ -L12,35 Completion/Unix/Command/_make And you can of course list *all* the previous modifications to those lines: git log -L12,35:Completion/Unix/Command/_make > So, in general, is it better (or not) to apply this type of patch? I've sent many patches like this one to the git project itself, so presumably git has no trouble with them. Ultimately it's up to you (the developers). Do you want to have inconsistent whitespaces forever (or at least until somebody modifies those lines, which seems to happen every 5 years)? Or would you rather have it clean now? Personally, sometimes I use ts=2 in shell scripts, so it's very annoying to see those badly indented lines, but your mileage may vary. Cheers. -- Felipe Contreras