Skip to content

Instantly share code, notes, and snippets.

@jldevezas
Last active December 11, 2015 17:38
Show Gist options
  • Save jldevezas/4635559 to your computer and use it in GitHub Desktop.
Save jldevezas/4635559 to your computer and use it in GitHub Desktop.
#!/bin/sh
find project/ -name '*.cs' -or -name '*.js' | \
awk '{ \
cmd = "wc -l "$0; \
cmd | getline res; \
split(res, n, " "); \
print n[1]; \
close(cmd) \
}' | paste -s -d'+' - | bc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment