node全局变量process属性值(mac环境)

任意新建一个js文件,只需一行代码:

console.dir(process);

保存该文件后执行,即可得到process变量的属性值列表:

  1 {
  2     title: ‘node‘,
  3     version: ‘v0.10.30‘,
  4     moduleLoadList: [‘Binding evals‘,
  5         ‘Binding natives‘,
  6         ‘NativeModule events‘,
  7         ‘NativeModule buffer‘,
  8         ‘Binding buffer‘,
  9         ‘NativeModule assert‘,
 10         ‘NativeModule util‘,
 11         ‘NativeModule path‘,
 12         ‘NativeModule module‘,
 13         ‘NativeModule fs‘,
 14         ‘Binding fs‘,
 15         ‘Binding constants‘,
 16         ‘NativeModule stream‘,
 17         ‘NativeModule _stream_readable‘,
 18         ‘NativeModule _stream_writable‘,
 19         ‘NativeModule _stream_duplex‘,
 20         ‘NativeModule _stream_transform‘,
 21         ‘NativeModule _stream_passthrough‘,
 22         ‘NativeModule console‘,
 23         ‘Binding tty_wrap‘,
 24         ‘NativeModule tty‘,
 25         ‘NativeModule net‘,
 26         ‘NativeModule timers‘,
 27         ‘Binding timer_wrap‘,
 28         ‘NativeModule _linklist‘,
 29         ‘Binding cares_wrap‘,
 30         ‘Binding signal_wrap‘
 31     ],
 32     versions: {
 33         http_parser: ‘1.0‘,
 34         node: ‘0.10.30‘,
 35         v8: ‘3.14.5.9‘,
 36         ares: ‘1.9.0-DEV‘,
 37         uv: ‘0.10.28‘,
 38         zlib: ‘1.2.3‘,
 39         modules: ‘11‘,
 40         openssl: ‘1.0.1h‘
 41     },
 42     arch: ‘x64‘,
 43     platform: ‘darwin‘,
 44     argv: [‘node‘, ‘/Users/baidu/github/test/b.js‘],
 45     execArgv: [],
 46     env: {
 47         MANPATH: ‘/Users/baidu/.nvm/v0.10.30/share/man:/Library/Java/JavaVirtualMachines/jdk1.8.0.jdk/Contents/Home/man:/usr/local/share/man:/usr/share/man:/opt/X11/share/man:/Applications/Xcode.app/Contents/Developer/usr/share/man:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/share/man‘,
 48         TERM_PROGRAM: ‘Apple_Terminal‘,
 49         TERM: ‘xterm-256color‘,
 50         SHELL: ‘/bin/bash‘,
 51         TMPDIR: ‘/var/folders/x4/ph44fxq90_99lq3wb24b11sw0000gn/T/‘,
 52         NVM_PATH: ‘/Users/baidu/.nvm/v0.10.30/lib/node‘,
 53         Apple_PubSub_Socket_Render: ‘/private/tmp/com.apple.launchd.OV6WFhpAzS/Render‘,
 54         TERM_PROGRAM_VERSION: ‘343.6‘,
 55         TERM_SESSION_ID: ‘E3666AE1-2E72-484B-978A-8D319AE91FA7‘,
 56         SVN_EDITOR: ‘sub‘,
 57         NVM_DIR: ‘/Users/baidu/.nvm‘,
 58         USER: ‘baidu‘,
 59         SSH_AUTH_SOCK: ‘/private/tmp/com.apple.launchd.6RgvKm8VMV/Listeners‘,
 60         __CF_USER_TEXT_ENCODING: ‘0x1F5:0x19:0x34‘,
 61         MAVEN_HOME: ‘/usr/local/Cellar/maven/3.2.2/libexec‘,
 62         PATH: ‘/Users/baidu/.nvm/v0.10.30/bin:/Users/baidu/Documents/myDocument/fcinst/bin:/Applications/MAMP/bin/php/php5.5.14/bin:/Library/Java/JavaVirtualMachines/jdk1.8.0.jdk/Contents/Home/bin:/usr/local/fcinst/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin‘,
 63         NVM_NODEJS_ORG_MIRROR: ‘http://nodejs.org/dist‘,
 64         PWD: ‘/Users/baidu/github/test‘,
 65         JAVA_HOME: ‘/Library/Java/JavaVirtualMachines/jdk1.8.0.jdk/Contents/Home‘,
 66         LANG: ‘zh_CN.UTF-8‘,
 67         NODE_PATH: ‘/Users/baidu/.nvm/v0.10.30/lib/node_modules‘,
 68         XPC_FLAGS: ‘0x0‘,
 69         XPC_SERVICE_NAME: ‘0‘,
 70         HOME: ‘/Users/baidu‘,
 71         SHLVL: ‘1‘,
 72         LOGNAME: ‘baidu‘,
 73         MAVEN: ‘/usr/local/Cellar/maven/3.2.2/libexec/bin‘,
 74         CLASSPATH: ‘:/Library/Java/JavaVirtualMachines/jdk1.8.0.jdk/Contents/Home/lib/dt.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0.jdk/Contents/Home/lib/tools.jar‘,
 75         NVM_BIN: ‘/Users/baidu/.nvm/v0.10.30/bin‘,
 76         DISPLAY: ‘/private/tmp/com.apple.launchd.SVvs5bqsWe/org.macosforge.xquartz:0‘,
 77         SECURITYSESSIONID: ‘186a5‘,
 78         _: ‘/Users/baidu/.nvm/v0.10.30/bin/node‘,
 79         OLDPWD: ‘/Users/baidu/github‘
 80     },
 81     pid: 2719,
 82     features: {
 83         debug: false,
 84         uv: true,
 85         ipv6: true,
 86         tls_npn: true,
 87         tls_sni: true,
 88         tls: true
 89     },
 90     _needImmediateCallback: false,
 91     execPath: ‘/Users/baidu/.nvm/v0.10.30/bin/node‘,
 92     debugPort: 5858,
 93     _getActiveRequests: [Function],
 94     _getActiveHandles: [Function],
 95     _needTickCallback: [Function],
 96     reallyExit: [Function],
 97     abort: [Function],
 98     chdir: [Function],
 99     cwd: [Function],
100     umask: [Function],
101     getuid: [Function],
102     setuid: [Function],
103     setgid: [Function],
104     getgid: [Function],
105     getgroups: [Function],
106     setgroups: [Function],
107     initgroups: [Function],
108     _kill: [Function],
109     _debugProcess: [Function],
110     _debugPause: [Function],
111     _debugEnd: [Function],
112     hrtime: [Function],
113     dlopen: [Function],
114     uptime: [Function],
115     memoryUsage: [Function],
116     binding: [Function],
117     _usingDomains: [Function],
118     _tickInfoBox: {
119         ‘0‘: 0,
120         ‘1‘: 0,
121         ‘2‘: 0
122     },
123     _events: {
124         SIGWINCH: [Function]
125     },
126     domain: null,
127     _maxListeners: 10,
128     EventEmitter: {
129         [Function: EventEmitter] listenerCount: [Function]
130     },
131     _fatalException: [Function],
132     _exiting: false,
133     assert: [Function],
134     config: {
135         target_defaults: {
136             cflags: [],
137             default_configuration: ‘Release‘,
138             defines: [],
139             include_dirs: [],
140             libraries: []
141         },
142         variables: {
143             clang: 1,
144             host_arch: ‘x64‘,
145             node_install_npm: true,
146             node_prefix: ‘/‘,
147             node_shared_cares: false,
148             node_shared_http_parser: false,
149             node_shared_libuv: false,
150             node_shared_openssl: false,
151             node_shared_v8: false,
152             node_shared_zlib: false,
153             node_tag: ‘‘,
154             node_unsafe_optimizations: 0,
155             node_use_dtrace: true,
156             node_use_etw: false,
157             node_use_openssl: true,
158             node_use_perfctr: false,
159             python: ‘/usr/bin/python‘,
160             target_arch: ‘x64‘,
161             v8_enable_gdbjit: 0,
162             v8_no_strict_aliasing: 1,
163             v8_use_snapshot: false,
164             want_separate_host_toolset: 0
165         }
166     },
167     nextTick: [Function: nextTick],
168     _currentTickHandler: [Function: _nextTick],
169     _nextDomainTick: [Function: _nextDomainTick],
170     _tickCallback: [Function: _tickCallback],
171     _tickDomainCallback: [Function: _tickDomainCallback],
172     _tickFromSpinner: [Function: _tickFromSpinner],
173     maxTickDepth: 1000,
174     stdout: [Getter],
175     stderr: [Getter],
176     stdin: [Getter],
177     openStdin: [Function],
178     exit: [Function],
179     kill: [Function],
180     addListener: [Function],
181     on: [Function],
182     removeListener: [Function],
183     mainModule: {
184         id: ‘.‘,
185         exports: {},
186         parent: null,
187         filename: ‘/Users/baidu/github/test/b.js‘,
188         loaded: false,
189         children: [],
190         paths: [‘/Users/baidu/github/test/node_modules‘,
191             ‘/Users/baidu/github/node_modules‘,
192             ‘/Users/baidu/node_modules‘,
193             ‘/Users/node_modules‘,
194             ‘/node_modules‘
195         ]
196     }
197 }
时间: 2024-08-08 09:38:51

