Skip to content

Commit f3cf764

Browse files
committed
Backing out build tag for suggestions per recommendation
from @kolyshkin 🙇
1 parent 3c923e7 commit f3cf764

File tree

9 files changed

+8
-42
lines changed

9 files changed

+8
-42
lines changed

Diff for: .github/workflows/cli.yml

+1-7
Original file line numberDiff line numberDiff line change
@@ -37,23 +37,17 @@ jobs:
3737
- name: vet
3838
run: go run internal/build/build.go vet
3939

40-
- name: test with urfave_cli_core tag
41-
run: go run internal/build/build.go -tags urfave_cli_core test
42-
4340
- name: test with urfave_cli_no_docs tag
4441
run: go run internal/build/build.go -tags urfave_cli_no_docs test
4542

46-
- name: test with urfave_cli_no_suggest tag
47-
run: go run internal/build/build.go -tags urfave_cli_no_suggest test
48-
4943
- name: test
5044
run: go run internal/build/build.go test
5145

5246
- name: check-binary-size
5347
run: go run internal/build/build.go check-binary-size
5448

5549
- name: check-binary-size with tags (informational only)
56-
run: go run internal/build/build.go -tags urfave_cli_core check-binary-size
50+
run: go run internal/build/build.go -tags urfave_cli_no_docs check-binary-size
5751

5852
- name: Upload coverage to Codecov
5953
if: success() && matrix.go == '1.18.x' && matrix.os == 'ubuntu-latest'

Diff for: Makefile

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@ all: generate vet tag-test test check-binary-size tag-check-binary-size gfmrun t
1717

1818
.PHONY: tag-test
1919
tag-test:
20-
go run internal/build/build.go -tags urfave_cli_core test
20+
go run internal/build/build.go -tags urfave_cli_no_docs test
2121

2222
.PHONY: tag-check-binary-size
2323
tag-check-binary-size:
24-
go run internal/build/build.go -tags urfave_cli_core check-binary-size
24+
go run internal/build/build.go -tags urfave_cli_no_docs check-binary-size
2525

2626
.PHONY: gfmrun
2727
gfmrun:

Diff for: README.md

-10
Original file line numberDiff line numberDiff line change
@@ -59,22 +59,12 @@ import (
5959

6060
You can use the following build tags:
6161

62-
#### `urfave_cli_core`
63-
64-
When set, applies all `urfave_cli_no.+` build tags to minimize resulting binary
65-
size.
66-
6762
#### `urfave_cli_no_docs`
6863

6964
When set, this removes `ToMarkdown` and `ToMan` methods, so your application
7065
won't be able to call those. This reduces the resulting binary size by about
7166
300-400 KB (measured using Go 1.18.1 on Linux/amd64), due to fewer dependencies.
7267

73-
#### `urfave_cli_no_suggest`
74-
75-
When set, the capability enabled by setting `App.Suggest` will be a no-op. This
76-
reduces the resulting binary size due to fewer dependencies.
77-
7868
### GOPATH
7969

8070
Make sure your `PATH` includes the `$GOPATH/bin` directory so your commands can

Diff for: docs.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
//go:build !urfave_cli_no_docs && !urfave_cli_core
2-
// +build !urfave_cli_no_docs,!urfave_cli_core
1+
//go:build !urfave_cli_no_docs
2+
// +build !urfave_cli_no_docs
33

44
package cli
55

Diff for: docs_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
//go:build !urfave_cli_no_docs && !urfave_cli_core
2-
// +build !urfave_cli_no_docs,!urfave_cli_core
1+
//go:build !urfave_cli_no_docs
2+
// +build !urfave_cli_no_docs
33

44
package cli
55

Diff for: internal/build/build.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ func checkBinarySizeActionFunc(c *cli.Context) (err error) {
242242

243243
tags := c.String("tags")
244244

245-
if strings.Contains(tags, "urfave_cli_core") || strings.Contains(tags, "urfave_cli_no_docs") {
245+
if strings.Contains(tags, "urfave_cli_no_docs") {
246246
desiredMinBinarySize = 1.39
247247
}
248248

Diff for: suggestions.go

-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
//go:build !urfave_cli_no_suggest && !urfave_cli_core
2-
// +build !urfave_cli_no_suggest,!urfave_cli_core
3-
41
package cli
52

63
import (

Diff for: suggestions_stubs.go

-12
This file was deleted.

Diff for: suggestions_test.go

-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
//go:build !urfave_cli_no_suggest && !urfave_cli_core
2-
// +build !urfave_cli_no_suggest,!urfave_cli_core
3-
41
package cli
52

63
import (

0 commit comments

Comments
 (0)