I installed phantomjs in my mac. I thought when I input in the terminal phantomjs xx.js it should work. However, it just returns
-bash: phantomjs: command not found
Then I found the file phantomjs is located in
/usr/local/Cellar/phantomjs/2.0.0/bin
Only if I am in that directory, can I use the command phantomjs.
My question is how can I make the command phantomjs work in other locations, like /Usr/Documents/... Thanks!
Related
I have this bash: rbenv: command not found thing always coming up on my terminal whenever I open it and they appear four times as shown below.
I am using windows, please, how do I fix this? All solutions I have researched are tailored toward MacOs.
bash: rbenv: command not found
bash: rbenv: command not found
bash: rbenv: command not found
bash: rbenv: command not found
I am using windows, please, how do I fix this? All solutions I have researched are tailored toward MacOs.
The error is coming from bash, a Unix shell. It's unclear how that's running on Windows (perhaps Windows Subsystem for Linux?) but the MacOS (really Unix) instructions should work.
Presumably you installed rbenv in this Unix on Windows environment at some point and now it's gone. If you want it back, install it again.
If you want it gone, follow the uninstall instructions. rbenv will add a line rbenv init to your shell startup configuration files. In bash, look at your .bashrc and .bash_profile files in your home directory and remove anything to do with rbenv.
If you don't know how to use bash, see Introduction to Bash for more.
I use Ubuntu 16.10. I tried installing Selenium module of python via the command - sudo pip3 install -U selenium. But, I am not able to install it. It is giving an unexpected error. I am sharing the screenshot of the terminal here. Please help!
Please click here for the screenshot
If you are using Ubuntu, I'd suggest checking in the package manager as it may already be there. I'm on Mint and it was already there when I loaded python (2.7 also).
I'm running PhantomJS 1.9.1 from Terminal on Mac OS 10.8.4, like so:
$ phantomjs
I get the PhantomJS prompt:
phantomjs>
But no matter what I type (including console.log('hello world'), etc.), nothing is printed to the terminal in response.
Am I launching it with incorrect parameters, or not setting it up properly after startup, or is there some other problem anyone can guess?
If I execute $ phantomjs test.js, the code in test.js does execute and get printed to the terminal.
Apparently installing PhantomJS through Node Package Manager may have something to do with this issue. If I download and install PhantomJS for Mac directly, then the REPL works as expected.
is it possible to run Google's Big Query command line tool: gsutil on Windows 7 64 bit?
I could not get this to work because of a dependent Python module called: pyOpenSSL-0.13, which I could not install w/o building it using Microsoft Express 2008. Just wondered if this was a known issue.
Thanks.
OK. I finally came up with a solution for those with a similar problem:
Install cygwin w/ dev tools (i.e. gcc compiler, make, automake, etc)
Install openssl-dev for cygwin.
Download pyOpenSSL-0.13 gzip file and decompress it into home folder. (Google for this)
run "python setup.py install" from inside a cygwin prompt.
Download gsutil source code from Google and decompress it into home folder.
run "python setup.py install" from inside a cygwin prompt.
cd to the gsutil directory
run ./gsutil
This solution worked for me on a 64 bit Windows 7 machine. It could be that I broke my installation and that others may not run into this problem. However, it does seem that OpenSSL support for gsutil on a Windows 64 bit machine running 64 bit python is non-existent.
After downloading emscripten via
git clone git://github.com/kripken/emscripten.git
and running
./emcc
a .emscripten file is created in my user root.
==============================================================================
Welcome to Emscripten!
This is the first time any of the Emscripten tools has been run.
A settings file has been copied to ~/.emscripten, at absolute path: /Users/calvin/.emscripten
Please edit that file and change the paths to fit your system. Specifically,
make sure LLVM_ROOT and NODE_JS are correct.
This command will now exit. When you are done editing those paths, re-run it.
==============================================================================
I have llvm installed and nodejs installed via macports. So where should I change LLVM_ROOT and NODE_JS to point to?
running emsdk activate latest (after having run emsdk install latest, which takes a while) gets all of my aliases and such working, I've added it to my bash profile
Are the LLVM / Node.js commands accessible on your path? E.g. does running node or clang work?
If so, you can detect the paths you need from there. For LLVM_ROOT, you want the directory containing the LLVM binaries:
$ dirname `which llvm-config`
/usr/local/bin
For NODE_JS, you want the path to the node binary itself:
$ which node
/usr/local/bin/node
If this fails (because they are not on your path already), then try looking in /opt/local/bin. That's seems like the right place from the MacPorts docs (I don't use MacPorts myself).