From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id 3FEB890F96 for ; Tue, 13 Feb 2024 11:54:30 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 2162C34DF8 for ; Tue, 13 Feb 2024 11:54:30 +0100 (CET) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS for ; Tue, 13 Feb 2024 11:54:29 +0100 (CET) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 43C3047C90 for ; Tue, 13 Feb 2024 11:54:29 +0100 (CET) Message-ID: <76bff08e-d283-480c-b686-83e51d544b8a@proxmox.com> Date: Tue, 13 Feb 2024 11:54:28 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: pmg-devel@lists.proxmox.com References: <20231025112026.4109852-1-d.csapak@proxmox.com> From: Mira Limbeck In-Reply-To: <20231025112026.4109852-1-d.csapak@proxmox.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-SPAM-LEVEL: Spam detection results: 0 AWL 0.212 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record T_SCC_BODY_TEXT_LINE -0.01 - URIBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [proxmox.com, main.rs] Subject: Re: [pmg-devel] [PATCH log-tracker v2] use pico-args instead of clap X-BeenThere: pmg-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox Mail Gateway development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Feb 2024 10:54:30 -0000 On 10/25/23 13:20, Dominik Csapak wrote: > Instead of upgrading from clap3 to clap4 (which seems to change their > interface every year or so), switch to the much smaller pico-args. (Same > as we did for termproxy recently, see [0]) Got rid of 13 dependencies, while adding 1 (pico-args) according to `cargo update` output. > It has almost all features we need (except producing help output) and > supports OsString, but wihout any dependencies. This decreases compile > time and reduces the size of the resulting binary. It also reduces the > lines of code. > > The only difference is now the different output for errors, e.g. for > missing values of options. > > Help output is copied from the old clap output. > > 0: https://git.proxmox.com/?p=pve-xtermjs.git;a=commitdiff;h=24d707d0506b120a085b06b5f2b6000696879a1e > > Signed-off-by: Dominik Csapak > --- > changes from v1: > * extracted the pkg_version into a variable for interpolated use > * improved commit message, e.g. by referencing the termproxy commit > > Cargo.toml | 2 +- > src/main.rs | 223 +++++++++++++++++++--------------------------------- > 2 files changed, 83 insertions(+), 142 deletions(-) > Looks good to me. Tested it both via GUI (which calls the CLI) and the CLI directly. Tested-by: Mira Limbeck Reviewed-by: Mira Limbeck