Skip to content

Instantly share code, notes, and snippets.

@paperlefthand
Last active December 13, 2021 09:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save paperlefthand/23e4f88cced9fd32a0f5649e2d4b6ff8 to your computer and use it in GitHub Desktop.
Save paperlefthand/23e4f88cced9fd32a0f5649e2d4b6ff8 to your computer and use it in GitHub Desktop.
シェル芸
#!/bin/bash
# decompress *.gz files under current directory, and add extension names ".csv" each of them.
for f in `find . -name '*.gz'`;
do
name=${f%.gz};
gzip -d ${name}.gz;
mv ${name} ${name}.csv;
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment