-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Add conversion from tokio::process::Command
to std::process::Command
#7001
Comments
Since this feature is relatively easy to implement, opening this issue is mainly to initiate some discussions and see if there are any reasons that I have not considered that actually make this feature unnecessary. We can also discuss which solution we choose to implement it with. If everything is clear, then I am willing to directly submit an associated PR. |
Thoughts @ipetkov ? Since we already have |
I suppose it would be fine. Most of the tokio-specific logic happens on spawn (and not before we forward calls to the std version) and since we already expose |
Which signature do you expect to implement?
|
We can start with just |
Is your feature request related to a problem? Please describe.
The reverse conversion currently exists, but the conversion from
tokio
tostd
(withownership
) does not currently exist.The
as_std
andas_std_mut
methods only return references, and becausestd::process::Command
is notClone
, its ownership cannot be moved out through simple dereference. Therefore, a separate conversion method which can move out ownership is needed.Describe the solution you'd like
Describe alternatives you've considered
Or some named methods such as:
The text was updated successfully, but these errors were encountered: