#shell #sh #bash

shellwords

Manipulate strings according to the word parsing rules of the UNIX Bourne shell

3 releases (stable)

1.1.0 Jun 27, 2020
1.0.0 Sep 27, 2018
0.1.0 Sep 3, 2017

#122 in Command-line interface

Download history 16064/week @ 2023-11-18 17252/week @ 2023-11-25 17130/week @ 2023-12-02 17209/week @ 2023-12-09 16308/week @ 2023-12-16 12420/week @ 2023-12-23 16243/week @ 2023-12-30 17828/week @ 2024-01-06 18393/week @ 2024-01-13 20463/week @ 2024-01-20 20456/week @ 2024-01-27 21186/week @ 2024-02-03 21659/week @ 2024-02-10 21895/week @ 2024-02-17 21041/week @ 2024-02-24 24087/week @ 2024-03-02

92,370 downloads per month
Used in 53 crates (35 directly)

MIT license

10KB
142 lines

shellwords

Crate shellwords provides utilities for parsing strings as they would be interpreted by the UNIX Bourne shell.

Examples

Split a string into a vector of words in the same way the UNIX Bourne shell does:

assert_eq!(split("here are \"two words\"").unwrap(), ["here", "are", "two words"]);

shellwords is released under the MIT license. See LICENSE for details.


lib.rs:

Crate shellwords provides utilities for parsing strings as they would be interpreted by the UNIX Bourne shell.

Dependencies

~2.1–3MB
~53K SLoC