Created
May 16, 2019 18:44
-
-
Save fredeerock/7e6849a063828fb6277436cffcc33e25 to your computer and use it in GitHub Desktop.
Rename a networkmanager connection without knowing the original connection name.
This file contains 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
#!/bin/bash | |
nmcli -g UUID c show | while read line; do if [ `nmcli -g connection.interface-name c s $line` = $LAN_IFACE ]; then nmcli c mod $line con-name lan-con; fi; done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment