From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id YOcPCG+ILGeHBAEAe85BDQ:P1 (envelope-from ) for ; Thu, 07 Nov 2024 09:29:19 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id YOcPCG+ILGeHBAEAe85BDQ (envelope-from ) for ; Thu, 07 Nov 2024 10:29:19 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=qq.com header.s=s201512 header.b=GLv6Rrsv; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1730971759; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=TCJm+dR8sERwaZC6rU0rqTvkR5luMY6OBUM29kp//9w=; b=DQkAohup3IaC/OJsRYxisEYWXXWtl/EcJb1us2K1oN2kpr3MRBWveeXkISxbM1P1K69pt3 tT2Xy6SKLCAWlpwm/de6cNDaRm0WzFtorc2gFvFaGJaS9rP2c0UZYMX4IyeBV5i2rmLH7P UxBveU+hFkRoz82zWCdsVHPdf3QzeF8FLO3nxoprOsb7AUOpHlmqshzOsziW4SDI9vw70J WGRfrOrequtQ+ReQXUeciMssO4EA3nKHHfVcbizAVGcdIpu3kZWVFKqI+NspjthVmK1Jau 0o6SWMB2tD7aih8cmHX5rhcXCRTrEp+P9649+YihplSsZv7KNJu5F1IxEMDAQw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=qq.com header.s=s201512 header.b=GLv6Rrsv; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=none ARC-Seal: i=1; s=key1; d=yhetil.org; t=1730971759; a=rsa-sha256; cv=none; b=OhNdQ3+V9AFQdDlhkB5rlYLlMBZ0+jVrlRi6KzgqDuDGmv5kG535ogA73v4u18BfUF5Gs+ qj4W1NPrN54wlKRH3T+5XJOkN5fnCiZQaMEHAl48emqtH7VOjBgRj+X84/Ex50axyOQhcB wauzf5XTDIW09XJwhaL37t8tB49N8Gs9hlwv6Pj+o1HWN1WvphUuj1fKlIbVlSSTlQm85o K8Z/7w16TVcle0sroh0RnSIRnRbTm+1+/1ht8F1xMgtS9KJKs2KPUL6PCQOKZ87pkq3u72 xmWSfMm9GskvUFRFczVtbFIZxM7sJRiHocVyABIrui+90u7HRx9NYVuEdR7yxA== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id B86D379103 for ; Thu, 07 Nov 2024 10:29:17 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t8yoL-00008o-NH; Thu, 07 Nov 2024 04:28:17 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t8yoJ-00008O-LH for emacs-orgmode@gnu.org; Thu, 07 Nov 2024 04:28:15 -0500 Received: from xmbghk7.mail.qq.com ([43.163.128.49]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t8yoE-0000LZ-Mx for emacs-orgmode@gnu.org; Thu, 07 Nov 2024 04:28:15 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qq.com; s=s201512; t=1730971677; bh=TCJm+dR8sERwaZC6rU0rqTvkR5luMY6OBUM29kp//9w=; h=From:To:Cc:Subject:Date; b=GLv6RrsvCaY+RSdcoADs6EfuQ9AG/VkXcsDlomNqflDE4HbznfvHOzLvZ8pZ6r1Bi EroAANpey+S0UM1vpvEfAmFFvHUPuSuZaC6pMsVC1/KMKLHztPnOscZII2UuO8k84P WGt9Z3tg6J6k+rlLAJwOO3owZgy6TYNn77RESq2U= Received: from shellcodes.org ([171.217.24.55]) by newxmesmtplogicsvrszb16-1.qq.com (NewEsmtp) with SMTP id 62588C87; Thu, 07 Nov 2024 17:24:37 +0800 X-QQ-mid: xmsmtpt1730971477tpcayurve Message-ID: X-QQ-XMAILINFO: M3Q/Kj4zjy60TtwgdM7BtBOptpAekV+o/6Wkx/ZFFiYkEsxuJkK8e5EXLmBzLq nNopWEeX9v45OIAkcF795yenkwt6TY0simmJRvuOs78k2ff1fM0fWEPtpY+P4s7OTbaD0om6Kn+X TpIRtaUKxkfkgzkD9ONXRxtCk3m0YEB5lY+dUefK7oJxaXS5+fPyRtFiDJJA+ep2jeJFY+ggg4Kz mIjoOfBvgUTJYmIHl6akislQXs6I7moq+p6fbRY049U7NVFy/LlhDfXHr78QqxLFS/1B32UK1D0p k6zMTsmXuAu9JNu0SJ0GOpuNFjp0A7Vff9JrzRid9ptTU3/OuWHvXx0kEmJQ9EWx3aUGfwIIsGbe VLdDC2m/dM/7Ox4V5Wvq8mDvh360ZyGphwCcPxy0Qs2lE/EDEe/wklkJnhDrkceytOMg6YIOS34X JYVqz+Vql1n0FksacrbrU5sf7bDQ903kG1ea1vzEwEdUJTtcYpjrU6N+Tfx2/2dmhcuZKAuiMuMc xNVk0P1Zx0eNN+1hQ+p4xORVYZcRSNLnjuT1rXatnRhcmmCvQNxUQGYN1g+Xu5ZspdG+xayLDBuB r5Dr1et7VTnOWfN6FQuAaAT+PavmfNvzSbPL7jjxIPH8u4AFkCoqNORrxvEBXE/g9LFUyeqx5yQ1 hOb7NJkxeuYa5o1SlCOeASdsF1//vuwDq7HYHlkvSOF6k4E7CtP3sht8HUd+z4Jhj2g+jIcRjcIS Qf2vcG5jVA0awdTPU4CghFfqPNN/zi3zIAIoov4UEZSfSNXuUpDWwnHaRsDvu01GPPhh3h5NYeMy 6BWf+iBUMUurXHKq1zPlV/4uUC+tC980dnSYGNkn1EzH7I9LcNcdmM4X7lH736uRI8lSb8sh2nik yRbUfLsvsMQ4wEtZeZmpd1LAmBXpK76MbGQQSK+o4RrHRUI8tH8w7x9DVu4pccrw== X-QQ-XMRINFO: MSVp+SPm3vtS1Vd6Y4Mggwc= Received: by shellcodes.org (sSMTP sendmail emulation); Thu, 07 Nov 2024 17:24:37 +0800 From: Xi Lu To: emacs-orgmode@gnu.org Cc: Xi Lu Subject: [PATCH] Fix `grep' command to handle filenames starting with '-'. Date: Thu, 7 Nov 2024 17:24:33 +0800 X-OQ-MSGID: <20241107092433.125307-1-lx@shellcodes.org> X-Mailer: git-send-email 2.45.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: none client-ip=43.163.128.49; envelope-from=lx@shellcodes.org; helo=xmbghk7.mail.qq.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, MSGID_FROM_MTA_HEADER=0.001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Scanner: mx11.migadu.com X-Migadu-Spam-Score: 2.35 X-Spam-Score: 2.35 X-Migadu-Queue-Id: B86D379103 X-TUID: sb3D5QiV7WlJ * lisp/org-mouse.el (org-mouse-context-menu): Fix `grep' command to handle filenames starting with '-' by adjusting wildcard usage to prevent misinterpretation as options. --- lisp/org-mouse.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/org-mouse.el b/lisp/org-mouse.el index 322d98682..7f85653f2 100644 --- a/lisp/org-mouse.el +++ b/lisp/org-mouse.el @@ -627,7 +627,7 @@ This means, between the beginning of line and the point." ["Sparse Tree" (org-occur ',region-string)] ["Find in Buffer" (occur ',region-string)] ["Grep in Current Dir" - (grep (format "grep -rnH -e '%s' *" ',region-string))] + (grep (format "grep -rnH -e '%s' ./*" ',region-string))] ["Grep in Parent Dir" (grep (format "grep -rnH -e '%s' ../*" ',region-string))] "--" -- 2.45.2