node全局变量process属性值(mac环境)的相关文章

Node.js【2】开发环境搭建(Windows、Linux&Mac)

安装方式有非常多种,以下仅仅是我喜欢的一种方式,安装的路径不一定要跟我一样. 眼下最新的版本号是v0.10.28 Windows 1.下载(放到E:\node\nodejs): http://nodejs.org/dist/latest/x64/node.exe http://nodejs.org/dist/npm/npm-1.4.9.zip 2.解压(到当前文件夹):npm-1.4.9.zip 3.环境变量: Path里面添加?:E:\node\nodejs 4.改动npm配置: C:\Use

node.js中的交互式运行环境-REPL

<Node.js权威指南>第2章Node.js中的交互式运行环境--REPL 开发者可以在该环境中很方便地输入各种JavaScript表达式并观察表达式的运行结果. 在学习Node.js框架的过程中,通过该运行环境的使用,我们可以很方便地了解Node.js中定义的各种对象所拥有的各种属性及方法.本节为大家介绍在REPL运行环境中操作变量 2.2 在REPL运行环境中操作变量 在REPL运行环境中,可以使用var关键字来定义一个变量并为其赋值,但是在输入了对其赋值进行的表达式后,该表达式的执行结

带你深入剖析inline-block属性值的前世今生

