cargo_unmaintained/github/
mod.rs1use super::{RepoStatus, Url};
2use anyhow::Result;
3
4pub(crate) trait Github {
5 fn load_token(f: impl FnOnce(&str) -> Result<()>) -> Result<bool>;
6 fn save_token() -> Result<()>;
7 fn archival_status(url: Url) -> Result<RepoStatus<()>>;
8}
9
10#[cfg(all(feature = "__mock_github", not(feature = "__real_github")))]
14mod mock;
15#[cfg(all(feature = "__mock_github", not(feature = "__real_github")))]
16pub use mock::Impl;
17
18#[cfg(any(not(feature = "__mock_github"), feature = "__real_github"))]
19mod real;
20#[cfg(any(not(feature = "__mock_github"), feature = "__real_github"))]
21pub use real::Impl;
22#[cfg(any(not(feature = "__mock_github"), feature = "__real_github"))]
23pub use real::util;