Skip to content

Instantly share code, notes, and snippets.

@zhanglongqi
Created April 20, 2017 01:18
Show Gist options
  • Save zhanglongqi/433db908a8977c046c81f2159c94d75b to your computer and use it in GitHub Desktop.
Save zhanglongqi/433db908a8977c046c81f2159c94d75b to your computer and use it in GitHub Desktop.
calculate the rate of some files in a folder
echo $(( `ls -l brief | grep -e ".*json.old$" | wc -l` / `ls -l brief | wc -l`.0 ))
# 0.71987643734567586
@zhanglongqi
Copy link
Author

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment