Contributing/Modding TW/grep commands
< Contributing | Modding TW
These are a series of grep commands you can use to find out how long your dialogue is, or find lines that are too long, etc. If you aren't familiar with grep, you'll want to set up WSL] and/or Git for Windows (see the Installation Guide).
Line count:
grep -RE "[^\s*;]PRINTFORM......|[^\s*;]PRINT[LW]*[^F_]......|PRINT_DIALOGUE.*|HPH_PRINT.*" . | grep -v \; | grep -v DEBUGPRINT | wc -l
Lines that are too long:
grep -RE "[^\s*;]PRINTFORM......{149,}|[^\s*;]PRINT[LW]*[^F_]......{149,}|PRINT_DIALOGUE.*{149,}|HPH_PRINT.*{149,}" . | grep -Ev "^\;|\\@|NAME_WITH_HONORIFICS|BREAKENG|PRINT_DIALOGUE" | less
Non-speech lines not using PRINTFORMD:
grep -RE "PRINTFORM [^「(]|PRINTFORML [^「(]|PRINTFORMW [^「(]" . | grep -Ev "\;|DEBUGP" | less
Speech lines using PRINTFORMD:
grep -RE "PRINTFORMD [「(]|PRINTFORMDL [「(]|PRINTFORMDW [「(]" . | grep -v "\;|DEBUGP" | less