Skip to content

Releases: FollowTheProcess/cli

v0.18.3

14 Dec 12:43
v0.18.3
3db465d

Choose a tag to compare

Changes

📚 Documentation

v0.18.2

30 Nov 14:58
v0.18.2
c2ad772

Choose a tag to compare

Changes

🐎 Performance

📦 Dependencies

v0.18.1

17 Nov 17:11
v0.18.1
39a5d2b

Choose a tag to compare

Changes

🚀 Features

🔨 Refactoring

📦 Dependencies

v0.18.0

12 Nov 20:26
v0.18.0
c47181d

Choose a tag to compare

Changes

Made Flags follow the same Option customisation mechanism as Args, setting a default value in the cli.Flag function signature is no longer required, a flag assumes it's zero value by default and may be overridden with cli.FlagDefault(T)

💥 Breaking Changes

🚀 Features

🔨 Refactoring

v0.17.0

09 Nov 17:08
v0.17.0
86a50b9

Choose a tag to compare

Changes

This release breaks quite a bit of stuff, but for a good cause!

Goodbye []string and hello to type safe structs!

I've completed re-worked how positional arguments work, instead of getting the raw []string passed to the Run method, I've introduced a mechanism for declaring type-safe structs describing the positional arguments, which are then inferred using generics and parsed similar to how flags already worked.

As a result of this:

  • I've dropped the cli.Allow option and all the argument validators as this new mechanism is much better and allows you to define exactly what
    arguments you want and what types they are
  • The signature of the function provided to cli.Run has changed from func(cmd *cli.Command, args []string) error to func(cmd *cli.Command) error
  • Raw positional arguments can still be obtained using cmd.Args()
  • cli.NoShortHand is now flag.NoShortHand
  • cli.FlagCount is now flag.Count

See the updated README and the updated examples for how to change your code to match the new behaviour.

I've updated my projects that use this and the changes honestly aren't so bad

💥 Breaking Changes

🚀 Features

🚨 Testing

🔨 Refactoring

v0.16.0

21 Oct 19:56
v0.16.0
aa45774

Choose a tag to compare

Changes

🚀 Features

📦 Dependencies

v0.15.0

02 Oct 18:56
v0.15.0
980e8d0

Choose a tag to compare

Changes

🚀 Features

v0.14.1

27 Sep 08:37
v0.14.1
c32196a

Choose a tag to compare

Changes

🚀 Features

👷 Continuous Integration

📦 Dependencies

v0.14.0

19 Jun 18:21
v0.14.0
4386993

Choose a tag to compare

Changes

🚀 Features

👷 Continuous Integration

📦 Dependencies

v0.13.0

16 Feb 09:40
v0.13.0
26f88fc

Choose a tag to compare

Changes

🚀 Features

🪲 Fixes

🐎 Performance

🚨 Testing

📚 Documentation

💄 Style

📦 Dependencies