From unknown Tue Jun 24 17:22:28 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#20959 <20959@debbugs.gnu.org> To: bug#20959 <20959@debbugs.gnu.org> Subject: Status: Switching script mode to rpm puts nonsense on the first line Reply-To: bug#20959 <20959@debbugs.gnu.org> Date: Wed, 25 Jun 2025 00:22:28 +0000 retitle 20959 Switching script mode to rpm puts nonsense on the first line reassign 20959 emacs submitter 20959 Petr Hracek severity 20959 minor thanks From debbugs-submit-bounces@debbugs.gnu.org Thu Jul 02 05:39:32 2015 Received: (at submit) by debbugs.gnu.org; 2 Jul 2015 09:39:32 +0000 Received: from localhost ([127.0.0.1]:36951 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZAaxw-0004lh-6o for submit@debbugs.gnu.org; Thu, 02 Jul 2015 05:39:32 -0400 Received: from eggs.gnu.org ([208.118.235.92]:48503) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZAaxu-0004lQ-18 for submit@debbugs.gnu.org; Thu, 02 Jul 2015 05:39:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZAaxn-0002Tu-Iv for submit@debbugs.gnu.org; Thu, 02 Jul 2015 05:39:24 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.5 required=5.0 tests=BAYES_05 autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:40008) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZAaxn-0002TZ-Ek for submit@debbugs.gnu.org; Thu, 02 Jul 2015 05:39:23 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33733) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZAaxm-0005sk-3q for bug-gnu-emacs@gnu.org; Thu, 02 Jul 2015 05:39:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZAaxi-0002OO-Rj for bug-gnu-emacs@gnu.org; Thu, 02 Jul 2015 05:39:21 -0400 Received: from mx1.redhat.com ([209.132.183.28]:43309) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZAaxi-0002MN-LB for bug-gnu-emacs@gnu.org; Thu, 02 Jul 2015 05:39:18 -0400 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (Postfix) with ESMTPS id 03BFCABB for ; Thu, 2 Jul 2015 09:39:16 +0000 (UTC) Received: from [10.34.4.133] (unused-4-133.brq.redhat.com [10.34.4.133]) by int-mx14.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t629dFnY006156 for ; Thu, 2 Jul 2015 05:39:16 -0400 Message-ID: <559506C3.9070806@redhat.com> Date: Thu, 02 Jul 2015 11:39:15 +0200 From: Petr Hracek User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: bug-gnu-emacs@gnu.org Subject: Switching script mode to rpm puts nonsense on the first line Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.68 on 10.5.11.27 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) Reproducer is: 1) shell-script-mode 2) 'sh-set-shell' 'rpm' then on the first line is #!/usr/bin/rpm which doe not make sense. https://bugzilla.redhat.com/show_bug.cgi?id=1030391#c6 Did you discover it? Whole RedHat bugzilla is here https://bugzilla.redhat.com/show_bug.cgi?id=1030391 -- Petr Hracek Software Engineer Developer Experience Red Hat, Inc Mob: +420777056169 email: phracek@redhat.com From debbugs-submit-bounces@debbugs.gnu.org Thu Jul 02 11:53:32 2015 Received: (at 20959) by debbugs.gnu.org; 2 Jul 2015 15:53:32 +0000 Received: from localhost ([127.0.0.1]:37842 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZAgns-0006lw-0i for submit@debbugs.gnu.org; Thu, 02 Jul 2015 11:53:32 -0400 Received: from eggs.gnu.org ([208.118.235.92]:37967) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZAgnp-0006lh-Qi for 20959@debbugs.gnu.org; Thu, 02 Jul 2015 11:53:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZAgnc-0001EI-FS for 20959@debbugs.gnu.org; Thu, 02 Jul 2015 11:53:24 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD autolearn=disabled version=3.3.2 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:37887) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZAgnZ-0001Cu-9P; Thu, 02 Jul 2015 11:53:13 -0400 Received: from rgm by fencepost.gnu.org with local (Exim 4.82) (envelope-from ) id 1ZAgnY-000782-0e; Thu, 02 Jul 2015 11:53:12 -0400 From: Glenn Morris To: Petr Hracek Subject: Re: bug#20959: Switching script mode to rpm puts nonsense on the first line References: <559506C3.9070806@redhat.com> X-Spook: CBP Wildfire Agriculture Forest fire passwd Reno Tsunami X-Ran: }r3}4;d(d)i$}V*F4zXg/rV(O|^pdb[3O3Bt~ua18.Ms7XT User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::e X-Spam-Score: -5.6 (-----) X-Debbugs-Envelope-To: 20959 Cc: 20959@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.6 (-----) Petr Hracek wrote: > Reproducer is: > 1) shell-script-mode > 2) 'sh-set-shell' 'rpm' > > then on the first line is #!/usr/bin/rpm which doe not make sense. > https://bugzilla.redhat.com/show_bug.cgi?id=1030391#c6 > > Did you discover it? That's what the command is documented to do. I assume it's being called for the effect of "switching the buffer to the rpm dialect of sh-mode". To do that, you can call it like M-: (sh-set-shell "rpm" nil nil) (which isn't much more typing). Perhaps C-u M-x sh-set-shell could mean that. The alternative would be a hard-coded list of interpreters that aren't really shells (I think rpm is the only one sh-mode handles?). From debbugs-submit-bounces@debbugs.gnu.org Fri Jul 17 08:04:08 2015 Received: (at 20959) by debbugs.gnu.org; 17 Jul 2015 12:04:08 +0000 Received: from localhost ([127.0.0.1]:51791 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZG4N6-0005jL-5N for submit@debbugs.gnu.org; Fri, 17 Jul 2015 08:04:08 -0400 Received: from mx1.redhat.com ([209.132.183.28]:38372) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1ZG4N2-0005jB-Uj for 20959@debbugs.gnu.org; Fri, 17 Jul 2015 08:04:05 -0400 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (Postfix) with ESMTPS id 11B388F30C for <20959@debbugs.gnu.org>; Fri, 17 Jul 2015 12:04:02 +0000 (UTC) Received: from [10.40.200.38] (ovpn-200-38.brq.redhat.com [10.40.200.38]) by int-mx14.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t6HC41ts031849 for <20959@debbugs.gnu.org>; Fri, 17 Jul 2015 08:04:02 -0400 Subject: Re: bug#20959: Switching script mode to rpm puts nonsense on the first line To: 20959@debbugs.gnu.org References: <559506C3.9070806@redhat.com> From: Petr Hracek Message-ID: <55A8EF31.7020401@redhat.com> Date: Fri, 17 Jul 2015 14:04:01 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.68 on 10.5.11.27 X-Spam-Score: -6.2 (------) X-Debbugs-Envelope-To: 20959 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -6.2 (------) On 07/02/2015 05:53 PM, Glenn Morris wrote: > Petr Hracek wrote: > >> Reproducer is: >> 1) shell-script-mode >> 2) 'sh-set-shell' 'rpm' >> >> then on the first line is #!/usr/bin/rpm which doe not make sense. >> https://bugzilla.redhat.com/show_bug.cgi?id=1030391#c6 >> >> Did you discover it? > That's what the command is documented to do. > > I assume it's being called for the effect of "switching the buffer to > the rpm dialect of sh-mode". To do that, you can call it like > > M-: (sh-set-shell "rpm" nil nil) > > (which isn't much more typing). > > Perhaps C-u M-x sh-set-shell could mean that. > > The alternative would be a hard-coded list of interpreters that aren't > really shells (I think rpm is the only one sh-mode handles?). Yeah hard-coded list of interpreters that aren't really shells would be great. -- Petr Hracek Software Engineer Developer Experience Red Hat, Inc Mob: +420777056169 email: phracek@redhat.com From debbugs-submit-bounces@debbugs.gnu.org Thu Jul 08 10:24:14 2021 Received: (at 20959) by debbugs.gnu.org; 8 Jul 2021 14:24:14 +0000 Received: from localhost ([127.0.0.1]:57164 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m1Uwo-000340-75 for submit@debbugs.gnu.org; Thu, 08 Jul 2021 10:24:14 -0400 Received: from quimby.gnus.org ([95.216.78.240]:35690) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m1Uwm-00033b-PV for 20959@debbugs.gnu.org; Thu, 08 Jul 2021 10:24:13 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=oWcajliDGOCLP5YW/fObHxS28FIJP47R/2B16Xye96s=; b=FXjZ7NAOKNMS3zCNkSXTWVQmxn ebVBDDX3Np3bfV03ZDscW/k1DuXRNhmOfTePeAmxb3yaH4bAP4NTJh7fPlylp8z+77wAwpCZHx0ee AtIIn1OqEcJ+IE73a7hZk6HCqfr9R8RqHAyafv3oNE/+WjeFFaJ+meyg7leCdyHEoilA=; Received: from cm-84.212.220.105.getinternet.no ([84.212.220.105] helo=elva) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m1UwP-0003Z8-5O; Thu, 08 Jul 2021 16:23:51 +0200 From: Lars Ingebrigtsen To: Glenn Morris Subject: Re: bug#20959: Switching script mode to rpm puts nonsense on the first line References: <559506C3.9070806@redhat.com> X-Now-Playing: Yorkston, Thorne, Khan's _Navarasa: Nine Emotions_: "Darbari" Date: Thu, 08 Jul 2021 16:23:48 +0200 In-Reply-To: (Glenn Morris's message of "Thu, 02 Jul 2015 11:53:11 -0400") Message-ID: <87sg0oriiz.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Glenn Morris writes: > Perhaps C-u M-x sh-set-shell could mean that. I've now done this in Emacs 28. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 20959 Cc: Petr Hracek , 20959@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Glenn Morris writes: > Perhaps C-u M-x sh-set-shell could mean that. I've now done this in Emacs 28. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Thu Jul 08 10:24:09 2021 Received: (at control) by debbugs.gnu.org; 8 Jul 2021 14:24:09 +0000 Received: from localhost ([127.0.0.1]:57161 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m1Uwj-00033j-28 for submit@debbugs.gnu.org; Thu, 08 Jul 2021 10:24:09 -0400 Received: from quimby.gnus.org ([95.216.78.240]:35688) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m1Uwh-00032v-DS for control@debbugs.gnu.org; Thu, 08 Jul 2021 10:24:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=jgOj6LArxAfI4s50OK8EvZiNsHeUOudxhE/rxgaMXvY=; b=uxOmHqoHZv7/5FiqrWc3XTgrVn ORyrbMKYRC7GnJXpDAlxxwYAsLn66zhMSNnyU9JAUBL+m+m16BAJyCdSVyAu4p9fUFy9ssKuj0Dg4 P+Td3FHwm9Wj+keCKeiCkNBJyDZsmyFJkC5PvF+peLMNeL0ug/rmzdGoys3uBKszL7u0=; Received: from cm-84.212.220.105.getinternet.no ([84.212.220.105] helo=elva) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m1UwV-0003ZC-8W for control@debbugs.gnu.org; Thu, 08 Jul 2021 16:24:01 +0200 Date: Thu, 08 Jul 2021 16:23:54 +0200 Message-Id: <87r1g8riit.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #20959 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: close 20959 28.1 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) close 20959 28.1 quit From unknown Tue Jun 24 17:22:28 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 06 Aug 2021 11:24:09 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator