This commit is contained in:
Michael Zhang 2020-04-21 22:40:35 -05:00
parent b7a62b8c57
commit 2251c4f8ea
Signed by: michael
GPG key ID: BDA47A31A3C8EE6B
4 changed files with 22 additions and 1 deletions

View file

@ -13,7 +13,7 @@ path = "bin/git.rs"
tokio = { version = "0.2.18", default-features = false, features = ["fs", "macros"] } tokio = { version = "0.2.18", default-features = false, features = ["fs", "macros"] }
typenum = { version = "1.12.0", default-features = false } typenum = { version = "1.12.0", default-features = false }
structopt = { version = "0.3.13", default-features = false } structopt = { version = "0.3.13", default-features = false }
anyhow = { version = "1.0.28", default-features = false } anyhow = { version = "1.0.28" }
thiserror = { version = "1.0.15", default-features = false } thiserror = { version = "1.0.15", default-features = false }
futures = { version = "0.3.4", default-features = false } futures = { version = "0.3.4", default-features = false }
sha-1 = { version = "0.8.2", default-features = false } sha-1 = { version = "0.8.2", default-features = false }

View file

@ -0,0 +1,5 @@
compatibility
=============
| feature | status | notes |
|---|---|---|

View file

@ -1,7 +1,22 @@
use std::path::Path; use std::path::Path;
use std::env;
use anyhow::Result;
pub struct Repository {} pub struct Repository {}
impl Repository { impl Repository {
pub async fn open(path: impl AsRef<Path>) {} pub async fn open(path: impl AsRef<Path>) {}
} }
pub async fn is_repo(path: impl AsRef<Path>) -> Result<bool> {
Ok(false)
}
/// Find the closest repository that the current repository belongs to.
pub async fn find() -> Result<Option<Repository>> {
let mut cwd = env::current_dir()?;
loop {
}
Ok(None)
}

View file

@ -0,0 +1 @@