Ken's Lotto Syndicate

Powerball Syndicate Home Page

Site Tools


bash_one-liners

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
bash_one-liners [2025/09/03 00:12] kenbash_one-liners [2026/07/07 23:13] (current) – external edit 127.0.0.1
Line 3: Line 3:
 To remove everything after and including the final '.' use: ''${var%.*}''\\ To remove everything after and including the final '.' use: ''${var%.*}''\\
 To remove the last 4 characters from 'string', use: ''new_string=${string::-4}''\\ To remove the last 4 characters from 'string', use: ''new_string=${string::-4}''\\
 +\\
 +===== sed =====
 +\\
 +Substitute any of listed characters with one command
 +<code>
 +sed s'/[":=]/ /g'
 +</code>
 +Brackets mean "any one of".
 +
bash_one-liners.1756858367.txt.gz · Last modified: (external edit)