extract if_index without grep from scutil --dns I'm using the grep command to extract active interfaces from the output of the scutil command with the --dns option.

$ scutil --dns | grep 'if_index'


I am suspecting if a user's machine with different system language (Spanish, Chinese, etc) the text 'if_index' will change and the above mentioned command will not produce the right result. Is my suspicion right? If so could someone tell what is the right way to perform the above operation?
If you look at the executable itself, /usr/sbin/scutil with the strings command you can see that those strings are hardcoded directly into the executable.

$ strings /usr/sbin/scutil | grep 'if_index'
  if_index : %d (%s)


Additionally this CLI's output remains the same when you try changing the LANG=.. or LC_ALL=.. environment variables. For example:

$ LANG="zh_CN.UTF-8" scutil --dns | grep 'if_index'
  if_index : 10 (en0)

$ LC_ALL="zh_CN.UTF-8" scutil --dns | grep 'if_index'
  if_index : 10 (en0)


Doing this with another CLI tool such as git translates the output:

$ LC_ALL="zh_CN.UTF-8" git --help
用法：git [--version] [--help] [-C &lt;路径&gt;] [-c &lt;名称&gt;=&lt;取值&gt;]
           [--exec-path[=&lt;路径&gt;]] [--html-path] [--man-path] [--info-path]
           [-p | --paginate | -P | --no-pager] [--no-replace-objects] [--bare]
           [--git-dir=&lt;路径&gt;] [--work-tree=&lt;路径&gt;] [--namespace=&lt;名称&gt;]
           &lt;命令&gt; [&lt;参数&gt;]

这些是各种场合常见的 Git 命令：

开始一个工作区（参见：git help tutorial）
   clone      克隆一个仓库到一个新目录
   init       创建一个空的 Git 仓库或重新初始化一个已存在的仓库


All this leads me to believe that the output will not change.