Skip to content

Releases: c4spar/deno-cliffy

v0.25.4

27 Oct 21:44
a64ad88
Compare
Choose a tag to compare

Bug Fixes

  • remove no longer existing validateFlags export from cliffy/mod.ts (#485) (22938a8)
  • prompt: add support for stabilized Deno.consoleSize() (#484) (096bb00)

Chore

v0.25.3

26 Oct 20:43
c35bd83
Compare
Choose a tag to compare

DEPRECATIONS

  • command: rename some types and deprecate old types (#474) (d56ad88)

    The following types have been deprecated and renamed:

    • IArgument -> Argument
    • ICommandGlobalOption -> GlobalOptionOptions
    • ICommandOption -> OptionOptions
    • ICompleteOptions -> CompleteOptions
    • ICompletion -> Completion
    • IEnvVar -> EnvVar
    • IEnvVarOptions -> EnvVarOptions
    • IExample -> Example
    • IGlobalEnvVarOptions -> GlobalEnvVarOptions
    • IOption -> Option
    • IParseResult -> CommandResult
    • IType -> TypeDef
    • ITypeOptions -> TypeOptions
    • IAction -> ActionHandler
    • ICompleteHandler -> CompleteHandler
    • IDescription -> Description
    • IEnvVarValueHandler -> EnvVarValueHandler
    • IFlagValueHandler -> OptionValueHandler
    • IHelpHandler -> HelpHandler
    • IVersionHandler -> VersionHandler
    • TypeValue -> Type.infer
  • flags: rename some types and deprecate old types (#473) (7615ed7)

    The following types have been deprecated and renamed:

    • IParseOptions -> ParseFlagsOptions
    • IFlagOptions -> FlagOptions
    • IFlagArgument -> ArgumentOptions
    • IDefaultValue -> DefaultValue
    • IFlagValueHandler -> ValueHandler
    • IFlagsResult -> ParseFlagsContext
    • ITypeInfo -> ArgumentValue
    • ITypeHandler -> TypeHandler
    • OptionType -> ArgumentType

Bug Fixes

  • command: remove duplicate "Missing argument" in error message (#471) (ee52235)
  • command: escape single quotes in command description for zsh completions (#467) (0b82722)
  • command,flags: value gets ignored if value of an option with an equals sign starts with a dash (#477) (517795a)
  • flags: value of combined short flags with equals sign is assigned to wrong option (#479) (dc29ab5)
  • flags: equalsSign option not working with type option (#476) (08e7465)

Code Refactoring

  • command: export CommandType and IntegerType (#478) (22b8999)
  • command: use full names for generic parameters (#475) (d93d2e0)
  • command,flags: rename errors (#470) (eb046b2)
  • flags: refactor arguments parsing (#480) (273dd41)

Chore

Documentation Updates

v0.25.2

30 Sep 23:44
c9b9bdc
Compare
Choose a tag to compare

Features

  • command: re-implement support for passing global options before sub-commands (#444) (5ff1575)
  • flags: add dotted option (#456) (cd8d73c)
  • flags: add stopOnUnknown option (#453) (b2700e5)
  • flags: return matched standalone option (#451) (6c5e27c)
  • flags: implement parse context (#448) (5890402)

Bug Fixes

  • switch from Deno.setRaw to new Deno.stdin.setRaw (#459) (e5b9416)
  • command: fix type errors with typescript => 4.8 (#460) (9763bd4)
  • command,flags: throw an error if an option without a value has a value (#443) (166101f)
  • flags: don't throw UnexpectedOptionValue error if no flags are defined (#450) (ed50ca3)

Code Refactoring

  • command: throw to many arguments error for global & none global option before a sub-command (#454) (78eec2d)
  • flags: refactor stop early parsing (#449) (e48fc0f)

Chore

v0.25.1

13 Sep 23:24
8fb32d9
Compare
Choose a tag to compare

Bug Fixes

  • command: help text of main command is always shown for validation errors (#441) (41b3547)

Chore

Revert

  • feat(command): support passing global options before sub-command (#388) (#440) (85d3dac)

v0.25.0

03 Sep 13:29
4ce24f7
Compare
Choose a tag to compare

BREAKING CHANGES

  • command: flatten variadic arguments and fix types for variadic option arguments (#418) (bf5f15a)

    Before:

    new Command()
      .arguments("[arg1] [arg2] [...restArgs]")
      .action((_, arg1, arg2, restArgs) => {})

    After:

    new Command()
      .arguments("[arg1] [arg2] [...restArgs]")
      .action((_, arg1, arg2, ...restArgs) => {})

Features

  • command: add .noGlobals() method (#403) (e37fb99)
  • table: allow undefined cell values and override them with row and col span (#427) (89fe0ca)

Bug Fixes

  • command: required options with conflicting options should be optional (#435) (4c71af1)
  • command: type error when trying to add a command instance with child commands (#386) (35fe1de)
  • command: use instance properties for shouldThrowErrors and shouldExit check (#426) (21d7558)
  • command: don't call Deno.exit() in help command when .noExit() is called (#424) (41769ec)
  • command: ignore missing required env vars for global help option (#423) (0290828)
  • command: ignore missing required env vars for help and version option (#415) (275b337)
  • command: do not require full env permission (#416) (bc4c1bd)
  • table: max call stack error thrown for large tables (#433) (f699178)
  • table: error when first row is empty and colSpan is enabled (#432) (4d07eea)
  • table: row doesn't inherit the table settings correctly (#428) (60a781c)

Code Refactoring

  • command: refactor .parseOptions() method (#409) (58df99d)

Chore

Documentation Updates

  • command: update ansi example (#422) (cab4f51)
  • command: fix examples and use local file imports (#410) (4c62043)

v0.24.3

29 Jul 18:21
60ca25c
Compare
Choose a tag to compare

Features

  • command: support passing global options before sub-command (#388) (ecbbcc0)
  • command: add support for list type in arguments (#402) (6dd3a6c)
  • command: indicate required env vars in help text (#394) (8f51cca)

Bug Fixes

  • command: all options should be optional if .allowEmpty() is called (#408) (2ba7386)
  • command: negatable option causes parsing issues when positioned before non-negatable options (#400) (751e1aa)
  • command: explicitly scope fish variables in completion script (#397) (2048a1e)
  • command: help text not always shown for validation error (#401) (e7bc0e8)
  • command: error handling not working correctly (#389) (0d66e88)

Code Refactoring

  • command: refactor .parseCommand() method (#404) (60b9dd7)

Chore

Documentation Updates

v0.24.2

10 May 20:54
e49c37b
Compare
Choose a tag to compare

Bug Fixes

  • command: list type not working in env vars (#379) (9d24d78)

Chore

v0.24.1

10 May 17:38
885674b
Compare
Choose a tag to compare

Features

  • command: allow boolean values in enum type (#377) (1f3d47e)

Bug Fixes

  • command: mapped value not correctly infered in option action handler (#378) (dbde261)

Chore

  • ci: run lint and test workflows on pull requests (#374) (cb2bb7e)
  • ci: disable temporarily the --jobs flag on ci (#376) (235838b)

Documentation Updates

  • correct plural/possessive usage of "'s" (#371) (3964dfe)
  • contributing: update test command to run successfully (#373) (#375) (23d5436)

v0.24.0

02 May 21:44
9b348ee
Compare
Choose a tag to compare

BREAKING CHANGES

  • command: refactor handling of optional options defined with an equals sign (#369) (a51e230)

    Options defined with an equal sign must now also be called with an equal sign: --foo=bar
    Options defined without an equal sign can be called with and without an equal sign as it was before: --foo bar and --foo=bar

Features

Bug Fixes

  • command,flags: fix handling of multi option arguments (#368) (eb75c0a)

v0.23.2

29 Apr 18:32
dc2f97b
Compare
Choose a tag to compare

v0.23.2 (Apr 29, 2022)

Features

  • command: dedent description for better multiline support (#365) (87976a6)
  • command: add support for grouped options (#364) (9d00c61)

Chore

Unit/Integration Tests

  • command: use assertSnapshot for integration tests (#367) (2dc7872)