Created
May 28, 2024 20:05
-
-
Save obfusk/51a84655edc2aa0925a72cc7df51ed30 to your computer and use it in GitHub Desktop.
perl command to decrement numbers in a file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
perl -pi -e 's/\b(\d+)\b/$1 - 1/e' file-with-numbers |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment