Skip to main content

A simple argument parser.

Usage

import argpar
import copy
import sys
opts = {"o": None, "g": "foo", "w": None}
flags = ["t", "u"]
posarg = {"path": "/home"}
argpar.parse(opts, flags, {}, copy.copy(sys.argv))

Vaules in opts and posarg dictionaries are default values.

Will automaticaly print help message if a h flag is found and exit.

We recomend copying sys.argv, as arguments get removed during parsing.

Metadata

Release files for argpar 1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for argpar 1
File Size Uploaded
argpar-1.tar.gz 1.8 kB Details

Release files / argpar-1.tar.gz

Download URL argpar-1.tar.gz
Size 1.8 kB
Tags Source
SHA-256 checksum
How to use checksums
c73d61706d785f9496e56092f45fc4fb0c6ea4f95cca05b09e053263b54b6bb9
BLAKE2b-256 checksum
How to use checksums
38056d4493c051d4434a16222cf25675da06001505fc77e8828d52b680c37f34
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

1.2.1

1 release file

1.2

1 release file

1.2.0

1 release file

1.1

2 release files

This release

1 This release

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page