Kir Kolyshkin
aabfea87c8
Move some test helpers from docs_test to fish_test
...
This is in preparation to make docs optional.
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2022-04-25 10:04:40 -07:00
59ec2a1d5a
Merge pull request #1262 from dearchap/issue_1199
...
Allow -ve values for int, float & duration
2022-04-24 13:14:41 -04:00
Naveen Gogineni
d198aed170
Add test when flag is not set
2022-04-24 12:06:28 -04:00
Naveen Gogineni
7f37d1d13c
Fix(1199). Allow -ve values for int, float & duration
2022-04-24 11:52:40 -04:00
c864c2425e
Merge pull request #1260 from dearchap/issue_1254
...
Add test case for short option handling
2022-04-24 08:25:02 -04:00
801780fcc1
Merge pull request #1370 from urfave/unshadow-context
...
Unshadow `context` package
2022-04-24 07:56:00 -04:00
9ce946162f
Unshadow context
package
...
and consistently name `*cli.Context` vars and method receivers `cCtx`
2022-04-23 22:07:16 -04:00
Naveen Gogineni
8c5f1fb359
Changes from code review
2022-04-23 19:30:34 -04:00
Naveen Gogineni
dd7065671f
Rebase from master
2022-04-23 19:26:24 -04:00
Naveen Gogineni
156d47e696
Fix: (issue#1254) short options handling needs to proceed from last terminated error
2022-04-23 19:26:24 -04:00
6033c008f2
Merge pull request #1366 from urfave/revert-1352-stalebot-config
...
Revert "Add Stale bot configuration per docs"
2022-04-22 10:56:21 -04:00
b7ee8fff31
Revert "Add Stale bot configuration per docs"
2022-04-22 10:49:09 -04:00
3b6436c36d
Pass non-empty string slice to example app Run
( #1364 )
...
so that it does not panic when run.
2022-04-22 06:35:07 -04:00
f04607a18b
Merge pull request #1361 from urfave/dearchap-remove_reflect
...
Remove reflect calls for doc generation (#1259 )
2022-04-21 23:07:28 -04:00
9fd3cc92ad
Add tests around flag stringifying for all modified types
2022-04-21 23:02:44 -04:00
79ed8b5263
Drop desired min binary size accordingly
2022-04-21 20:35:22 -04:00
d83bb8d85e
Merge branch 'main' into remove_reflect
2022-04-21 20:22:26 -04:00
372ee0a551
Merge pull request #1360 from urfave/schollz-master
...
show only subcommand flags with bash completion (#1186 )
2022-04-21 20:15:12 -04:00
c4c15e1453
Writing tests around changes from #1186
2022-04-21 20:07:06 -04:00
7a231c5eb1
Merge branch 'main' into master
2022-04-21 19:31:22 -04:00
2e3b8fc06b
Merge pull request #1359 from urfave/deps-updates
...
Update dependencies and go.mod spec
2022-04-21 19:21:40 -04:00
6effd9fba8
Update dependencies and go.mod spec
...
Closes #1322
2022-04-21 19:11:01 -04:00
9e59db8b32
Merge pull request #1358 from urfave/trunk-is-main
...
Switch branch references from `master` to `main`
2022-04-21 17:55:02 -04:00
7c50be3d7c
Switch branch references from master
to main
...
Connected to #1349
2022-04-21 16:14:27 -04:00
850cf82509
Merge pull request #1353 from urfave/drop-go111module
...
Drop references/usage of GO111MODULE
2022-04-21 16:10:13 -04:00
22366116c3
Merge branch 'master' into drop-go111module
2022-04-21 16:02:17 -04:00
7f0e884542
Merge pull request #1352 from urfave/stalebot-config
...
Add Stale bot configuration per docs
2022-04-21 16:01:15 -04:00
2e81fd08e4
Merge pull request #1357 from urfave/be-ye-disabling-of-yon-shield
...
Attempting to soften the barrier to entry
2022-04-21 16:00:23 -04:00
16a163bbb2
Bump matrix of supported Go versions ( #1351 )
...
* Bump matrix of supported Go versions
to test on the latest release (^1.18) and drop testing/supporting ^1.15.
* Switch to gfmrun v1.3.0
* Use `go env` correctly
* Add missing `"fmt"` import in example
* Use correct go version strings; other general CI updates
* Drop extra backslashes in continous command
2022-04-21 15:32:32 -04:00
64aad19eb5
Drop extra backslashes in continous command
2022-04-21 15:24:14 -04:00
902f5abbc8
Use correct go version strings; other general CI updates
2022-04-21 15:18:35 -04:00
e63054a42e
Attempting to soften the barrier to entry
...
and also removing issue title formatting that overlaps with label
functionality
2022-04-21 15:07:45 -04:00
5c6ccfb097
Add missing "fmt"
import in example
2022-04-20 14:45:04 -04:00
8c33a078d1
Use go env
correctly
2022-04-20 14:41:26 -04:00
17aa508d22
Switch to gfmrun v1.3.0
2022-04-20 14:38:32 -04:00
d7bc33018b
Drop references/usage of GO111MODULE
2022-04-19 16:57:25 -04:00
e61b99e19a
Add Stale bot configuration per docs
...
with (greatly) extended values for `daysUntilStale` and `daysUntilClose`
per suggestion.
2022-04-19 16:51:13 -04:00
12b9c9d420
Bump matrix of supported Go versions
...
to test on the latest release (^1.18) and drop testing/supporting ^1.15.
2022-04-19 16:32:23 -04:00
Ana Krivokapić
7b2e60968b
Small fixes to the v2 migration guide ( #1340 )
...
- Add missing items to TOC
- Remove items from TOC that don't exist in the document
- Reorder the items in TOC to match the document
2022-03-13 22:29:56 -04:00
Kir Kolyshkin
81cb783759
Fix strconv.ParseFloat usage ( #1335 )
...
The bitSize argument of ParseFloat should either be 32 or 64, not 10.
Found by staticcheck linter.
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2022-02-16 21:29:15 -05:00
Kir Kolyshkin
3df9a3cd86
Don't call open("") ( #1336 )
...
strings.Split(s, sep) returns a slice of a single element containing s
if sep is not found in s. This is true even if s is empty.
As a result, every call to flagFromEnvOrFile results in an attempt to
open a file with empty name. This is seen from strace as
[pid 3287620] openat(AT_FDCWD, "", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 3287620] openat(AT_FDCWD, "", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
...
To fix, check if the string is empty before calling ReadFile.
This also fixes cases where filePath is non-empty but has extra commas.
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2022-02-15 08:28:44 -05:00
Chenxiao Zhao
1bf639b391
remove useless variable declarations ( #1330 )
2022-02-04 02:21:50 -05:00
Daniel Mil
175bb8742c
Bump yaml.v2 version to 2.2.8 ( #1326 )
...
* Bump yamlv2 version
* Update max binary size to fix security vulnerability
2022-01-24 23:51:18 -05:00
Robert Liebowitz
5d61a2f46e
Bump Go version range in CI to 1.15-1.17 ( #1323 )
2022-01-24 08:59:04 +01:00
badcw
e855c4cd1d
fix: Nil pointer when getting context's flagSet( #1325 ) ( #1327 )
...
* fix: Nil pointer when getting context's flagSet in UsageError function(#1325 )
* test: add unit test for nil flagset in Context
2022-01-16 19:22:57 -05:00
Anthony Fok
c2cf7ed6df
Bump github.com/cpuguy83/go-md2man/v2 to v2.0.1 ( #1321 )
...
Also fix test expectation for man contents: dash and underscore
are no longer escaped with backslash in go-md2man v2.0.1
See cpuguy83/go-md2man#74
2022-01-03 22:46:55 -05:00
Anthony Fok
a7d59840f4
Fix reversed Got/Expected in expectFileContent in docs_test.go ( #1320 )
2022-01-03 18:20:18 -05:00
Mritunjay Kumar Sharma
9afa0745ed
docs: Added some deprecated parts in migrating to v2 ( #1319 )
...
Co-authored-by: Robert Liebowitz <rliebz@gmail.com>
2021-12-30 07:17:48 -05:00
Tom Limoncelli
56bfa4be20
DOCS: Replace deprecated functions ( #1317 )
2021-12-30 06:43:21 -05:00
William Wilson
e8d8173889
Make test case compatible with Go 1.17 ( #1299 )
...
* Make test case compatible with Go 1.17
* tweak test case to bring coverage back up
2021-12-05 14:56:34 -05:00