I have a csv file in my home directory as below
cat try.csv
val1,val2,val3,val4,val5,val6
10-Jul-19,12604876601113439,Self,abs,Tier-I,30088.5
09-Jul-19,12604876601112397,Self,abs,Tier-I,200590
08-Jul-19,12604876601111807,Self,abs,Tier-I,200590
05-Jul-19,12604876601109069,Self,abs,Tier-I,70206.5
29-May-19,12604876601085648,Self,cdf,Tier-I,70206.5
30-Apr-19,12604876601068094,Self,cdf,Tier-I,130383.5
15-Nov-18,12604876600900949,Self,xyz,Tier-I,71209.46
10-Oct-18,12604876600887501,Self,xyz,Tier-I,79233.06
I can use grep
command to extract the rows having word 'abs':
grep -w 'abs' try.csv
10-Jul-19,12604876601113439,Self,abs,Tier-I,30088.5
09-Jul-19,12604876601112397,Self,abs,Tier-I,200590
08-Jul-19,12604876601111807,Self,abs,Tier-I,200590
05-Jul-19,12604876601109069,Self,abs,Tier-I,70206.5
However I have come across ripgrep
in https://blog.burntsushi.net/ripgrep/ which claims to have similar functionalities of grep
but performs faster (my actual csv file is very big with size 30gb so I need for some faster way than grep
)
So I installed ripgrep
with cargo install ripgrep
and run below code
ripgrep -w 'abs' try.csv
But I got below error
Command 'ripgrep' not found, did you mean:
command 'sipgrep' from deb sipgrep
command 'zipgrep' from deb unzip
Try: apt install <deb name>
Any pointer to use ripgrep in the correct way will be helpful