1

Preface: I've added alias airport="sudo /System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport" to my .zshrc.

myuser:~/ $ airport prefs                                            [17:19:30]
AirPort preferences for en1:

DisconnectOnLogout=NO
JoinMode=Automatic
Unable to retrieve JoinModeFallback
RememberRecentNetworks=YES
RequireAdminIBSS=NO
RequireAdminNetworkChange=NO
RequireAdminPowerToggle=NO
WoWEnabled=YES

myuser:~/ $ airport prefs | grep "JoinMode="                         [17:20:36]
Unable to retrieve JoinModeFallback
JoinMode=Automatic

Why doesn't this grep filter out the JoinModeFallback line?

2

Because pipes only work on stdout by default. That line is an error message being sent to stderr.

  • Oh, I didn't know! I wish I had a good way of highlighting stderr. – 2rs2ts Jun 11 '13 at 0:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.