4 ms·
Just an anecdote that probably says more about me than about the internet: Recently I had work on a shell script that used "sed" to make changes in config file
by aerique 14y ago
Just an anecdote that probably says more about me than about the internet:
Recently I had work on a shell script that used "sed" to make changes in config files. At some point a change only had to happen once a line with a certain string had been seen, so I googled for this situation.
Multiple StackOverflow answers were at the the top of the results as well a several other sites all of them containing incomprehesible examples of line noise. Half the time, the comments on the pages with the aformentioned examples also indicated the solutions didn't work.
So I did a "man sed" looking for examples but it was a pretty short man page which told me to peruse "info sed". Not expecting much I fired up info (which I generally try to avoid: just put your docs in the man page) and to my surprise there was very good and clear documentation on sed which got me to fix my initial problem in 5 minutes in a clear way (well, it did need a comment in the code).
The next time I need to know anything about sed I will check the manual first.
- johncoltrane 14y agoRTFM is always the first thing to do. It's not always sufficient but it often is.