Mercurial > ~dholland > hg > ag > index.cgi
comparison ibmscripts/cc @ 24:a4899cdfc2d6 default tip
Obfuscate the regexps to strip off the IBM compiler's copyright banners.
I don't want bots scanning github to think they're real copyright
notices because that could cause real problems.
author | David A. Holland |
---|---|
date | Mon, 13 Jun 2022 00:40:23 -0400 |
parents | 13d2b8934445 |
children |
comparison
equal
deleted
inserted
replaced
23:cac4c76600eb | 24:a4899cdfc2d6 |
---|---|
91 /J- /Gl /Gm /Gu+ $DEFS $WARN $OPT $SHLIB \ | 91 /J- /Gl /Gm /Gu+ $DEFS $WARN $OPT $SHLIB \ |
92 /C "$FILE" | 92 /C "$FILE" |
93 echo "@@@Exit $?" | 93 echo "@@@Exit $?" |
94 ) 2>&1 | tr -d '\r' | tee "$LOG" | ( | 94 ) 2>&1 | tr -d '\r' | tee "$LOG" | ( |
95 if [ $QUIET = 1 ]; then | 95 if [ $QUIET = 1 ]; then |
96 # | |
97 # The compiler prints its copyright banner every time you run | |
98 # it, that is, on every file, and there's apparently no way to | |
99 # fully suppress this. So, since this is extremely annoying and | |
100 # interferes with development, delete the strings from the | |
101 # output. Obfuscate the regexps slightly, because I want them | |
102 # to be precise (no other messages should be suppressed) but I | |
103 # also don't want to be harassed by source-scanning bots or | |
104 # (perhaps) clueless lawyers that think they're actual IBM | |
105 # copyright notices. I wrote this script; it's not IBM's. | |
106 # | |
96 sed ' | 107 sed ' |
97 /^IBM(R) VisualAge(TM) for C++ for Windows(R), Version 3\.5$/d | 108 /^[I][B][M](.) VisualAge(..) for C++ for Windows(.), Version 3\.5$/d |
98 /^- Licensed Materials - Program-Property of IBM$/d | 109 /^- [L]icensed [M]aterials - Program-[P]roperty of [I][B][M]$/d |
99 /^(C) Copyright IBM Corp. 1991, 1996 - All Rights Reserved.$/d | 110 /^(.) [C]opyright [I][B][M] [C]orp. 1991, 1996 - [A]ll [R]ights [R]eserved.$/d |
100 ' | 111 ' |
101 else | 112 else |
102 cat | 113 cat |
103 fi | 114 fi |
104 ) | awk ' | 115 ) | awk ' |