Change icns in macOS to gray color via bash or other script?
In general, no. Each application is sandboxed, code signed and updated by the Mac App Store update process. Some apps are restricted by system integrity protection. 

In specific yes, you could disable sip if needed. You could disable gatekeeper and modify the app and re-enable gatekeeper. The engineering work to maintain a general script would be days to get a framework done and then hours to days Pre update.