Skip to content

Commit d6afd2a

Browse files
committed
Stop modules from rudely exposing their guts publicly: #5
1 parent 4d84e78 commit d6afd2a

File tree

1 file changed

+19
-24
lines changed

1 file changed

+19
-24
lines changed

src/lib.rs

Lines changed: 19 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -44,46 +44,41 @@ extern crate hostname;
4444

4545
#[macro_use]
4646
mod ffi_helpers;
47-
pub mod command;
47+
mod command;
4848
mod project;
49-
pub mod directory;
50-
pub mod error;
51-
pub mod file;
49+
mod directory;
50+
mod error;
51+
mod file;
5252
#[macro_use]
5353
mod host;
5454
#[cfg(all(test, feature = "remote-run"))]
5555
mod mock_env;
56-
pub mod package;
56+
mod package;
5757
#[cfg(feature = "remote-run")]
5858
mod payload;
59-
pub mod service;
59+
mod service;
6060
mod target;
61-
pub mod template;
61+
mod template;
6262

63-
pub use command::{Command, CommandResult};
64-
pub use directory::{Directory, DirectoryOpts};
65-
pub use error::Error;
66-
pub use file::{File, FileOwner};
67-
pub use host::Host;
63+
pub use command::{Command, CommandResult, ffi as command_ffi};
64+
pub use directory::{Directory, DirectoryOpts, ffi as directory_ffi};
65+
pub use error::{Error, geterr};
66+
pub use file::{File, FileOwner, ffi as file_ffi};
67+
pub use host::{Host, ffi as host_ffi};
6868
pub use host::data::open as data_open;
69-
pub use host::ffi::{host_data, get_value, get_value_keys, get_value_type};
70-
#[cfg(feature = "local-run")]
71-
pub use host::ffi::host_local;
72-
#[cfg(feature = "remote-run")]
73-
pub use host::ffi::{host_connect, host_connect_endpoint, host_connect_payload, host_close};
7469
pub use mustache::{MapBuilder, VecBuilder};
75-
pub use package::Package;
76-
pub use package::providers::{Provider, ProviderFactory, Providers};
70+
pub use package::{Package, ffi as package_ffi};
71+
pub use package::providers::Providers;
7772
#[cfg(feature = "remote-run")]
78-
pub use payload::Payload;
73+
pub use payload::{Payload, ffi as payload_ffi};
7974
#[cfg(feature = "remote-run")]
75+
#[doc(hidden)]
8076
pub use payload::config::Config as PayloadConfig;
81-
#[cfg(feature = "remote-run")]
82-
pub use payload::ffi::{payload_new, payload_build, payload_run, payload_free};
77+
#[doc(hidden)]
8378
pub use project::{Language, ProjectConfig};
8479
pub use serde_json::Value;
85-
pub use service::{Service, ServiceRunnable};
86-
pub use template::Template;
80+
pub use service::{Service, ServiceRunnable, ffi as service_ffi};
81+
pub use template::{Template, ffi as template_ffi};
8782
pub use zfilexfer::FileOptions;
8883

8984
#[cfg(feature = "remote-run")]

0 commit comments

Comments
 (0)