tldr/pages/osx/networksetup.md

20 lines
530 B
Markdown
Raw Normal View History

# networksetup
> Configuration tool for Network System Preferences
- List available network service providers (Ethernet, Wi-Fi, Bluetooth, etc)
`networksetup -listallnetworkservices`
- Show network settings for a particular networking device
`networksetup -getinfo {{"Wi-Fi"}}`
- Get currently connected Wi-Fi network name (Wi-Fi device usually en0 or en1)
`networksetup -getairportnetwork {{en0}}`
- Connect to a particular Wi-Fi network
2014-02-17 16:15:03 +00:00
`networksetup -setairportnetwork {{en0}} {{"Airport Network SSID"}} {{password}}`