Comment on Merging two ini/env keyval files and remove duplicate keys using awkComments−mattkenefickOP7yI ran into this issue today and couldn't find a great solution online.Needed to combine multiple key/value files, like .ini or .env, and have some values override others while removing duplicates.This script + example demonstrates how to use awk to remove duplicate lines based on their key.
Comments
I ran into this issue today and couldn't find a great solution online.
Needed to combine multiple key/value files, like .ini or .env, and have some values override others while removing duplicates.
This script + example demonstrates how to use awk to remove duplicate lines based on their key.