Added Bad Lines Remover in foundrycleaner.sh
- set so Auto does line removal - set so auto does line combining (often needed for when the 100th result is on the next line)
This commit is contained in:
parent
3e2bf5fe1b
commit
27d1be4016
1 changed files with 19 additions and 2 deletions
|
|
@ -51,10 +51,20 @@ lineCombiner(){
|
|||
' "$tempfile" > "$OUTPUT_FILE"
|
||||
}
|
||||
|
||||
badLineRemover() {
|
||||
grep -Ev "[0-9] {1,}" "$tempfile" > "$OUTPUT_FILE"
|
||||
}
|
||||
|
||||
outToTemp() {
|
||||
cp "$OUTPUT_FILE" "$tempfile"
|
||||
}
|
||||
|
||||
|
||||
|
||||
### RUNTIME ###
|
||||
|
||||
cp "$INPUT_FILE" "$tempfile"
|
||||
touch $tempfile
|
||||
|
||||
case $1 in
|
||||
dice)
|
||||
|
|
@ -72,11 +82,18 @@ case $1 in
|
|||
lines)
|
||||
lineCombiner
|
||||
;;
|
||||
badlinesrm)
|
||||
badLineRemover
|
||||
;;
|
||||
auto)
|
||||
lineCombiner
|
||||
outToTemp
|
||||
badLineRemover
|
||||
outToTemp
|
||||
ListSort
|
||||
cp "$OUTPUT_FILE" "$tempfile"
|
||||
outToTemp
|
||||
RemoveNumbers
|
||||
cp "$OUTPUT_FILE" "$tempfile"
|
||||
outToTemp
|
||||
dice
|
||||
;;
|
||||
*)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue