Rebuild everything against ocaml-4.02.0-0.8.git10e45753.fc22.
[goaljobs-goals.git] / git.ml
1 (* Utilities for handling git repositories. *)
2
3 open Goaljobs
4
5 let git_has_local_changes dir =
6   let lines = shlines "cd %s && git status --porcelain" (quote dir) in
7   let lines = List.filter (
8     fun line ->
9       let code = String.sub line 0 2 in
10       code <> "??"
11   ) lines in
12   List.length lines > 0