Remove Timestamps From Linux boot logs with Vim

March 23, 2018

This line replaces the values between [  and  ] with white space.

 

:%s/\(\[\).*\(\]\)/\1           \2/g

 

% - find a replace on every line

s - search and replace

\(\[\) - select the first bracket, can then refer to it with \1

.* - all characters

\(\]\) - select the second bracket, can then refer to it with \2

g - replace all instances on a line 

Please reload

Our Recent Posts

DOCSIS 3.1 Series of Specification and Related Specifications

May 25, 2020

Abbreviations, Acronyms from CM-SP-PHYv3.1-I17-190917 and Notes

May 25, 2020

Install a Vim Package on Vim 8 Running on Windows 7

May 3, 2020

1/1
Please reload

Tags

Please reload

©2018 by Zach Pfeffer

SEARCH THIS SITE