Command Reference
Execute Program
Spawns a process and waits for it to complete.
Arguments can be either a string literal or identifier. Note that the lexical definition of an identifier is loosened for this command to provide better ergonomics.
Metadata
Adds metadata to the current unit which can be viewed with august inspect
.
This command is a no op at runtime.
Depends On
Makes a unit a dependency of the current unit.
This command is a no op at runtime.
Do Unit
Runs a unit sequentially.
Concurrency Block
0.6
Warning
This language feature is only useable on the async runtime as it would be incredibly expensive on threads.
Runs multiple commands at the same time. Works best for long running operations like executing CLI tools.
August runs the commands in a unit sequentially and a unit's dependencies in parallel. The concurrency block is useful for running multiple independent commands inline rather than creating new units.
The example above can be written without the concurrency block like so:
unit ConcurrencyBlock {
depends_on(__command_a, __command_b, __command_c)
}
unit __command_a {
do(A)
}
unit __command_b {
~(cargo build)
}
unit __command_c {
~(npm run build)
}
Module: fs
Create File
Creates an empty file.
Create Directory
Recursively creates an empty directory.
Remove File/Directory
Removes a file or recursively removes a directory.
Copy File/Directory
Copies a file or directory to a different location.
Move File/Directory
Moves a file or directory to a different location.
Copy and Move Expansions
0.6
Expands to several copy
/move
calls to a common destination directory.
Example
Is equivalent to the following:Print/EPrint File
Print the contents of a file to stdout
or stderr
Module: io
io::print("Hello, World!")
io::println("Hello, World!")
io::eprint("Hello, World!")
io::eprintln("Hello, World!")
Prints text to stdout
or stderr
Module: env
Set Environment Variable
Sets the value of an environment variable for the august
process, which is inherited by child processes spawned by exec
.
Remove Environment Variable
Clears the value of an environment variable for the august
process, which is inherited by child processes spawned by exec
.
Add to PATH
Adds a directory to the PATH
environment variable for the august
process,
which is inherited by child processes spawned by exec
.
Directory path is canonicalised before it is added.
Remove from PATH
Remove a directory to the PATH
environment variable for the august
process,
which is inherited by child processes spawned by exec
.
Directory path is canonicalised during comparison for removal.