pub enum Action {
WriteConfig {
path: PathBuf,
vendored: PathBuf,
format: String,
pointers: Vec<String>,
fallback: Option<PathBuf>,
},
CopyDir {
from: PathBuf,
to: PathBuf,
},
CopyFile {
from: PathBuf,
to: PathBuf,
},
GitSkill {
url: String,
commit: String,
subpath: String,
to: PathBuf,
},
Run {
argv: Vec<String>,
env: BTreeMap<String, String>,
},
Remove {
path: PathBuf,
},
}Expand description
One concrete thing an auto step does.
Variants§
WriteConfig
Restore a vendored config file (whole, or only pointers merged into the target).
Secrets missing from the environment are taken from path, else from fallback
(the user’s live config, when materializing into a prefix on the same machine).
Fields
CopyDir
Copy a vendored directory (a skill) into place.
CopyFile
Copy a file (an instruction file) into place.
GitSkill
Fetch a skill from git at a commit.
Run
Run a command.
Remove
Move a path aside to <path>.hlock-bak.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Action
impl<'de> Deserialize<'de> for Action
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Action, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Action, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for Action
impl Serialize for Action
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for Action
Auto Trait Implementations§
impl Freeze for Action
impl RefUnwindSafe for Action
impl Send for Action
impl Sync for Action
impl Unpin for Action
impl UnsafeUnpin for Action
impl UnwindSafe for Action
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more