You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: cmd/omitsize/omitsize.go
+23-16Lines changed: 23 additions & 16 deletions
Original file line number
Diff line number
Diff line change
@@ -23,6 +23,8 @@ import (
23
23
var (
24
24
cacheDir=flag.String("cachedir", "", "if non-empty, use this directory to store cached size results to speed up subsequent runs. The tool does not consider the git status when deciding whether to use the cache. It's on you to nuke it between runs if the tree changed.")
25
25
features=flag.String("features", "", "comma-separated list of features to consider, with or without the ts_omit_ prefix")
26
+
27
+
showRemovals=flag.Bool("show-removals", false, "if true, show a table of sizes removing one feature at a time from the full set")
26
28
)
27
29
28
30
funcmain() {
@@ -31,7 +33,9 @@ func main() {
31
33
varall []string
32
34
if*features=="" {
33
35
fork:=rangefeaturetags.Features {
34
-
all=append(all, "ts_omit_"+k)
36
+
ifk.IsOmittable() {
37
+
all=append(all, k.OmitTag())
38
+
}
35
39
}
36
40
} else {
37
41
forv:=rangestrings.SplitSeq(*features, ",") {
@@ -49,27 +53,30 @@ func main() {
49
53
baseC:=measure("tailscale")
50
54
baseBoth:=measure("tailscaled", "ts_include_cli")
51
55
52
-
fmt.Printf("(a) starting with everything and removing a feature...\n\n")
0 commit comments