Skip to content

Commit

Permalink
Rollup merge of rust-lang#36841 - GuillaumeGomez:process_doc, r=steve…
Browse files Browse the repository at this point in the history
…klabnik

Improve process module doc a bit

r? @steveklabnik
  • Loading branch information
steveklabnik authored Sep 30, 2016
2 parents a6f0a41 + 3176ba4 commit e3e5f1f
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion src/libstd/process.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,25 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.

//! Working with processes.
//! A module for working with processes.
//!
//! # Examples
//!
//! Basic usage where we try to execute the `cat` shell command:
//!
//! ```should_panic
//! use std::process::Command;
//!
//! let mut child = Command::new("/bin/cat")
//! .arg("file.txt")
//! .spawn()
//! .expect("failed to execute child");
//!
//! let ecode = child.wait()
//! .expect("failed to wait on child");
//!
//! assert!(ecode.success());
//! ```
#![stable(feature = "process", since = "1.0.0")]

Expand Down

0 comments on commit e3e5f1f

Please sign in to comment.