Talk:Console Command Examples

From Free Knowledge Base- The DUCK Project: information for everyone
Revision as of 13:52, 20 July 2024 by Littleguy (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

testing case conversion

for f in *; do temp="${f}_temp"; mv -- "$f" "$temp"; done && for f in *_temp; do mv -- "$f" "${f%_temp}"; done
for f in *; do mv -- "$f" "$(echo "$f" | tr '[:upper:]' '[:lower:]' | sed 's/ /_/g')"; done && for f in *_temp; do mv -- "$f" "${f%_temp}"; done
for f in *; do temp="${f}_temp"; mv -- "$f" "$temp"; done && for f in *_temp; do mv -- "$f" "$(echo "${f%_temp}" | tr '[:upper:]' '[:lower:]')"; done