Simple method-chaining tool
Project description
Example
import chainop, argparse
parser = argparse.ArgumentParser()
chop = chainop(parser).add_argument("--arg0")("--arg1")("--foobar")("--arg3", type=int)
foobar_arg:argparse.Action = chop[2] # Get the returned value for the 3rd add_argument call
print(foobar_arg.dest)
chop[3].default = 0
args = parser.parse_args()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
chainop-1.0.0.tar.gz
(1.5 kB
view details)
File details
Details for the file chainop-1.0.0.tar.gz
.
File metadata
- Download URL: chainop-1.0.0.tar.gz
- Upload date:
- Size: 1.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4d8d805c121cc95ade6df7751f37a49671d382b9697f61b0bc696f5aadfd8a79 |
|
MD5 | a4c9d13ab652cefdb37d0314c9f709c3 |
|
BLAKE2b-256 | 023f26da7bd48be43eefaee9341b54c7ddd01ac4c0c17cb15605837bef61e395 |