Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple PATH arguments, truncation fix, fmt, clippy #92

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Commits on Feb 6, 2024

  1. Run cargo fmt

    totph committed Feb 6, 2024
    Configuration menu
    Copy the full SHA
    05d3316 View commit details
    Browse the repository at this point in the history
  2. Fix clippy warnings and a typo

    totph committed Feb 6, 2024
    Configuration menu
    Copy the full SHA
    92d02a0 View commit details
    Browse the repository at this point in the history
  3. Fix alignment of -h/--help output

    Mostly caused by &str = "\NL .." removing the newline and any leading white
    space on the following line.
    
    ```diff
    @@ -16,1 -16,1 @@
    -weggli 0.2.4
    + weggli 0.2.4
      Felix Wilhelm <[email protected]>
      ARGS:
    -     <PATTERN>    Search pattern.
    +    <PATTERN>    Search pattern.
         <PATH>       A file or directory to search.
     [..]
      OPTIONS:
    -     -A, --after <after>                 Lines to print after a match. Default = 5.
    +    -A, --after <after>                 Lines to print after a match. Default = 5.
         -B, --before <before>               Lines to print before a match. Default = 5.
     [..]
                 not:     Negative sub queries. [..]
    -           strict:   Enable stricter matching.
    +            strict:  Enable stricter matching.
     [..]
    ```
    
    and fix indentation of longer paragraphs and trailine white space.
    totph committed Feb 6, 2024
    Configuration menu
    Copy the full SHA
    b2350f1 View commit details
    Browse the repository at this point in the history
  4. Accept multiple PATH arguments

    Reading from stdin / '-' can be one of them.
    
    Plus when searching in '.' avoid the middle dot like
    '/path/./src/foo.c' when converting to an absolute path.
    
    Update README.md with new --help output and fix trailing whitespace.
    totph committed Feb 6, 2024
    Configuration menu
    Copy the full SHA
    89f41a4 View commit details
    Browse the repository at this point in the history
  5. Fix result truncation being off by one

    The final '}' in a block was truncated when no line numbers were used.
    totph committed Feb 6, 2024
    Configuration menu
    Copy the full SHA
    a1df1cd View commit details
    Browse the repository at this point in the history