Small coverage tool (percent of saved config)
This commit is contained in:
parent
c0159583eb
commit
3069437cc2
1 changed files with 10 additions and 0 deletions
10
coverage
Executable file
10
coverage
Executable file
|
@ -0,0 +1,10 @@
|
|||
#!/bin/bash
|
||||
|
||||
DOTFILESINHOME=$(find ~/ -maxdepth 1 -type f -iname '.*rc' | wc -l)
|
||||
DOTFILESINCONF=$(find ~/.config -maxdepth 1 -type d | wc -l)
|
||||
SAVEDDOTFILES=$(ls -d ~/dotfiles | wc -l)
|
||||
|
||||
TOTALDOTFILES=$(echo "$DOTFILESINCONF + $DOTFILESINHOME" | bc -l)
|
||||
PERC=$(echo "scale=2; $SAVEDDOTFILES / $TOTALDOTFILES" | bc -l)
|
||||
echo "Coverage is (roughly) around ${PERC}%"
|
||||
|
Loading…
Reference in a new issue