Start taking out futures feature
This commit is contained in:
parent
241806b757
commit
3e70feb75f
|
|
@ -33,8 +33,8 @@ check:
|
||||||
build_all-features:
|
build_all-features:
|
||||||
stage: build
|
stage: build
|
||||||
script:
|
script:
|
||||||
- cargo clippy --all --features latest,futures -- -D warnings
|
- cargo clippy --all --features latest -- -D warnings
|
||||||
- cargo test --verbose --all --features latest,futures
|
- cargo test --verbose --all --features latest
|
||||||
|
|
||||||
build_default-features:
|
build_default-features:
|
||||||
stage: build
|
stage: build
|
||||||
|
|
@ -58,7 +58,7 @@ docs:
|
||||||
script:
|
script:
|
||||||
- make merge-lgpl-docs
|
- make merge-lgpl-docs
|
||||||
- cargo rustdoc --verbose --package ostree-sys --features dox -- ${RUSTDOC_OPTS}
|
- cargo rustdoc --verbose --package ostree-sys --features dox -- ${RUSTDOC_OPTS}
|
||||||
- cargo rustdoc --verbose --package ostree --features dox,futures -- ${RUSTDOC_OPTS}
|
- cargo rustdoc --verbose --package ostree --features dox -- ${RUSTDOC_OPTS}
|
||||||
artifacts:
|
artifacts:
|
||||||
paths:
|
paths:
|
||||||
- target/doc
|
- target/doc
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@ exclude = [
|
||||||
]
|
]
|
||||||
|
|
||||||
[package.metadata.docs.rs]
|
[package.metadata.docs.rs]
|
||||||
features = ["dox", "futures"]
|
features = ["dox"]
|
||||||
|
|
||||||
[badges.gitlab]
|
[badges.gitlab]
|
||||||
repository = "fkrull/ostree-rs"
|
repository = "fkrull/ostree-rs"
|
||||||
|
|
@ -29,13 +29,11 @@ repository = "fkrull/ostree-rs"
|
||||||
name = "ostree"
|
name = "ostree"
|
||||||
|
|
||||||
[workspace]
|
[workspace]
|
||||||
members = ["sys"]
|
members = [".", "sys"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
libc = "0.2"
|
libc = "0.2"
|
||||||
bitflags = "1"
|
bitflags = "1"
|
||||||
fragile = { version = "0.3.0", optional = true }
|
|
||||||
futures-preview = { version = "0.3.0-alpha", optional = true }
|
|
||||||
lazy_static = "1.1"
|
lazy_static = "1.1"
|
||||||
glib = "0.9.0"
|
glib = "0.9.0"
|
||||||
gio = "0.8.0"
|
gio = "0.8.0"
|
||||||
|
|
@ -51,7 +49,6 @@ tempfile = "3"
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
dox = ["ostree-sys/dox"]
|
dox = ["ostree-sys/dox"]
|
||||||
futures = ["futures-preview", "fragile", "gio/futures", "glib/futures"]
|
|
||||||
v2014_9 = ["ostree-sys/v2014_9"]
|
v2014_9 = ["ostree-sys/v2014_9"]
|
||||||
v2015_7 = ["v2014_9", "ostree-sys/v2015_7"]
|
v2015_7 = ["v2014_9", "ostree-sys/v2015_7"]
|
||||||
v2016_4 = ["v2015_7", "ostree-sys/v2016_4"]
|
v2016_4 = ["v2015_7", "ostree-sys/v2016_4"]
|
||||||
|
|
|
||||||
|
|
@ -18,12 +18,6 @@ extern crate libc;
|
||||||
extern crate bitflags;
|
extern crate bitflags;
|
||||||
#[macro_use]
|
#[macro_use]
|
||||||
extern crate lazy_static;
|
extern crate lazy_static;
|
||||||
#[cfg(feature = "futures")]
|
|
||||||
extern crate fragile;
|
|
||||||
#[cfg(feature = "futures")]
|
|
||||||
extern crate futures;
|
|
||||||
|
|
||||||
use glib::Error;
|
|
||||||
|
|
||||||
// code generated by gir
|
// code generated by gir
|
||||||
#[rustfmt::skip]
|
#[rustfmt::skip]
|
||||||
|
|
@ -35,26 +29,33 @@ pub use crate::auto::*;
|
||||||
|
|
||||||
// handwritten code
|
// handwritten code
|
||||||
mod checksum;
|
mod checksum;
|
||||||
|
pub use crate::checksum::*;
|
||||||
|
|
||||||
#[cfg(any(feature = "v2018_6", feature = "dox"))]
|
#[cfg(any(feature = "v2018_6", feature = "dox"))]
|
||||||
mod collection_ref;
|
mod collection_ref;
|
||||||
mod functions;
|
|
||||||
#[cfg(any(feature = "v2019_3", feature = "dox"))]
|
|
||||||
mod kernel_args;
|
|
||||||
mod object_name;
|
|
||||||
mod repo;
|
|
||||||
#[cfg(any(feature = "v2018_2", feature = "dox"))]
|
|
||||||
mod repo_checkout_at_options;
|
|
||||||
mod se_policy;
|
|
||||||
pub use crate::checksum::*;
|
|
||||||
#[cfg(any(feature = "v2018_6", feature = "dox"))]
|
#[cfg(any(feature = "v2018_6", feature = "dox"))]
|
||||||
pub use crate::collection_ref::*;
|
pub use crate::collection_ref::*;
|
||||||
|
|
||||||
|
mod functions;
|
||||||
pub use crate::functions::*;
|
pub use crate::functions::*;
|
||||||
|
|
||||||
|
#[cfg(any(feature = "v2019_3", feature = "dox"))]
|
||||||
|
mod kernel_args;
|
||||||
#[cfg(any(feature = "v2019_3", feature = "dox"))]
|
#[cfg(any(feature = "v2019_3", feature = "dox"))]
|
||||||
pub use crate::kernel_args::*;
|
pub use crate::kernel_args::*;
|
||||||
|
|
||||||
|
mod object_name;
|
||||||
pub use crate::object_name::*;
|
pub use crate::object_name::*;
|
||||||
|
|
||||||
|
mod repo;
|
||||||
pub use crate::repo::*;
|
pub use crate::repo::*;
|
||||||
|
|
||||||
|
#[cfg(any(feature = "v2018_2", feature = "dox"))]
|
||||||
|
mod repo_checkout_at_options;
|
||||||
#[cfg(any(feature = "v2018_2", feature = "dox"))]
|
#[cfg(any(feature = "v2018_2", feature = "dox"))]
|
||||||
pub use crate::repo_checkout_at_options::*;
|
pub use crate::repo_checkout_at_options::*;
|
||||||
|
|
||||||
|
mod se_policy;
|
||||||
pub use crate::se_policy::*;
|
pub use crate::se_policy::*;
|
||||||
|
|
||||||
// tests
|
// tests
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,6 @@
|
||||||
#[cfg(any(feature = "v2016_4", feature = "dox"))]
|
#[cfg(any(feature = "v2016_4", feature = "dox"))]
|
||||||
use crate::RepoListRefsExtFlags;
|
use crate::RepoListRefsExtFlags;
|
||||||
use crate::{Checksum, ObjectName, ObjectType, Repo};
|
use crate::{Checksum, ObjectName, ObjectType, Repo};
|
||||||
#[cfg(feature = "futures")]
|
|
||||||
use futures::future;
|
|
||||||
use gio;
|
use gio;
|
||||||
use gio_sys;
|
use gio_sys;
|
||||||
use glib;
|
use glib;
|
||||||
|
|
@ -11,8 +9,6 @@ use glib::Error;
|
||||||
use glib::IsA;
|
use glib::IsA;
|
||||||
use glib_sys;
|
use glib_sys;
|
||||||
use ostree_sys;
|
use ostree_sys;
|
||||||
#[cfg(feature = "futures")]
|
|
||||||
use std::boxed::Box as Box_;
|
|
||||||
use std::collections::{HashMap, HashSet};
|
use std::collections::{HashMap, HashSet};
|
||||||
use std::path::Path;
|
use std::path::Path;
|
||||||
use std::{mem::MaybeUninit, ptr};
|
use std::{mem::MaybeUninit, ptr};
|
||||||
|
|
@ -225,7 +221,6 @@ impl Repo {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(feature = "futures")]
|
|
||||||
pub fn write_content_async_future<P: IsA<gio::InputStream> + Clone + 'static>(
|
pub fn write_content_async_future<P: IsA<gio::InputStream> + Clone + 'static>(
|
||||||
&self,
|
&self,
|
||||||
expected_checksum: Option<&str>,
|
expected_checksum: Option<&str>,
|
||||||
|
|
@ -306,7 +301,6 @@ impl Repo {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(feature = "futures")]
|
|
||||||
pub fn write_metadata_async_future(
|
pub fn write_metadata_async_future(
|
||||||
&self,
|
&self,
|
||||||
objtype: ObjectType,
|
objtype: ObjectType,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue