Skip to content

Commit 066cbdb

Browse files
Update documentation with note about quoting
1 parent 146ffdc commit 066cbdb

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,10 @@ $./split_tests -help
6767
CircleCI API key (or set CIRCLECI_API_KEY environment variable) - required to use CircleCI
6868
-circleci-project string
6969
CircleCI project name (e.g. github/leonid-shevtsov/split_tests) - required to use CircleCI
70-
-glob string
71-
Glob pattern to find test files (default "spec/**/*_spec.rb")
72-
-exclude-glob string
73-
Glob pattern to exclude test files
70+
-glob 'pattern'
71+
Glob pattern to find test files (default 'spec/**/*_spec.rb'). Make sure to single-quote the pattern to avoid shell expansion.
72+
-exclude-glob 'pattern'
73+
Glob pattern to exclude test files. Make sure to single-quote as well.
7474
-help
7575
Show this help text
7676
-junit

main.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,8 @@ func addNewFiles(fileTimes map[string]float64, currentFileSet map[string]bool) {
6666
}
6767

6868
func parseFlags() {
69-
flag.StringVar(&testFilePattern, "glob", "spec/**/*_spec.rb", "Glob pattern to find test files")
70-
flag.StringVar(&excludeFilePattern, "exclude-glob", "", "Glob pattern to exclude test files")
69+
flag.StringVar(&testFilePattern, "glob", "spec/**/*_spec.rb", "Glob pattern to find test files. Make sure to single-quote to avoid shell expansion.")
70+
flag.StringVar(&excludeFilePattern, "exclude-glob", "", "Glob pattern to exclude test files. Make sure to single-quote.")
7171

7272
flag.IntVar(&splitIndex, "split-index", -1, "This test container's index (or set CIRCLE_NODE_INDEX)")
7373
flag.IntVar(&splitTotal, "split-total", -1, "Total number of containers (or set CIRCLE_NODE_TOTAL)")

0 commit comments

Comments
 (0)