曾几何时,display:inline-block 已经深入「大街小巷」,随处可见 「display:inline-block; *display:inline; *zoom:1; 」这样的代码.如今现代浏览器已经全面支持这个属性值了,上面的代码只是为了兼容 IE6.7 而已.那么你真的了解 inline-block 了吗?本文将带你深入剖析该属性值的前世今生,让你更好的理解和运用 inline-block.(本文约定 display:inline-block 简写为 inline-block)

【小家Spring】老项目迁移问题:@ImportResource导入的xml配置里的Bean能够使用@PropertySource导入的属性值吗?

#### 每篇一句 > 大师都是偏执的,偏执才能产生力量,妥协是没有力量的.你对全世界妥协了你就是空气.所以若没有偏见,哪来的大师呢 #### 相关阅读 [[小家Spring]详解PropertyPlaceholderConfigurer.PropertyOverrideConfigurer等对属性配置文件Properties的加载和使用](https://blog.csdn.net/f641385712/article/details/91444601) [[小家Spring]Spring中@

Mac环境变量的位置、查看和添加PATH环境变量

Mac 启动加载文件位置(可设置环境变量) (1)首先要知道你使用的Mac OS X是什么样的Shell,使用命令echo $SHELL如果输出的是:csh或者是tcsh,那么你用的就是C Shell.如果输出的是:bash,sh,zsh,那么你的用的可能就是Bourne Shell的一个变种.Mac OS X 10.2之前默认的是C Shell.Mac OS X 10.3之后默认的是Bourne Shell. (2)如果是Bourne Shell.那么你可以把你要添加的环境变量添加到你主目录下

Python帮助函数调试函数 用于获取对象的属性及属性值

刚接触Python,上篇 <Python入门>第一个Python Web程序--简单的Web服务器 中调试非常不方便,不知道对象详细有什么属性,包括什么值,所以写了一个函数.用于获取对象的属性及属性值 函数代码例如以下: #调试函数.用于输出对象的属性及属性值 def getAllAttrs(obj): strAttrs = '' for o in dir(obj): strAttrs =strAttrs + o + ' := ' + str(getattr(obj,o)) + '<br

JavaScript中node的相关属性

1,childNodes childNodes属性将返回一个数组,这个数组包含给定元素节点的全体子元素. 检索body元素的第一个子节点: var body_element=document.getElementByTagName("body")[0]; body元素有几个子元素 var body_element_length=body_element.lchildNodes.length; 2,noteType 检索节点 的类型 alert(body_element.noteType

SoapUI对于Json数据进行属性值获取与传递

SoapUI的Property Transfer功能可以很好地对接口请求返回的数据进行参数属性获取与传递,但对于Json数据,SoapUI会把数据格式先转换成XML格式,但实际情况却是,转换后的XML格式往往根本没法用Xpath形式获取到指定的数据了.因此只能用Script脚本形式了. {"addUsersToDirectoryResponse":{"addUserToDirectoryResponse":[{"ack":"Succes

MAC环境下 nodejs 4.5.0 卸载

MAC 环境下,我之前的删除 node 环境如果是用brew 安装的 node.js 4.4 之前的版本.可以网上参考其他方法,我之前的帖子也有之前的删除方法.参考帖子: http://www.cnblogs.com/wjw-blog/p/4840727.html 另外,只要是在 node 官网上下载的安装包,用安装包安装的node.应该可以用一下命令行卸载: 在终端输入以下命令: sudo rm -rf /usr/local/{bin/{node,npm},lib/node_modules/n