Skip to content

Commit

Permalink
Update our own submodule automatically
Browse files Browse the repository at this point in the history
  • Loading branch information
alexcrichton committed Apr 8, 2016
1 parent 8fbe14b commit b5e4d05
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ git2 = "0.3"
First, you'll need to install _CMake_. Afterwards, just run:

```sh
$ git clone --recursive https://github.com/alexcrichton/git2-rs
$ git clone https://github.com/alexcrichton/git2-rs
$ cd git2-rs
$ cargo build
```
Expand Down
1 change: 0 additions & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ install:
- set CARGO_TARGET_DIR=%APPVEYOR_BUILD_FOLDER%\target
- rustc -V
- cargo -V
- git submodule update --init

build: false

Expand Down
5 changes: 5 additions & 0 deletions libgit2-sys/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@ fn main() {
}
}

if !Path::new("libgit2").exists() {
let _ = Command::new("git").args(&["submodule", "update", "--init"])
.status();
}

let target = env::var("TARGET").unwrap();
let host = env::var("HOST").unwrap();
let windows = target.contains("windows");
Expand Down

0 comments on commit b5e4d05

Please sign in to comment.