diff --git a/bash/src/pman.sh b/bash/src/pman.sh index a6b062e..d4e00ae 100644 --- a/bash/src/pman.sh +++ b/bash/src/pman.sh @@ -33,7 +33,13 @@ Ces lignes ne seront pas incluses dans le fichier destination function _filter_rel() { # enlever les commits "techniques" générés par ce script - grep -vE '' + awk ' +BEGIN { tech = 0 } +tech == 0 && $0 ~ /^\+.*/ { tech = 1; next } +tech == 1 && $0 ~ /^\|/ { next } +tech == 1 && $0 ~ /^\+/ { tech = 0 } +$0 !~ // { print } +' } function _filter_changes() {