Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- cfg_vars=(
- '/etc/resolv.conf'
- '/etc/network/interfaces'
- '/etc/wpa_supplicant/wpa_supplicant-wlan0.conf'
- '/etc/systemd/network/00-wireless-dhcp.network'
- '/etc/systemd/system/network-wireless@.service'
- '/etc/wpa_supplicant/kill_wpa.sh'
- '/etc/nsswitch.conf'
- '/etc/sysctl.conf'
- )
- # Print File List
- printf "FILE LIST:\n"
- let pt=0
- while [ -n ""${cfg_vars[$pt]} ]
- do
- printf '\t%s\n' "${cfg_vars[$pt]}"
- let pt=$pt+1
- done
- printf '(end)\n\n'
- printf "FILE CONTENTS:\n\n"
- let pt=0
- while [ -n ""${cfg_vars[$pt]} ]
- do
- echo "## START FILE: "${cfg_vars[$pt]}
- printf '\n'
- cat ${cfg_vars[$pt]}
- echo "## END FILE: "${cfg_vars[$pt]}
- printf '\n\n'
- let pt=$pt+1
- done
- printf '(end)\n\n'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement