Function get_writable_load_path

Source
pub fn get_writable_load_path(runtime: bool) -> Result<PathBuf, Error>
Expand description

Returns a writable VOA load path.

Gathers the list of writable VOA load paths for the calling user and returns the first from the list. If runtime is true, the ephemeral load path of the calling user is selected instead.

§Errors

Returns an error if no LoadPath can be found.

§Examples

use voa::commands::get_writable_load_path;

let config_dir = get_writable_load_path(false)?;
let runtime_dir = get_writable_load_path(true)?;