From 8697555125c57ae64a0c9b78514b4aac4fd523de Mon Sep 17 00:00:00 2001 From: Mitja Felicijan Date: Tue, 27 Jun 2023 14:50:20 +0200 Subject: Massive formatting and added figcaption --- content/notes/grep-to-less-maintain-colors.md | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'content/notes/grep-to-less-maintain-colors.md') diff --git a/content/notes/grep-to-less-maintain-colors.md b/content/notes/grep-to-less-maintain-colors.md index 9b797ee..6df2761 100644 --- a/content/notes/grep-to-less-maintain-colors.md +++ b/content/notes/grep-to-less-maintain-colors.md @@ -7,16 +7,15 @@ draft: false tags: [bash] --- -I often use `grep` to search for todo's in my code and other people's -code and then pipe them in `less` and I missed having colors that grep -outputs in `less`. +I often use `grep` to search for todo's in my code and other people's code and +then pipe them in `less` and I missed having colors that grep outputs in `less`. - Grep's `--color=always` use markers to highlight the matching strings. - Less's `-R` option outputs "raw" control characters. -You could use `alias grep='grep --color=always'` and `alias less='less --R'` or create todo function in your `.bashrc` that accepts first argument -as search string. +You could use `alias grep='grep --color=always'` and `alias less='less -R'` or +create todo function in your `.bashrc` that accepts first argument as search +string. ```sh # This is where the magic happens. -- cgit v1.2.3