From nobody Fri Feb 11 15:17:12 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id C29D319C145B; Fri, 11 Feb 2022 15:17:15 +0000 (UTC) (envelope-from garga@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JwHKR4sSFz4vhF; Fri, 11 Feb 2022 15:17:15 +0000 (UTC) (envelope-from garga@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1644592635; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=IEXpWnWyUVL6DbXzB38ezXtNbGlZh/jVcmjwFfEA1vo=; b=EeleuEooym6jIu4MZtN95c1TJ0HvcitTprz+XcR22+zVhB/S4cNhK/3SGR2eCFmFyNRhfd xs/b4jAgVgS7kvxldnc+P6YCQQa9RcR/zLSP6R3coafKBlxqLy/wj/7noeovtci3exhxUn ADvxnQEvMYHkitqJSFA1OfzvgDYR+/JJeXQLKpZbaeDP7o+A7TH3EStZCKFKTLHcBGTi60 VxIWjanQvbg5s5SHS3fyhOA08IoSKRwJzLlPItPHPcMS+u8JrBQ1ysZFi6AUSQ+6xH9CCb kaRJwrloWtfNcJpDeapUUyXkOVMtlENl+G5by4soNM7CE+DdKDtVYhr2T83kFw== Received: from [172.21.4.170] (dynamic-177-53-82-16.telecominternet.net.br [177.53.82.16]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) (Authenticated sender: garga) by smtp.freebsd.org (Postfix) with ESMTPSA id 4870DCD30; Fri, 11 Feb 2022 15:17:14 +0000 (UTC) (envelope-from garga@FreeBSD.org) Message-ID: <0a83179a-6bcc-a6e6-7719-28c7b5f2aac1@FreeBSD.org> Date: Fri, 11 Feb 2022 12:17:12 -0300 List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.6.0 Subject: Re: git: b1f7154cb125 - main - gitignore: ignore vim swap files & .rej/.orig Content-Language: en-US From: Renato Botelho To: Drew Gallatin Cc: Kristof Provost , Andrew Gallatin , "Alexander V. Chernikov" , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org, Conrad Meyer , Andriy Gapon References: <202201170935.20H9ZM3T069547@gitrepo.freebsd.org> <72061959-88f8-d2ee-b4e9-f09ca084411e@cs.duke.edu> <4FC1EDC4-9F20-4271-B468-715A1727AC8A@FreeBSD.org> <4f4f6a83-3def-4938-6e40-5460486cc415@FreeBSD.org> <898c0071-66bc-db5f-b70d-72429d167279@FreeBSD.org> In-Reply-To: <898c0071-66bc-db5f-b70d-72429d167279@FreeBSD.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1644592635; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=IEXpWnWyUVL6DbXzB38ezXtNbGlZh/jVcmjwFfEA1vo=; b=aShIqU6vGwjVoW5cgxNTOYLvCBnni6DELhRTE0q4iilVuBV2rI+49ZQ70U5XAuuvB4nXsb kqm7QaTTaO7+G46Uhey5XOaTYKKJbbcZzT0FyQcy3+ea/v07zGtWvc4c4xF/2b/h6Ft8Sp VyQknF/B5MDR4J7yeiClst61hRNxGQ6WKZ4nQxmWPhsiJPJ52ZuVBYq3BRh+tuZRxIeGNQ o3U/bCmYs5c669Dw1RYWHadZutQZTtewXZ+W1NqK1eTmC+PDG3QY9WJkEj9C9+TY2T3MZV KCekXmB8Q8inGbNQUsHjopjR7OLXZ8VOjiKofYwF3f2OJUykia7oMeC34q+oLw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1644592635; a=rsa-sha256; cv=none; b=xgkX0tLRGOaWq0fVN+6WLxhopHW5/RJFA9TUD7vUpPUO/qgZ3RqceSY6qYXJL5erXWKicM KmbWjuwr6jQB48nIcn/TgRLSnUdwCmPmG6pmHyR7pcDSZmL6lzLOm0aGHmzMIegxcU02GP Ez1oOYjVJ1phRLPrJKmo+Un2N1ZbCJf3bu2Fpx25wkFdVR7h1IRXgyh2JrMJDZwrWX+/6T VRltTRmgTzsD+TjDCvC/ML6hynv71xvHpFKQhF3r8DsYhois5VfjPz9YFTZf2sZFA26y7j /R4072udlXCPJrpZ5JBqDJjpKZkWlVU1GkokCoz4/8+ubi6SDIdAXJG+wTb97g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N On 11/02/22 12:12, Renato Botelho wrote: > On 11/02/22 12:11, Renato Botelho wrote: >> On 11/02/22 12:02, Drew Gallatin wrote: >>> I think that has the same problem.  Either that, or I'm doing the >>> escaping wrong.  Using tcsh: >>> >>> <10:01am>beast/gallatin:work1>git clean -ne '\!\*.orig' >>> Would remove ktrace.out >>> <10:01am>beast/gallatin:work1>git clean -xn | grep rej >>> Would remove FreeBSD/sys/dev/mlx5/mlx5_en/en_hw_tls.h.rej >> >> -e expects a pattern of files/directories that you don't want to >> remove and can be used multiple times.  It worked here on a testing repo: >> >> sh-3.2$ git clean -xn >> Would remove d1/d2/bar.orig >> Would remove d1/d2/bar.rej >> Would remove foo.orig >> Would remove foo.rej >> >> sh-3.2$ git clean -xn -e '*.rej' >> Would remove d1/d2/bar.orig >> Would remove foo.orig >> >> sh-3.2$ git clean -xn -e '*.rej' -e '*.orig' >> sh-3.2$ >> > > Fat finger here, I was about to say you also can specify what you want > to remove using wildcards like: > > sh-3.2$ git clean -xn '*.orig' > Would remove d1/d2/bar.orig > Would remove foo.orig > > sh-3.2$ git clean -xn '*.rej' > Would remove d1/d2/bar.rej > Would remove foo.rej > And last but not least, if it does what you need, you can create an alias to make it simpler: sh-3.2$ git config --global alias.myclean "clean -xn '*.rej' '*.orig'" sh-3.2$ git myclean Would remove d1/d2/bar.orig Would remove d1/d2/bar.rej Would remove foo.orig Would remove foo.rej -- Renato Botelho