This package has been deprecated

Author message:

Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.

pasamanos

0.0.10 • Public • Published

Pasamanos:

A CLI parameter parser that makes 0 decisions about how you structure your project.

Usage

First, obviously, npm install pasamanos.

In your code:

import { params } from 'pasamanos'

const fromCLI = params(process.argv, {
    'verbose':'v',
    'force':'f'
});

// or maybe take key=value pairs from somewhere else? I won't judge you.
const fromSomewhereElse = params(['-f=false','-v','--very-long-flag'], {
    'verbose':'v',
    'force':'f'
});

if(fromCli.verbose){
    // say something
}

or

const { params } = require('pasamanos');

Troubleshooting

I get some variant of Error [ERR_REQUIRE_ESM] when using your module
Turns out using `microbundle` to ensure compatibility between ESM and CommonJS and such
uncovered a whole rat king worth of flags and version compatibility issues. 
Sorry about that.
If you encounter this error, your best choice is requiring `pasamanos/dist/index.cjs`
instead of the default `pasamanos`. 
Is this production ready?
I mean it's below 0.1 yet but you do you.

Package Sidebar

Install

npm i pasamanos

Weekly Downloads

0

Version

0.0.10

License

MIT

Unpacked Size

53.5 kB

Total Files

28

Last publish

Collaborators

  • cfvergara