BSD Ports

devel/lua-optparse 3 FreeBSD

Parse and process command-line options

System
FreeBSD
Repository
FreeBSD ports
Maintainer
[email protected]
Port added
Last update
Commit
327200dab8
License
MIT
Categories
devel

Description

In the common case, you can write the long-form help output typical of a modern command line program, and let this module generate a custom parser that collects and diagnoses the options it describes.

The parser is actually an object instance which can then be tweaked for the uncommon case, by hand, or by using the "on" method to tie your custom handlers to options that are not handled quite the way you'd like.

This is a pure Lua library compatible with LuaJIT, Lua 5.1, 5.2, 5.3, 5.4 and 5.5.

Version history 1

  1. 3 327200dab8

Upstream's version as each commit to the port's Makefile set it, or as this site first saw it in the system's packages; the tree's own revisions are not versions here.

Install

Binary package:

pkg install lua51-optparse

From the ports tree:

cd /usr/ports/devel/lua-optparse/ && make install clean

To depend on this port in another port's Makefile:

RUN_DEPENDS=	lua51-optparse>0:devel/lua-optparse

Packages

The version each package repository carries. “-” means the repository builds no package of it, “n/a” that there is no such repository.

Repositoryaarch64amd64armv6armv7i386
FreeBSD:14:latest-3--3
FreeBSD:14:quarterly--n/a--
FreeBSD:15:latest33n/a--
FreeBSD:15:quarterly--n/an/an/a
FreeBSD:16:latest-3n/an/an/a
FreeBSD:16:quarterlyn/an/an/an/an/a

Dependency graph

Ports that need it on the left, what it needs to run on the right; at most 8 of each. "Dependencies" below lists them all.

Dependencies

The Makefile names none itself; they come from USES and USE_*.

The full lists below include those, and their dependencies in turn.

Build dependencies 2
Run dependencies 2
Required by 1

Configuration

No options to configure.

USES
lua:module
Service scripts
none
Flavors
lua52-optparse-3, lua53-optparse-3, lua54-optparse-3, lua55-optparse-3

Files

pkg-plist 3
  • %%LUA_MODSHAREDIR%%/optparse/_normalize.lua
  • %%LUA_MODSHAREDIR%%/optparse/init.lua
  • %%LUA_MODSHAREDIR%%/optparse/version.lua
distinfo 1
FileSizeSHA256
gvvaughan-optparse-v3_GH0.tar.gz334466856f78357a699850f56572adef514efca877dde2ac8a831bdae48e56096c90d

Commit history 1

DateCommitCreditsLog message
327200dab8 Po-Chuan Hsieh devel/lua-optparse: Add lua-optparse 3
In the common case, you can write the long-form help output typical of a modern command line program, and let this module generate a custom parser that collects and diagnoses the options it describes. The parser is actually an object instance which can then be tweaked for the uncommon case, by hand, or by using the "on" method to tie your custom handlers to options that are not handled quite the way you'd like. This is a pure Lua library compatible with LuaJIT, Lua 5.1, 5.2, 5.3, 5.4 and 5.5.