Code Monkey home page Code Monkey logo

regex-searcher-cwg1's Introduction

Simple Searcher

CloudWeGo Day1 Assignment

提示

example_dir用于进行搜索测试。可以自行添加更复杂的结构。

Features实现情况

  • ✅ 重构到多个模块中
  • –v/--verbose 搜索过程与层级显示
  • ✅ 同时⽀持匹配多个正则/给输出结果去重排序
  • ✅ 尝试使⽤ tracing 库打⽇志
  • ✅ 尝试⽀持同时搜索多个 path
  • ✅ 彩⾊输出
  • 其他:
    • -h 查看帮助
    • 输出结果已去重并排序

Try These!

  • 编译release版本并查看帮助:cargo clean && cargo run --release -- -h && cd ./target/release/
  • 查找example_dir下的所有txt文件:regex -p './example_dir' -r '.*\.txt'
  • 查找example_dir下的所有txt文件以及无后缀名,并显示详细搜索过程:regex -p './example_dir' -r '.*\.txt' '[^\.]*' -v
  • 查找example_dir/subdir1example_dir/subdir2下的所有文件:regex -p './example_dir/subdir1' './example_dir/subdir2' -r '.*'
  • 去重测试:regex -p './example_dir/subdir1' -r '.*\.t' '.*\.txt' -v
  • 排序测试:regex -p './example_dir' -r '3' '1' '2' -v

ScreenShotExample

success advanced

regex-searcher-cwg1's People

Contributors

cubicyyy avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.