From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Dale Mellor Newsgroups: gmane.lisp.guile.bugs Subject: bug#41127: [PATCH 0/2] New (ice-9 command-line-processor). Date: Thu, 07 May 2020 13:24:39 +0100 Organization: DM Bespoke Computer Solutions Ltd Message-ID: <9066a0d4437b09b02aa12c3d91dcefd607aa1e03.camel@rdmp.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="68869"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Evolution 3.30.5-1.1 To: 41127@debbugs.gnu.org Original-X-From: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Thu May 07 17:42:09 2020 Return-path: Envelope-to: guile-bugs@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 1jWif2-000Hp6-3D for guile-bugs@m.gmane-mx.org; Thu, 07 May 2020 17:42:08 +0200 Original-Received: from localhost ([::1]:44082 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jWif0-0004fV-TH for guile-bugs@m.gmane-mx.org; Thu, 07 May 2020 11:42:06 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:59612) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jWiex-0004fK-4D for bug-guile@gnu.org; Thu, 07 May 2020 11:42:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:60460) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jWiew-00035r-Qn for bug-guile@gnu.org; Thu, 07 May 2020 11:42:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jWiew-0002yH-PC for bug-guile@gnu.org; Thu, 07 May 2020 11:42:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dale Mellor Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Thu, 07 May 2020 15:42:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 41127 X-GNU-PR-Package: guile X-GNU-PR-Keywords: patch X-Debbugs-Original-To: bug-guile Original-Received: via spool by submit@debbugs.gnu.org id=B.158886609911367 (code B ref -1); Thu, 07 May 2020 15:42:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 7 May 2020 15:41:39 +0000 Original-Received: from localhost ([127.0.0.1]:43771 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jWieY-0002xG-RP for submit@debbugs.gnu.org; Thu, 07 May 2020 11:41:39 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:35792) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jWfZz-0005Ru-Qv for submit@debbugs.gnu.org; Thu, 07 May 2020 08:24:44 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:44656) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jWfZz-00052b-KI for bug-guile@gnu.org; Thu, 07 May 2020 08:24:43 -0400 Original-Received: from ec2-52-19-174-175.eu-west-1.compute.amazonaws.com ([52.19.174.175]:51370 helo=rdmp.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jWfZy-0000Kb-P2 for bug-guile@gnu.org; Thu, 07 May 2020 08:24:43 -0400 Original-Received: from [127.0.0.1] (helo=localhost) by rdmp.org with esmtp (Exim 4.92) (envelope-from ) id 1jWfZw-00016O-Ed for bug-guile@gnu.org; Thu, 07 May 2020 12:24:40 +0000 Received-SPF: softfail client-ip=52.19.174.175; envelope-from=guile-qf1qmg@rdmp.org; helo=rdmp.org X-detected-operating-system: by eggs.gnu.org: First seen = 2020/05/07 07:54:38 X-ACL-Warn: Detected OS = ??? X-Spam_score_int: 5 X-Spam_score: 0.5 X-Spam_bar: / X-Spam_report: (0.5 / 5.0 requ) BAYES_00=-1.9, RDNS_DYNAMIC=0.982, SPF_HELO_SOFTFAIL=0.732, SPF_SOFTFAIL=0.665 autolearn=_AUTOLEARN X-Spam_action: no action X-Mailman-Approved-At: Thu, 07 May 2020 11:41:37 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Original-Sender: "bug-guile" Xref: news.gmane.io gmane.lisp.guile.bugs:9746 Archived-At: Modelled after GNU libc's argp command-line parser, and building on (ice-9 getopt-long), this new module allows a one-stop specification of how the command line options should work, (process-command-line (command-line) application "my-app" version "1.0" usage "[OPTION]..." license GPLv3 option (--option=3 -o "demonstration option")) and then the program gets variables with names like --option which convey the state of the command line, (cond (--option => (lambda (o) (display "The option value is ") (display o) (newline))) and as a side-effect --help, --version and --usage are dealt with automatically!