diff options
author | Canop <cano.petrole@gmail.com> | 2020-01-20 22:11:38 +0100 |
---|---|---|
committer | Canop <cano.petrole@gmail.com> | 2020-01-20 22:11:38 +0100 |
commit | ec5220711e02c63a4832f984ae788958b3133d18 (patch) | |
tree | 822dacfb3a6c34809291bbd37cac5c958691dc31 /src/git_ignore.rs | |
parent | 7ccda47e5044ec2b56b1b6deb4ecdd82eacae9ff (diff) |
minor code fmt changes
Diffstat (limited to 'src/git_ignore.rs')
-rw-r--r-- | src/git_ignore.rs | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/src/git_ignore.rs b/src/git_ignore.rs index c18e379..cc1b055 100644 --- a/src/git_ignore.rs +++ b/src/git_ignore.rs @@ -3,15 +3,16 @@ //! can apply for a dir (i.e when entering a directory we //! may add a gitignore file to the stack) -use std::{ - fs::File, - io::{BufRead, BufReader, Result}, - path::Path, +use { + glob, + regex::Regex, + std::{ + fs::File, + io::{BufRead, BufReader, Result}, + path::Path, + }, }; -use glob; -use regex::Regex; - /// a simple rule of a gitignore file #[derive(Clone)] struct GitIgnoreRule { @@ -128,7 +129,8 @@ impl GitIgnoreFilter { // we reset the chain: we don't want the .gitignore // files of super repositories // (see https://github.com/Canop/broot/issues/160) - let mut files = if is_git_repo(dir) { // we'll assume it's a .git folder + let mut files = if is_git_repo(dir) { + // we'll assume it's a .git folder debug!("entering a git repo {:?}", dir); self.files.clone() } else { |