Skip to content

v1.7.1

Compare
Choose a tag to compare
@lukeed lukeed released this 13 Feb 02:41
· 18 commits to master since this release

Patches

  • Allows option flags to come before the command name: 4ccffe0

    Important: As with any CLI program, these options must come in pairs!
    Otherwise your command name may be interpreted as the flag's value.

    This is not a new limitation.
    Previously, Sade ignored all input flags that were defined before the command.

    $ doorman greet Luke --excited 
    #=> βœ“ hello Luke!
    
    $ doorman --excited greet Luke 
    #=> ✘ Unknown command: Luke
    
    $ doorman --type Howdy greet Luke
    #=> βœ“ Howdy Luke!

    This was done so that Sade programs could be aliased/saved with common options.
    For example, you may want to save something like ley to a custom script:

    // package.json
    {
      "scripts": {
        "migrate": "ley -r dotenv/config"
      }
    }

    As of this release, this is now possible! πŸŽ‰

    Developers can successfully run this script like so: yarn migrate up
    Again, only as of this patch release, the -r dotenv/config option will still be applied.