-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Please replace command string with array #5
Comments
I think the relevant line is here. Currently it's defined as a string. I believe you can get this to accept either a string or an array by defining a utility type like this: #[derive(Deserialize)]
#[serde(untagged)]
pub enum Command {
Simple(String),
Array(Vec<String>),
} and then using this Awesome work tho, I really love QEMU for testing and I'm super lazy to remember all the command-line options it takes! |
Hi, thanks for the feedback. I think this request makes sense — internally we are splitting the string into tokens like this anyways. But I’d also like to keep the current string format as a second option. It will be important for #3. So the above suggestion :). There is precedent for multiple syntax forms (see Dockerfile |
If you really want to support two forms, then please make string form accept bash command, i. e. command for processing by shell. This is exactly what docker's CMD does |
Hi. I just read this config in your blog:
I don't like this config. It seems that
command
key is meant to be passed directly toexecve
function (as opposed to command, which needs to be interpreted by shell). But then command is conceptually an array, not a string! So, please, replace with this (toml syntax allows this):The text was updated successfully, but these errors were encountered: