From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Felix Dietrich Newsgroups: gmane.emacs.help Subject: Re: terminal command with output in current buffer Date: Fri, 16 Jul 2021 21:35:05 +0200 Message-ID: <877dhqoxw6.fsf@sperrhaken.name> References: <87czrip6db.fsf@sperrhaken.name> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7736"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Fri Jul 16 21:35:56 2021 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m4Tcq-0001ln-Lx for geh-help-gnu-emacs@m.gmane-mx.org; Fri, 16 Jul 2021 21:35:56 +0200 Original-Received: from localhost ([::1]:49430 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m4Tco-0001HS-ML for geh-help-gnu-emacs@m.gmane-mx.org; Fri, 16 Jul 2021 15:35:54 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53322) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m4TcA-0001HK-Mn for help-gnu-emacs@gnu.org; Fri, 16 Jul 2021 15:35:14 -0400 Original-Received: from mout.kundenserver.de ([212.227.126.133]:50501) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m4Tc8-0005YQ-UD for help-gnu-emacs@gnu.org; Fri, 16 Jul 2021 15:35:14 -0400 Original-Received: from localhost ([77.11.230.244]) by mrelayeu.kundenserver.de (mreue010 [212.227.15.167]) with ESMTPSA (Nemesis) id 1Mt7Pt-1lFOC72fTl-00tQBZ for ; Fri, 16 Jul 2021 21:35:10 +0200 In-Reply-To: (lisa-asket@perso.be's message of "Fri, 16 Jul 2021 19:00:13 +0200 (CEST)") X-Provags-ID: V03:K1:CcV0ZKWor7Mab51sxhRT5zpV6fZYtzt/gH6/Yc8K8dhrBkzRi83 rwM9BqIOHq5ijy2ZH6F00aUr6a1RM7pALnA6Uy89bpDjy1NAbX1LShS2isTRAx05wnbJNJj qxmvGzTWfNTbzXO29cXfKvMQBIGmLbLq5TJmEhVpy6cH5+BVIHnZcVVXlL2NGOGRoySpwFC z6SJdpaDOFyehtrdXnhdA== X-UI-Out-Filterresults: notjunk:1;V03:K0:TX37+ASO36Q=:acGP/7xnhr3YBOzHRHlMye ve1GoDTM82Tlvpx2Xn12CYzs1/RUXR88tD9KwFjLU+SVeqc5lsDs8GuJnmhrSLI2SkLcTxHYM +FjRw4Wc6YNnnq37cLUX+HabKvb2abMf/7CN3H0+Bgo1LvW1yM6dLLaYMv9lkbI8eMYsphxoa vzW0OwiPrgUjraJbCkPiR2H9yZS7IEcnmr+laxAZOCTpNu3a+wW1wKNdxBPFrxm4WXLvOu4Iq t9EjtQm8MepZ7AfQvjEPmS3mMJsfss/w/WDoUM/tjHcpnHvFPdiM6AXqKh3r6+5mWkjygQWk7 7S1+lXNYHzJwMrzj/ffsLRD19GSovuzs/FLIhPpMVsPNAy3lksFnJjYsdqydRQsgPpppCxt3a spgh5IqoL2XOCUrpYvKm2dFNUyETzgvCTypQDCqvaWDnE6XLu42V69v2zHEixyTsFsoF/JVch VTmEqT8V/fesl20ok5BoSBE3aR23AZqJ8Upr7Eur+WOXuJeCsmPmOzLvb58lr2LPJG7NsZ1Al 2tooR+ZzdD4gUtj9Nz3anwURp/N2SM7AZZsNUf20m0J8IkwJWA7KhYcat8LVPDUE+YrVFOxZ2 l0Mj7QMbVDaVokQ/Otcdgdf+t74l4B1HscYP6Fc9125xVMSnLloxyTjI5guJx/xBTCZBBuBE7 H4SG735P+b0YmSMXbHSgG+GxOaGMcKy59WUvnFtB66WMLTG7Q+nhrT8qsr/XE5YkkkbxsBp7T paeCg8ymdgX9tWHQP+CNsqqTajl3r8iovZMYIESU9A55M6pyWfC8YcR3lZZ955pPU93scjXf Received-SPF: none client-ip=212.227.126.133; envelope-from=felix.dietrich@sperrhaken.name; helo=mout.kundenserver.de 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, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:131768 Archived-At: lisa-asket@perso.be writes: > Many thanks, I just did not follow what asynchronously meant. Fair enough. > Can one assign default values when `read-from-minibuffer` in empty? =E2=80=9Cread-from-minibuffer=E2=80=9D as well as the functions suggested b= y Stefan Monnier (=E2=80=9Cread-number=E2=80=9D, =E2=80=9Cread-string=E2=80=9D, =E2= =80=A6) have a parameter DEFAULT or DEFAULT-VALUE (or similar) that you may use for that purpose; read their documentation. You may also check the return value of =E2=80=9Cread-from-minibuffer=E2=80= =9D or =E2=80=9Cread-string=E2=80=9D and act accordingly: (let ((read-result (read-from-minibuffer "Prompt: "))) (if (seq-empty-p read-result) (setq read-result "default-value"))) See also: --=20 Felix Dietrich