all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Filipp Gunbin <fgunbin@fastmail.fm>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: "Rudolf Adamkovič" <salutis@me.com>, 52546@debbugs.gnu.org
Subject: bug#52546: 29.0.50; Missing space character
Date: Sat, 23 Apr 2022 03:14:24 +0300	[thread overview]
Message-ID: <m2wnfg1wrj.fsf@fastmail.fm> (raw)
In-Reply-To: <875yrkvm2w.fsf@gnus.org> (Lars Ingebrigtsen's message of "Sun, 19 Dec 2021 13:03:03 +0100")

[-- Attachment #1: Type: text/plain, Size: 772 bytes --]

reopen 52546
quit

On 19/12/2021 13:03 +0100, Lars Ingebrigtsen wrote:

> Rudolf Adamkovič <salutis@me.com> writes:
>
>> Reproduction steps:
>>
>> 1. run 'emacs -Q'
>> 2. type M-x and then 'sql-sqlite'
>> 3. see a prompt in the minibuffer
>>
>> Expected: 'Database ~/…'
>>
>> Actual: 'Database~/…' (notice the missing space character)
>
> Yup.  I've now fixed this in Emacs 29.
>
> -- 
> (domestic pets only, the antidote for overdose, milk.)
>    bloggy blog: http://lars.ingebrigtsen.no

(Sending once again, after unarchiving the bug.  The previous message
didn't add the comment.)

It looks like this fixes the bug more correctly.  We should pass
sql-get-login-ext the "raw" prompt, which is then passed to
format-prompt.

Filipp


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: patch --]
[-- Type: text/x-diff, Size: 1581 bytes --]

From 361ea4a001e1634f1acc620ceeca3d32a348a798 Mon Sep 17 00:00:00 2001
From: Filipp Gunbin <fgunbin@fastmail.fm>
Date: Sat, 23 Apr 2022 01:59:53 +0300
Subject: [PATCH] Fix prompts in sql-get-login again

* lisp/progmodes/sql.el (sql-get-login-ext): Use prompt-def
everywhere.
(sql-get-login): Revert previous fix. (bug#52546)
---
 lisp/progmodes/sql.el | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el
index 13fba0c705..18b0274fbf 100644
--- a/lisp/progmodes/sql.el
+++ b/lisp/progmodes/sql.el
@@ -3216,7 +3216,7 @@ sql-get-login-ext
      (cond
       ((plist-member plist :file)
        (let ((file-name
-              (read-file-name prompt
+              (read-file-name prompt-def
                               (file-name-directory last-value)
                               default
                               (if (plist-member plist :must-match)
@@ -3246,7 +3246,7 @@ sql-get-login-ext
                         default))
 
       ((plist-get plist :number)
-       (read-number prompt (or default last-value 0)))
+       (read-number (concat prompt ": ") (or default last-value 0)))
 
       (t
        (read-string prompt-def last-value history-var default))))))
@@ -3318,7 +3318,7 @@ sql-get-login
          (sql-get-login-ext 'sql-server "Server" 'sql-server-history plist))
 
         ('database
-         (sql-get-login-ext 'sql-database "Database: "
+         (sql-get-login-ext 'sql-database "Database"
                             'sql-database-history plist))
 
         ('port
-- 
2.36.0


  reply	other threads:[~2022-04-23  0:14 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-16 10:39 bug#52546: 29.0.50; Missing space character Rudolf Adamkovič via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-12-19 12:03 ` Lars Ingebrigtsen
2022-04-23  0:14   ` Filipp Gunbin [this message]
2022-04-23 12:29     ` Lars Ingebrigtsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m2wnfg1wrj.fsf@fastmail.fm \
    --to=fgunbin@fastmail.fm \
    --cc=52546@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    --cc=salutis@me.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.