Comments on: 10 Interesting Linux Command Line Tricks and Tips Worth Knowing https://www.tecmint.com/linux-command-line-tricks-and-tips-worth-knowing/ Tecmint - Linux Howtos, Tutorials, Guides, News, Tips and Tricks. Thu, 13 Jul 2023 23:25:25 +0000 hourly 1 By: dragonmouth https://www.tecmint.com/linux-command-line-tricks-and-tips-worth-knowing/comment-page-2/#comment-1302094 Thu, 05 Dec 2019 17:43:26 +0000 http://www.tecmint.com/?p=23978#comment-1302094 “The next example renames all files matching "*.bak" to strip the extension, where 's/\e.bak$//' is the rule:” I know this is an old thread but shouldn’t there be screen shots of the output of this command?

]]>
By: Aaron Kili https://www.tecmint.com/linux-command-line-tricks-and-tips-worth-knowing/comment-page-2/#comment-857793 Fri, 06 Jan 2017 16:25:51 +0000 http://www.tecmint.com/?p=23978#comment-857793 In reply to Buchan.

@Buchan

Thanks for the useful insights.

]]>
By: Buchan https://www.tecmint.com/linux-command-line-tricks-and-tips-worth-knowing/comment-page-2/#comment-857655 Thu, 05 Jan 2017 15:39:32 +0000 http://www.tecmint.com/?p=23978#comment-857655 In reply to Ed.

“You should only use su if there is no other option”

What? Really, blanket sudo is worse than su.

What is wrong with:

su -c '> /var/log/uptime.log'

(Hint: nothing)

Regarding the solution in.the article that uses:

$ su 
$ sudo ...

What is the purposeof the ‘sudo’? Again: nothing.

Regarding killing processes using pidof and then kill, it can be more effecrive to use pkill (if you are unfamiliar with pkill, you van use prgrep to see which processes pkill would kill, they take mostly the same optioms).

]]>
By: Aaron Kili https://www.tecmint.com/linux-command-line-tricks-and-tips-worth-knowing/comment-page-2/#comment-857465 Wed, 04 Jan 2017 12:37:45 +0000 http://www.tecmint.com/?p=23978#comment-857465 In reply to Anonymous.

@Anonymous

Works just fine. thanks for the useful suggestion.

]]>
By: Anonymous https://www.tecmint.com/linux-command-line-tricks-and-tips-worth-knowing/comment-page-2/#comment-857440 Wed, 04 Jan 2017 08:13:04 +0000 http://www.tecmint.com/?p=23978#comment-857440 In reply to Ed.

cat /dev/null | sudo tee /var/log/uptime.log

]]>