mirror of
https://github.com/nushell/nushell.git
synced 2025-08-09 23:58:06 +02:00
Rename the Path and Pattern primitives (#2889)
* Rename the Path primitive to FilePath * Rename glob pattern also * more fun * Fix the Windows path methods
This commit is contained in:
@ -45,12 +45,12 @@ fn nu_value_to_sqlite_string(v: Value) -> String {
|
||||
Primitive::Duration(i) => format!("{}", i),
|
||||
Primitive::Decimal(f) => format!("{}", f),
|
||||
Primitive::Filesize(u) => format!("{}", u),
|
||||
Primitive::Pattern(s) => format!("'{}'", s.replace("'", "''")),
|
||||
Primitive::GlobPattern(s) => format!("'{}'", s.replace("'", "''")),
|
||||
Primitive::String(s) => format!("'{}'", s.replace("'", "''")),
|
||||
Primitive::Boolean(true) => "1".into(),
|
||||
Primitive::Boolean(_) => "0".into(),
|
||||
Primitive::Date(d) => format!("'{}'", d),
|
||||
Primitive::Path(p) => format!("'{}'", p.display().to_string().replace("'", "''")),
|
||||
Primitive::FilePath(p) => format!("'{}'", p.display().to_string().replace("'", "''")),
|
||||
Primitive::Binary(u) => format!("x'{}'", encode(u)),
|
||||
Primitive::BeginningOfStream
|
||||
| Primitive::EndOfStream
|
||||
|
Reference in New Issue
Block a user