dagger/dsl/workspace
Types
pub type ForDirectory
pub type ForWorkspace
Values
pub fn client_id(
parent: types.Workspace,
client client: types.Client,
then handler: fn(Result(String, types.QueryError)) -> a,
) -> a
The client ID that owns this workspace’s host filesystem.
pub fn directory(
parent: types.Workspace,
path path: String,
with with_fn: fn(Opts(ForDirectory)) -> Opts(ForDirectory),
) -> types.Directory
Returns a Directory from the workspace. Path is relative to workspace root. Use “.” for the root directory.
pub fn file(
parent: types.Workspace,
path path: String,
) -> types.File
Returns a File from the workspace. Path is relative to workspace root.
pub fn find_up(
parent: types.Workspace,
name name: String,
with with_fn: fn(Opts(ForFindUp)) -> Opts(ForFindUp),
client client: types.Client,
then handler: fn(Result(String, types.QueryError)) -> a,
) -> a
Search for a file or directory by walking up from the start path within the workspace. Returns the path relative to the workspace root if found, or null if not found. The search stops at the workspace root and will not traverse above it.
pub fn id(parent: types.Workspace) -> types.Workspace
A unique identifier for this Workspace.
pub fn opt_exclude(
opts: Opts(ForDirectory),
val: List(String),
) -> Opts(ForDirectory)
pub fn opt_gitignore(
opts: Opts(ForDirectory),
val: Bool,
) -> Opts(ForDirectory)
pub fn opt_include(
opts: Opts(ForDirectory),
val: List(String),
) -> Opts(ForDirectory)
pub fn opt_skip_migration_check(
opts: Opts(ForWorkspace),
val: Bool,
) -> Opts(ForWorkspace)
pub fn root(
parent: types.Workspace,
client client: types.Client,
then handler: fn(Result(String, types.QueryError)) -> a,
) -> a
Absolute path to the workspace root directory.
pub fn workspace(
with with_fn: fn(Opts(ForWorkspace)) -> Opts(ForWorkspace),
) -> types.Workspace