Kiln » gitkiln Read More
Clone URL:  
Pushed to one repository · View In Graph Contained in master

allow calling up help, even if not in a repository

Changeset 395812569db2

Parent 7f3c3aaa2bd2

by Profile picture of User 12Benjamin Pollack <benjamin@fogcreek.com>

Changes to one file · Browse files at 395812569db2 Showing diff from parent 7f3c3aaa2bd2 Diff from another changeset...

Change 1 of 1 Show Entire File main.go Stacked
 
262
263
264
265
266
 
 
 
 
 
 
 
267
268
269
 
262
263
264
 
 
265
266
267
268
269
270
271
272
273
274
@@ -262,8 +262,13 @@
  os.Exit(1)   }   if _, err := kiln.GitRoot(); err != nil { - fmt.Fprintln(os.Stderr, "git-kiln must be run from within a Git repository") - os.Exit(1) + if len(os.Args) == 2 && os.Args[1] == "help" { + showHelp() + return + } else { + fmt.Fprintln(os.Stderr, "git-kiln must be run from within a Git repository") + os.Exit(1) + }   }     bytesOut, err := exec.Command("git", "ls-remote", "--get-url").Output()