Skip to content
Myr

Merge branch 'pr/opposing-options' of https://github.com/Asha20/fd into pr/opposing-options

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Vukašin Stepanović · committed by Vukašin Stepanović · parents 668af05, 9bc8fab · Browse files · 10 files+241 added−109 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

10 files+241 added−109 removed

  • other:+241 added−109 removed

10 files+241 added−109 removed

modified:.github/workflows/CICD.yml+8 added-8 removed
14 unmodified lines
1516jobs:17 min_version:18 name: Minimum supported rust version19 runs-on: ubuntu-18.0419 runs-on: ubuntu-20.0420 steps:21 - name: Checkout source code22 uses: actions/checkout@v223
20 unmodified lines
44 strategy:45 fail-fast: false46 matrix:47 job:48 - { os: ubuntu-18.04, target: arm-unknown-linux-gnueabihf , use-cross: true }49 - { os: ubuntu-18.04, target: arm-unknown-linux-musleabihf, use-cross: true }50 - { os: ubuntu-18.04, target: aarch64-unknown-linux-gnu , use-cross: true }51 - { os: ubuntu-18.04, target: i686-unknown-linux-gnu , use-cross: true }52 - { os: ubuntu-18.04, target: i686-unknown-linux-musl , use-cross: true }53 - { os: ubuntu-18.04, target: x86_64-unknown-linux-gnu }54 - { os: ubuntu-18.04, target: x86_64-unknown-linux-musl , use-cross: true }48 - { os: ubuntu-20.04, target: arm-unknown-linux-gnueabihf , use-cross: true }49 - { os: ubuntu-20.04, target: arm-unknown-linux-musleabihf, use-cross: true }50 - { os: ubuntu-20.04, target: aarch64-unknown-linux-gnu , use-cross: true }51 - { os: ubuntu-20.04, target: i686-unknown-linux-gnu , use-cross: true }52 - { os: ubuntu-20.04, target: i686-unknown-linux-musl , use-cross: true }53 - { os: ubuntu-20.04, target: x86_64-unknown-linux-gnu }54 - { os: ubuntu-20.04, target: x86_64-unknown-linux-musl , use-cross: true }55 - { os: macos-10.15 , target: x86_64-apple-darwin }56 # - { os: windows-2019, target: i686-pc-windows-gnu } ## disabled; error: linker `i686-w64-mingw32-gcc` not found57 - { os: windows-2019, target: i686-pc-windows-msvc }58 - { os: windows-2019, target: x86_64-pc-windows-gnu }
275 unmodified lines
modified:doc/fd.1+11 added-4 removed
55 unmodified lines
56pattern contains an uppercase character (smart case).57.TP58.B \-g, \-\-glob59Perform a glob-based search instead of a regular expression search.60If combined with the '\-\-full-path' option, '**' can be used to match multiple path components.61.TP62.B \-\-regex63Perform a regular-expression based search (default). This can be used to override --glob.64.TP
154 unmodified lines
219.RE220.RE221.TP222.BI "\-\-changed-within " date|duration222Filter results based on the file modification time. The argument can be provided as a specific223point in time (\fIYYYY-MM-DD HH:MM:SS\fR) or as a duration (\fI10h, 1d, 35min\fR).223Filter results based on the file modification time.224Files with modification times greater than or equal to the argument will be returned.225The argument can be provided as a duration (\fI10h, 1d, 35min\fR) or as a specific point226in time in either full RFC3339 format with time zone, or as a date or datetime in the227local time zone (\fIYYYY-MM-DD\fR or \fIYYYY-MM-DD HH:MM:SS\fR).228.B --change-newer-than229can be used as an alias.230231Examples:232 \-\-changed-within 2weeks233 \-\-change-newer-than "2018-10-27 10:00:00"234.TP235.BI "\-\-changed-before " date|duration232Filter results based on the file modification time. The argument can be provided as a specific233point in time (\fIYYYY-MM-DD HH:MM:SS\fR) or as a duration (\fI10h, 1d, 35min\fR).236Filter results based on the file modification time.237Files with modification times less than or equal to the argument will be returned.238The argument can be provided as a duration (\fI10h, 1d, 35min\fR) or as a specific point239in time in either full RFC3339 format with time zone, or as a date or datetime in the240local time zone (\fIYYYY-MM-DD\fR or \fIYYYY-MM-DD HH:MM:SS\fR).241.B --change-older-than242can be used as an alias.243244Examples:
143 unmodified lines
modified:src/filter/time.rs+54 added-3 removed
1use chrono::{offset::TimeZone, DateTime, Local, NaiveDate};23use std::time::SystemTime;45/// Filter based on time ranges.6#[derive(Debug, PartialEq)]
5 unmodified lines
12impl TimeFilter {13 fn from_str(ref_time: &SystemTime, s: &str) -> Option<SystemTime> {14 humantime::parse_duration(s)15 .map(|duration| *ref_time - duration)14 .or_else(|_| humantime::parse_rfc3339_weak(s))15 .or_else(|_| humantime::parse_rfc3339_weak(&(s.to_owned() + " 00:00:00")))16 .ok()17 .or_else(|| {18 DateTime::parse_from_rfc3339(s)19 .map(|dt| dt.into())20 .ok()21 .or_else(|| {22 NaiveDate::parse_from_str(s, "%F")23 .map(|nd| nd.and_hms(0, 0, 0))24 .ok()25 .and_then(|ndt| Local.from_local_datetime(&ndt).single())26 })27 .or_else(|| Local.datetime_from_str(s, "%F %T").ok())28 .map(|dt| dt.into())29 })30 }3132 pub fn before(ref_time: &SystemTime, s: &str) -> Option<TimeFilter> {33 TimeFilter::from_str(ref_time, s).map(TimeFilter::Before)
17 unmodified lines
51 use std::time::Duration;5253 #[test]54 fn is_time_filter_applicable() {42 let ref_time = humantime::parse_rfc3339("2010-10-10T10:10:10Z").unwrap();55 let ref_time = Local56 .datetime_from_str("2010-10-10 10:10:10", "%F %T")57 .unwrap()58 .into();5960 assert!(TimeFilter::after(&ref_time, "1min")61 .unwrap()62 .applies_to(&ref_time));63 assert!(!TimeFilter::before(&ref_time, "1min")
28 unmodified lines
92 .applies_to(&ref_time));93 assert!(!TimeFilter::after(&ref_time, t10s_before)94 .unwrap()95 .applies_to(&t1m_ago));9697 let same_day = "2010-10-10";98 assert!(!TimeFilter::before(&ref_time, same_day)99 .unwrap()100 .applies_to(&ref_time));101 assert!(!TimeFilter::before(&ref_time, same_day)102 .unwrap()103 .applies_to(&t1m_ago));104105 assert!(TimeFilter::after(&ref_time, same_day)106 .unwrap()107 .applies_to(&ref_time));108 assert!(TimeFilter::after(&ref_time, same_day)109 .unwrap()110 .applies_to(&t1m_ago));111112 let ref_time = DateTime::parse_from_rfc3339("2010-10-10T10:10:10+00:00")113 .unwrap()114 .into();115 let t1m_ago = ref_time - Duration::from_secs(60);116 let t10s_before = "2010-10-10T10:10:00+00:00";117 assert!(!TimeFilter::before(&ref_time, t10s_before)118 .unwrap()119 .applies_to(&ref_time));120 assert!(TimeFilter::before(&ref_time, t10s_before)121 .unwrap()122 .applies_to(&t1m_ago));123124 assert!(TimeFilter::after(&ref_time, t10s_before)125 .unwrap()126 .applies_to(&ref_time));127 assert!(!TimeFilter::after(&ref_time, t10s_before)128 .unwrap()129 .applies_to(&t1m_ago));130 }131}
modified:src/filetypes.rs+28 added
1use crate::filesystem;2use crate::walk;34/// Whether or not to show5pub struct FileTypes {6 pub files: bool,7 pub directories: bool,
16 unmodified lines
24 empty_only: false,25 }26 }27}2829impl FileTypes {30 pub fn should_ignore(&self, entry: &walk::DirEntry) -> bool {31 if let Some(ref entry_type) = entry.file_type() {32 (!self.files && entry_type.is_file())33 || (!self.directories && entry_type.is_dir())34 || (!self.symlinks && entry_type.is_symlink())35 || (!self.sockets && filesystem::is_socket(*entry_type))36 || (!self.pipes && filesystem::is_pipe(*entry_type))37 || (self.executables_only38 && !entry39 .metadata()40 .map(|m| filesystem::is_executable(&m))41 .unwrap_or(false))42 || (self.empty_only && !filesystem::is_empty(&entry))43 || !(entry_type.is_file()44 || entry_type.is_dir()45 || entry_type.is_symlink()46 || filesystem::is_socket(*entry_type)47 || filesystem::is_pipe(*entry_type))48 } else {49 true50 }51 }52}
modified:src/main.rs+5 added-3 removed
208 unmodified lines
209 let color_arg = ["--color=", color].concat();210211 #[allow(unused)]212 let gnu_ls = |command_name| {213 // Note: we use short options here (instead of --long-options) to support more214 // platforms (like BusyBox).215 vec![216 command_name,215 "-l", // long listing format216 "--human-readable", // human readable file sizes217 "--directory", // list directories themselves, not their contents217 "-l", // long listing format218 "-h", // human readable file sizes219 "-d", // list directories themselves, not their contents220 &color_arg,221 ]222 };223
274 unmodified lines
modified:src/walk.rs+9 added-35 removed
356 unmodified lines
357 {358 DirEntry::BrokenSymlink(path)359 }360 _ => {361 match tx_thread.send(WorkerResult::Error(ignore::Error::WithPath {361 return match tx_thread.send(WorkerResult::Error(ignore::Error::WithPath {362 path,363 err: inner_err,364 })) {365 Ok(_) => {366 return ignore::WalkState::Continue;367 }368 Err(_) => {369 return ignore::WalkState::Quit;370 }365 Ok(_) => ignore::WalkState::Continue,366 Err(_) => ignore::WalkState::Quit,367 }368 }369 },374 Err(err) => match tx_thread.send(WorkerResult::Error(err)) {375 Ok(_) => {376 return ignore::WalkState::Continue;370 Err(err) => {371 return match tx_thread.send(WorkerResult::Error(err)) {372 Ok(_) => ignore::WalkState::Continue,373 Err(_) => ignore::WalkState::Quit,374 }378 Err(_) => {379 return ignore::WalkState::Quit;380 }375 }381 },376 };377378 if let Some(min_depth) = config.min_depth {379 if entry.depth().map_or(true, |d| d < min_depth) {
35 unmodified lines
415 }416417 // Filter out unwanted file types.418 if let Some(ref file_types) = config.file_types {425 if let Some(ref entry_type) = entry.file_type() {426 if (!file_types.files && entry_type.is_file())427 || (!file_types.directories && entry_type.is_dir())428 || (!file_types.symlinks && entry_type.is_symlink())429 || (!file_types.sockets && filesystem::is_socket(*entry_type))430 || (!file_types.pipes && filesystem::is_pipe(*entry_type))431 || (file_types.executables_only432 && !entry433 .metadata()434 .map(|m| filesystem::is_executable(&m))435 .unwrap_or(false))436 || (file_types.empty_only && !filesystem::is_empty(&entry))437 || !(entry_type.is_file()438 || entry_type.is_dir()439 || entry_type.is_symlink()440 || filesystem::is_socket(*entry_type)441 || filesystem::is_pipe(*entry_type))442 {443 return ignore::WalkState::Continue;444 }445 } else {419 if file_types.should_ignore(&entry) {420 return ignore::WalkState::Continue;421 }422 }423
64 unmodified lines
modified:Cargo.lock+102 added-56 removed
58 unmodified lines
59checksum = "cf1de2fe8c75bc145a2f577add951f8134889b4795d47466a54a5c846d691693"6061[[package]]62name = "bstr"63version = "0.2.14"63version = "0.2.16"64source = "registry+https://github.com/rust-lang/crates.io-index"65checksum = "473fc6b38233f9af7baa94fb5852dca389e3d95b8e21c8e3719301462c5d9faf"65checksum = "90682c8d613ad3373e66de8c6411e0ae2ab2571e879d2efbf73558cc66f21279"66dependencies = [67 "memchr",68]6970[[package]]71name = "cc"72version = "1.0.66"72version = "1.0.69"73source = "registry+https://github.com/rust-lang/crates.io-index"74checksum = "4c0496836a84f8d0495758516b8621a622beb77c0fed418570e50764093ced48"74checksum = "e70cc2f62c6ce1868963827bd677764c62d07c3d9a3e1fb1177ee1a9ab199eb2"7576[[package]]77name = "cfg-if"78version = "0.1.10"78version = "1.0.0"79source = "registry+https://github.com/rust-lang/crates.io-index"80checksum = "4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822"80checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"8182[[package]]83name = "cfg-if"84version = "1.0.0"83name = "chrono"84version = "0.4.19"85source = "registry+https://github.com/rust-lang/crates.io-index"86checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"86checksum = "670ad68c9088c2a963aaa298cb369688cf3f9465ce5e2d4ca10e6e0098a1ce73"87dependencies = [88 "libc",89 "num-integer",90 "num-traits",91 "time",92 "winapi",93]9495[[package]]96name = "clap"97version = "2.33.3"
11 unmodified lines
109]110111[[package]]112name = "crossbeam-utils"106version = "0.8.1"113version = "0.8.5"114source = "registry+https://github.com/rust-lang/crates.io-index"108checksum = "02d96d1e189ef58269ebe5b97953da3274d83a93af647c2ddd6f9dab28cedb8d"115checksum = "d82cfc11ce7f2c3faef78d8a684447b40d503d9681acebed6cb728d45940c4db"116dependencies = [110 "autocfg",111 "cfg-if 1.0.0",117 "cfg-if",118 "lazy_static",119]120121[[package]]122name = "ctrlc"117version = "3.1.9"123version = "3.2.0"124source = "registry+https://github.com/rust-lang/crates.io-index"119checksum = "232295399409a8b7ae41276757b5a1cc21032848d42bff2352261f958b3ca29a"125checksum = "377c9b002a72a0b2c1a18c62e2f3864bdfea4a015e3683a96e24aa45dd6c02d1"126dependencies = [127 "nix",128 "winapi",129]
9 unmodified lines
139version = "2.0.0"140source = "registry+https://github.com/rust-lang/crates.io-index"141checksum = "b98cf8ebf19c3d1b223e151f99a4f9f0690dca41414773390fc824184ac833e1"142dependencies = [137 "cfg-if 1.0.0",143 "cfg-if",144 "dirs-sys-next",145]146147[[package]]148name = "dirs-sys-next"143version = "0.1.1"149version = "0.1.2"150source = "registry+https://github.com/rust-lang/crates.io-index"145checksum = "99de365f605554ae33f115102a02057d4fc18b01f3284d6870be0938743cfe7d"151checksum = "4ebda144c4fe02d1f7ea1a7d9641b6fc6b580adcfa024ae48797ecdeb6825b4d"152dependencies = [153 "libc",154 "redox_users",155 "winapi",
5 unmodified lines
161dependencies = [162 "ansi_term 0.12.1",163 "anyhow",164 "atty",165 "chrono",166 "clap",167 "ctrlc",168 "diff",169 "dirs-next",
16 unmodified lines
186]187188[[package]]189name = "filetime"183version = "0.2.14"190version = "0.2.15"191source = "registry+https://github.com/rust-lang/crates.io-index"185checksum = "1d34cfa13a63ae058bfa601fe9e313bbdb3746427c1459185464ce0fcf62e1e8"192checksum = "975ccf83d8d9d0d84682850a38c8169027be83368805971cc4f238c2b245bc98"193dependencies = [187 "cfg-if 1.0.0",194 "cfg-if",195 "libc",189 "redox_syscall 0.2.10",196 "redox_syscall",197 "winapi",198]199200[[package]]
15 unmodified lines
216checksum = "a06f77d526c1a601b7c4cdd98f54b5eaabffc14d5f2f0296febdc7f357c6d3ba"217218[[package]]219name = "getrandom"213version = "0.1.15"220version = "0.2.3"221source = "registry+https://github.com/rust-lang/crates.io-index"215checksum = "fc587bc0ec293155d5bfa6b9891ec18a1e330c234f896ea47fbada4cadbe47e6"222checksum = "7fcd999463524c52659517fe2cea98493cfe485d10565e7b0fb07dbba7ad2753"223dependencies = [217 "cfg-if 0.1.10",224 "cfg-if",225 "libc",226 "wasi",227]228
11 unmodified lines
240]241242[[package]]243name = "hermit-abi"237version = "0.1.17"244version = "0.1.19"245source = "registry+https://github.com/rust-lang/crates.io-index"239checksum = "5aca5565f760fb5b220e499d72710ed156fdb74e631659e99377d9ebfbd13ae8"246checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33"247dependencies = [248 "libc",249]250251[[package]]252name = "humantime"246version = "2.0.1"253version = "2.1.0"254source = "registry+https://github.com/rust-lang/crates.io-index"248checksum = "3c1ad908cc71012b7bea4d0c53ba96a8cba9962f048fa68d143376143d863b7a"255checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4"256257[[package]]258name = "ignore"252version = "0.4.17"259version = "0.4.18"260source = "registry+https://github.com/rust-lang/crates.io-index"254checksum = "b287fb45c60bb826a0dc68ff08742b9d88a2fea13d6e0c286b3172065aaf878c"261checksum = "713f1b139373f96a2e0ce3ac931cd01ee973c3c5dd7c40c0c2efe96ad2b6751d"262dependencies = [263 "crossbeam-utils",264 "globset",265 "lazy_static",
34 unmodified lines
300checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646"301302[[package]]303name = "libc"297version = "0.2.98"304version = "0.2.99"305source = "registry+https://github.com/rust-lang/crates.io-index"299checksum = "320cfe77175da3a483efed4bc0adc1968ca050b098ce4f2f1c13a56626128790"306checksum = "a7f823d141fe0a24df1e23b4af4e3c7ba9e5966ec514ea068c93024aa7deb765"307308[[package]]309name = "log"303version = "0.4.11"310version = "0.4.14"311source = "registry+https://github.com/rust-lang/crates.io-index"305checksum = "4fabed175da42fed1fa0746b0ea71f412aa9d35e76e95e59b192c64b9dc2bf8b"312checksum = "51b9bbe6c47d51fc3e1a9b945965946b4c44142ab8792c50835a980d362c2710"313dependencies = [307 "cfg-if 0.1.10",314 "cfg-if",315]316317[[package]]318name = "lscolors"
10 unmodified lines
329source = "registry+https://github.com/rust-lang/crates.io-index"330checksum = "b16bd47d9e329435e309c58469fe0791c2d0d1ba96ec0954152a5ae2b04387dc"331332[[package]]333name = "memoffset"334version = "0.6.4"335source = "registry+https://github.com/rust-lang/crates.io-index"336checksum = "59accc507f1338036a0477ef61afdae33cde60840f4dfe481319ce3ad116ddf9"337dependencies = [338 "autocfg",339]340341[[package]]342name = "nix"327version = "0.20.0"343version = "0.22.0"344source = "registry+https://github.com/rust-lang/crates.io-index"329checksum = "fa9b4819da1bc61c0ea48b63b7bc8604064dd43013e7cc325df098d49cd7c18a"345checksum = "cf1e25ee6b412c2a1e3fcb6a4499a5c1bfe7f43e014bdce9a6b6666e5aa2d187"346dependencies = [347 "bitflags",348 "cc",333 "cfg-if 1.0.0",349 "cfg-if",350 "libc",351 "memoffset",352]353354[[package]]355name = "normpath"
4 unmodified lines
360 "winapi",361]362363[[package]]364name = "num-integer"365version = "0.1.44"366source = "registry+https://github.com/rust-lang/crates.io-index"367checksum = "d2cc698a63b549a70bc047073d2949cce27cd1c7b0a4a862d08a8031bc2801db"368dependencies = [369 "autocfg",370 "num-traits",371]372373[[package]]374name = "num-traits"375version = "0.2.14"376source = "registry+https://github.com/rust-lang/crates.io-index"377checksum = "9a64b1ec5cda2586e284722486d802acf1f7dbdc623e2bfc57e65ca1cd099290"378dependencies = [379 "autocfg",380]381382[[package]]383name = "num_cpus"384version = "1.13.0"385source = "registry+https://github.com/rust-lang/crates.io-index"386checksum = "05499f3756671c15885fee9034446956fff3f243d6077b91e5767df161f766b3"
2 unmodified lines
389 "libc",390]391392[[package]]393name = "once_cell"394version = "1.8.0"395source = "registry+https://github.com/rust-lang/crates.io-index"396checksum = "692fcb63b64b1758029e0a96ee63e049ce8c5948587f2f7208df04625e5f6b56"397398[[package]]399name = "proc-macro2"400version = "1.0.28"401source = "registry+https://github.com/rust-lang/crates.io-index"402checksum = "5c7ed8b8c7b886ea3ed7dde405212185f423ab44682667c8c6dd14aa1d9f6612"
48 unmodified lines
451]452453[[package]]454name = "redox_syscall"413version = "0.1.57"414source = "registry+https://github.com/rust-lang/crates.io-index"415checksum = "41cc0f7e4d5d4544e8861606a285bb08d3e70712ccc7d2b84d7c0ccfaf4b05ce"416417[[package]]418name = "redox_syscall"455version = "0.2.10"456source = "registry+https://github.com/rust-lang/crates.io-index"457checksum = "8383f39639269cde97d255a32bdb68c047337295414940c68bdd30c2e13203ff"458dependencies = [
1 unmodified line
460]461462[[package]]463name = "redox_users"428version = "0.3.5"464version = "0.4.0"465source = "registry+https://github.com/rust-lang/crates.io-index"430checksum = "de0737333e7a9502c789a36d7c7fa6092a49895d4faa31ca5df163857ded2e9d"466checksum = "528532f3d801c87aec9def2add9ca802fe569e44a544afe633765267840abe64"467dependencies = [468 "getrandom",433 "redox_syscall 0.1.57",469 "redox_syscall",470]471472[[package]]473name = "regex"
72 unmodified lines
546version = "1.2.0"547source = "registry+https://github.com/rust-lang/crates.io-index"548checksum = "3b114ece25254e97bf48dd4bfc2a12bad0647adacfe4cae1247a9ca6ad302cec"549dependencies = [514 "cfg-if 1.0.0",550 "cfg-if",551 "proc-macro2",552 "quote",553 "syn",554 "version_check",
10 unmodified lines
565]566567[[package]]568name = "thread_local"533version = "1.0.1"569version = "1.1.3"570source = "registry+https://github.com/rust-lang/crates.io-index"535checksum = "d40c6d1b69745a6ec6fb1ca717914848da4b44ae29d9b3080cbee91d72a69b14"571checksum = "8018d24e04c95ac8790716a5987d0fec4f8b27249ffa0f7d33f1369bdfb88cbd"572dependencies = [537 "lazy_static",573 "once_cell",574]575576[[package]]577name = "time"578version = "0.1.43"579source = "registry+https://github.com/rust-lang/crates.io-index"580checksum = "ca8a50ef2360fbd1eeb0ecd46795a87a19024eb4b53c5dc916ca1fd95fe62438"581dependencies = [582 "libc",583 "winapi",584]585586[[package]]587name = "unicode-width"588version = "0.1.8"589source = "registry+https://github.com/rust-lang/crates.io-index"590checksum = "9337591893a19b88d8d87f2cec1e73fad5cdfd10e5a6f349f498ad6ea2ffb1e3"
27 unmodified lines
618checksum = "5fecdca9a5291cc2b8dcf7dc02453fee791a280f3743cb0905f8822ae463b3fe"619620[[package]]621name = "walkdir"576version = "2.3.1"622version = "2.3.2"623source = "registry+https://github.com/rust-lang/crates.io-index"578checksum = "777182bc735b6424e1a57516d35ed72cb8019d85c8c9bf536dccb3445c1a2f7d"624checksum = "808cf2735cd4b6866113f648b791c6adc5714537bc222d9347bb203386ffda56"625dependencies = [626 "same-file",627 "winapi",628 "winapi-util",629]630631[[package]]632name = "wasi"587version = "0.9.0+wasi-snapshot-preview1"633version = "0.10.2+wasi-snapshot-preview1"634source = "registry+https://github.com/rust-lang/crates.io-index"589checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519"635checksum = "fd6fbd9a79829dd1ad0cc20627bf1ed606756a7f77edff7b66b7064f9cb327c6"636637[[package]]638name = "winapi"639version = "0.3.9"
27 unmodified lines
modified:Cargo.toml+1 added
modified:CHANGELOG.md+2 added
8 unmodified lines
9- Set default path separator to `/` in MSYS, see #537 and #730 (@aswild)10- fd cannot search files under a RAM disk, see #75211- fd doesn't show substituted drive on Windows, see #36512- Properly handle write errors to devices that are full, see #73713- Use local time zone for time functions (`--change-newer-than`, `--change-older-than`), see #631 (@jacobmischka)14- Support `--list-details` on more platforms (like BusyBox), see #7831516## Changes1718- Apply custom `--path-separator` to commands run with `--exec(-batch)` and `--list-details`, see #697 (@aswild)
509 unmodified lines
modified:README.md+21 added
113 unmodified lines
114src/lscolors/mod.rs115tests/testenv/mod.rs116```117118### Searching for a particular file name119120 To find files with exactly the provided search pattern, use the `-g` (or `--glob`) option:121``` bash122> fd -g libc.so /usr123/usr/lib32/libc.so124/usr/lib/libc.so125```126127### Hidden and ignored files128By default, *fd* does not search hidden directories and does not show hidden files in the129search results. To disable this behavior, we can use the `-H` (or `--hidden`) option:130``` bash
13 unmodified lines
144145To really search *all* files and directories, simply combine the hidden and ignore features to show146everything (`-HI`).147148### Matching the full path149By default, *fd* only matches the filename of each file. However, using the `--full-path` or `-p` option,150you can match against the full path.151152```bash153> fd -p -g '**/.git/config'154> fd -p '.*/lesson-\d+/[a-z]+.(jpg|png)'155```156157### Command execution158159Instead of just showing the search results, you often want to *do something* with them. `fd`160provides two ways to execute external commands for each of your search results:
479 unmodified lines
640cargo install fd-find641```642Note that rust version *1.42.0* or later is required.643644`make` is also needed for the build.645646### From binaries647648The [release page](https://github.com/sharkdp/fd/releases) includes precompiled binaries for Linux, macOS and Windows. Statically-linked binaries are also available: look for archives with `musl` in the file name.649
16 unmodified lines
666667- [sharkdp](https://github.com/sharkdp)668- [tmccombs](https://github.com/tmccombs)669- [tavianator](https://github.com/tavianator)670- [pemistahl](https://github.com/pemistahl/)671672## License673674Copyright (c) 2017-2021 The fd developers
4 unmodified lines