Ariya Hidayat
51d5835942
System#os.version workaround for new(er) OS X versions.
...
In case Qt doesn't provide the information yet, deduce it from the OS
kernel version (e.g. 14.x.y for OS 10.10 Yosemite).
https://github.com/ariya/phantomjs/issues/12579
2014-09-23 07:51:36 -07:00
Ariya Hidayat
72c53b5476
System#os.version should know OS 10.9 Mavericks.
...
https://github.com/ariya/phantomjs/issues/12579
2014-09-22 20:46:51 -07:00
Ariya Hidayat
639e09bd3a
Provide OS kernel version in system.os.
...
This is available via the new property called `release`. A very simple
example to demonstrate it:
var system = require('system');
console.log('Kernel release', system.os.release);
which will print (on OS X 10.7.5 Lion):
Kernel release 11.4.2
https://github.com/ariya/phantomjs/issues/12587
2014-09-21 23:47:57 -07:00
Vitaliy Slobodin
cf12fc4a23
Long live PhantomJS 2!
...
https://github.com/ariya/phantomjs/issues/10448
2014-07-27 07:47:34 -07:00
execjosh
39bec1ce17
Synchronize std{in,out,err} encoding with `Terminal`
...
See #11234 https://github.com/ariya/phantomjs/pull/11234
Spin off from #11168 https://github.com/ariya/phantomjs/pull/11168
2013-04-29 07:00:47 -07:00
execjosh
36ab7194e4
Use UTF-8 encoding for std{in,out,err}
...
This fixes issue #11162 .
`File` constructor takes a `QTextCodec *`, codec; but, if codec is
`NULL`, then it assumes "binary" mode, which causes non-ASCII
characters to be converted to NUL (`\0`) in `File::write`.
This change passes the codec for UTF-8 to the `File` constructor for
the `std{in,out,err}` instances, thus opening them in *text mode*.
2013-04-12 23:10:25 -07:00
execjosh
d906bc3819
Automate lazy generation of REPL completion lists
...
All invokable methods, slots, signals, and properties visible from
JavaScript, but which do not start with an underscore, are lazily
(only when necessary) added to the completion list through dynamic
reflection.
This leverages `QMetaObject` for reflection of `QObject`s. As such,
there is now no need to inherit `REPLCompletable` and it has been
removed.
http://code.google.com/p/phantomjs/issues/detail?id=943
2013-01-04 21:23:58 -08:00
execjosh
f6c87221a7
Implement system.std{in,out,err}
...
See [issue 333][1] and pull request #192 .
**Caveat**
`File::read` currently takes no parameters and is equivalent to a
"`readAll`". This will be changed later to match [IO/A Spec's
`Stream#read`][2]; but, should still be noted.
[1]: http://code.google.com/p/phantomjs/issues/detail?id=333
[2]: http://wiki.commonjs.org/wiki/IO/A#Instance_Methods
2012-12-25 03:41:34 -08:00
James M. Greene
280305797e
Exposing the Process ID (PID) via the System module.
...
`require('system').pid` should return your PhantomJS instance's Process ID.
http://code.google.com/p/phantomjs/issues/detail?id=769
2012-11-06 11:49:55 -06:00
Ariya Hidayat
3b161b914a
Add 'isSSLSupported' to the system module.
...
http://code.google.com/p/phantomjs/issues/detail?id=484
2012-09-03 06:50:34 -07:00
Ariya Hidayat
c191a00277
Better support for OS X Mountain Lion.
...
require('system').os.version should give "10.8 (Mountain Lion)".
http://code.google.com/p/phantomjs/issues/detail?id=688
2012-07-31 23:37:53 -07:00
Ariya Hidayat
9ca88ea681
Better support for Windows 8.
...
require('system').os.version should give "8" for Windows 8.
http://code.google.com/p/phantomjs/issues/detail?id=684
2012-07-30 05:07:50 -07:00
Ivan De Marino
f40b7ab730
Adding property "os" to the "system" module.
...
Contains the properties:
- name
- architecture
- version
http://code.google.com/p/phantomjs/issues/detail?id=585
2012-06-15 00:12:08 -07:00
Ariya Hidayat
756d0d3166
Implement system.env to get system environment variables.
...
Based on the initial work from execjosh:
https://github.com/ariya/phantomjs/pull/192
See also http://wiki.commonjs.org/wiki/System#System_Interface .
http://code.google.com/p/phantomjs/issues/detail?id=271
2012-03-15 01:22:17 -07:00
Ariya Hidayat
545a3f76b4
Implement system.args to get command-line arguments.
...
This also means that phantom.args is deprecated.
Based on the initial work from execjosh:
https://github.com/ariya/phantomjs/pull/192
See also http://wiki.commonjs.org/wiki/System#System_Interface .
http://code.google.com/p/phantomjs/issues/detail?id=270
http://code.google.com/p/phantomjs/issues/detail?id=276
2012-03-15 01:11:26 -07:00
Ariya Hidayat
119e1ba516
Implement the plumbing for CommonJS System module support.
...
See http://wiki.commonjs.org/wiki/System .
Based on the initial work from execjosh:
https://github.com/ariya/phantomjs/pull/192
http://code.google.com/p/phantomjs/issues/detail?id=270
2012-03-14 23:23:43 -07:00