[Mac OS X] 如何在终端查看 Mac OS 版本信息
来源:互联网 发布:游戏视频录制软件 编辑:程序博客网 时间:2024/05/16 04:52
本文转载至:https://www.cyberciti.biz/faq/mac-osx-find-tell-operating-system-version-from-bash-prompt/
use ssh client to login into my Mac Min server without GUI. How can I tell what version of Mac OS X operating system am I using command prompt? How do I find out Mac OS X version from Terminal app bash shell?
On Apple Mac OS X you need to use the following command to find out operating system version:
- system_profiler command – Show Apple hardware and software configuration.
- sw_vers command – Show Mac OS X operating system version.
- uname command – Show operating system name and more.
Determine OS X version from the command line
Open the terminal app and type the following command:$ sw_vers
Sample outputs:
Where, you can pass the following options:
- -productName – Print just the value of the ProductName property.
- -productVersion – Print just the value of the ProductVersion property.
- -buildVersion – Print just the value of the BuildVersion property.
Say hello to system_profiler
You can use the system_profiler command as follows to get the same information:$ system_profiler | less
$ system_profiler SPSoftwareDataType
Sample outputs:
Using SystemVersion.plist file
The above commands use /System/Library/CoreServices/SystemVersion.plist file. One can print the version info as follows:$ cat /System/Library/CoreServices/SystemVersion.plist
Sample outputs:
On Mac OS X server, try:$ cat /System/Library/CoreServices/ServerVersion.plist
How do I find out OS X Darwin kernel version?
Simply type the following uname command to see operating system name including the machine hardware name, the nodename, the machine processor architecture name, the operating system release, the operating system name, and the operating system version:$ uname -av
Sample outputs:
Darwin Viveks-MacBook-Pro.local 15.0.0 Darwin Kernel Version 15.0.0: Sat Sep 19 15:53:46 PDT 2015; root:xnu-3247.10.11~1/RELEASE_X86_64 x86_64
Tip: Read OS X version in audio format
Type the following bash command to hear OS X version using the say command on OS X:
- [Mac OS X] 如何在终端查看 Mac OS 版本信息
- MAC OS X终端
- Mac OS X 命令查看系统版本信息
- Mac OS X下查看CPU信息
- Mac OS X 如何查看隐藏文件
- MAC OS X终端常用命令
- MAC OS X终端常用命令
- Mac OS X终端命令
- Mac OS X版本历史
- mac os x 如何打开多个终端
- 在Mac OS X下使用终端显示隐藏文件
- 在 Mac OS X 终端里使用 Solarized 配色方案
- 在 Mac OS X 终端里使用 Solarized 配色方案
- 在 Mac OS X 终端里使用 Solarized 配色方案
- 在 Mac OS X 终端里使用 Solarized 配色方案
- 在 Mac OS X 终端里使用 Solarized 配色方案
- 在 Mac OS X 终端里使用 Solarized 配色方案
- 在 Mac OS X 终端里使用 Solarized 配色方案
- 【jzoj4919】【神炎皇】【数论】
- [Java面试十二]数据库概念相关
- 字符串方法总结
- 兄弟连HTML5——09.canvas实例2——太阳系2.html
- 文件综合应用-配置文件的读写修改
- [Mac OS X] 如何在终端查看 Mac OS 版本信息
- C++中RTTI与dynamic_cast
- [Java面试三]JavaWeb基础知识总结.
- JavaScript childNodes attributes
- POJ 1511 Invitation Cards-2016.12月计科院赛(最短路)
- jvm调优+jstat
- Android Studio项目怎么导入Coding上创建的版本库
- 一个被弃用输出PDF,预览DOC格式的方法
- 文章标题 CSU 1756 :Prime