From: Fiona Ebner <f.ebner@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [RFC qemu-server 4/4] partially fix #2077: remove dependency on Term::ReadLine
Date: Thu, 18 Sep 2025 15:50:56 +0200 [thread overview]
Message-ID: <20250918135215.95188-5-f.ebner@proxmox.com> (raw)
In-Reply-To: <20250918135215.95188-1-f.ebner@proxmox.com>
Originally-by: Stefan Hrdlicka <s.hrdlicka@proxmox.com>
[FE: rebase and adapt to rename]
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
---
Dependency bump for pve-common needed.
Advanced users might be unhappy with not having the editing and
history shortcuts Term::ReadLine provides anymore.
debian/control | 1 -
src/PVE/CLI/qm.pm | 6 ++----
2 files changed, 2 insertions(+), 5 deletions(-)
diff --git a/debian/control b/debian/control
index f02ef742..7af87a05 100644
--- a/debian/control
+++ b/debian/control
@@ -46,7 +46,6 @@ Depends: conntrack,
libpve-common-perl (>= 9.0.3),
libpve-guest-common-perl (>= 5.2.2),
libpve-storage-perl (>= 9.0.7),
- libterm-readline-gnu-perl,
liburi-perl,
libuuid-perl,
perl (>= 5.10.0-19),
diff --git a/src/PVE/CLI/qm.pm b/src/PVE/CLI/qm.pm
index 2e56e234..8ee5033a 100755
--- a/src/PVE/CLI/qm.pm
+++ b/src/PVE/CLI/qm.pm
@@ -12,7 +12,6 @@ use IO::Select;
use IO::Socket::UNIX;
use JSON;
use POSIX qw(strftime);
-use Term::ReadLine;
use URI::Escape;
use PVE::APIClient::LWP;
@@ -23,6 +22,7 @@ use PVE::GuestImport::OVF;
use PVE::INotify;
use PVE::JSONSchema qw(get_standard_option);
use PVE::Network;
+use PVE::PTY;
use PVE::RPCEnvironment;
use PVE::SafeSyslog;
use PVE::Tools qw(extract_param file_get_contents);
@@ -551,9 +551,7 @@ __PACKAGE__->register_method({
print "Entering QEMU Monitor for VM $vmid - type 'help' for help\n";
- my $term = Term::ReadLine->new('qm');
-
- while (defined(my $input = $term->readline('qm> '))) {
+ while (defined(my $input = PVE::PTY::read_line('qm> '))) {
chomp $input;
next if $input =~ m/^\s*$/;
last if $input =~ m/^\s*q(uit)?\s*$/;
--
2.47.2
_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
prev parent reply other threads:[~2025-09-18 13:52 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-18 13:50 [pve-devel] [PATCH-SERIES common/manager/qemu-server 0/4] " Fiona Ebner
2025-09-18 13:50 ` [pve-devel] [PATCH common 1/4] pty: introduce read_line() function Fiona Ebner
2025-09-22 9:45 ` Stoiko Ivanov
2025-09-18 13:50 ` [pve-devel] [RFC common 2/4] developer readme: remove libterm-readline-gnu-perl dependency Fiona Ebner
2025-09-18 14:12 ` Fiona Ebner
2025-09-18 13:50 ` [pve-devel] [PATCH manager 3/4] partially fix #2077: remove dependency on Term::ReadLine Fiona Ebner
2025-09-18 13:50 ` Fiona Ebner [this message]
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=20250918135215.95188-5-f.ebner@proxmox.com \
--to=f.ebner@proxmox.com \
--cc=pve-devel@lists.proxmox.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.
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.