Created
February 13, 2020 02:20
-
-
Save dishuostec/a7da9dfc44c9b5db464213752e5a419a to your computer and use it in GitHub Desktop.
split config file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[foo] | |
foo 1 | |
foo 2 | |
[bar] | |
bar 1 | |
bar 2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rm \[*\].conf | |
awk '/^\[(.*)\]$/{x=$0".conf";next}{print > x;}' list.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
will create