osx-elcapitan

How to extract xip archive using command line?

筅森魡賤 提交于 2019-12-03 09:26:59
问题 I searched around how to extract XIP archive using command line with no luck so I am leaving my own solution, as a bash function, here. I found my inspiration here. 回答1: function unxip() { [ -z "$1" ] && echo "usage: unxip /path/to/archive.xip" && return # http://newosxbook.com/src.jl?tree=listings&file=pbzx.c PBZX="/usr/local/src/pbzx/pbzx" && [ ! -x "$PBZX" ] && echo "$PBZX not found." && return [ ! -f "$1" ] && echo "$1 not found." && return [ -f "Content" ] || [ -f "Metadata" ] && echo

MAC OSX El Capitan: Airport Sym link not permitted

心已入冬 提交于 2019-12-03 04:18:57
问题 I tried making a symbolic link to the airport command in MAC OS X El Capitan, using the command: sudo ln -s /System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport /usr/sbin/airport It returned the following error: ln: /usr/sbin/airport: Operation not permitted Is this due to the El Capitan's "rootless" feature? The sym link worked fine in MAC OS X Yosemite. 回答1: The target directory should be /usr/local/bin/airport See the article on System Integrity

copying file under root got failed in OS X El Capitan 10.11

你。 提交于 2019-12-03 03:49:26
问题 I'm trying to copy under root file into /System folder. It works well on all previous OS X version but not on El Capitan 10.11 Here how I copy file under root in terminal: MACMINI:~ myusername$ sudo su - MACMINI:~ root# cp /Users/myusername/Desktop/myfile.plist /System/Library/LaunchDaemons/ As result I receive an error: cp: /System/Library/LaunchDaemons/myfile.plist: Operation not permitted 回答1: Considering that certain system directories are protected from being written at all (even with

Using pfctl on Mac OS 10.11 (El Capitan) to forward ports

纵饮孤独 提交于 2019-12-03 03:45:20
I am currently testing if my developing environment will run on the new upcoming Mac OS 10.11 and if I can upgrade as soon as it's released. On my test machine I am currently running the Beta Preview 3. Everything seems to be running fine. I just can get pfctl to forward my ports. I use Vagrant and Parallels Desktop to run a Debian system for my local web server. Vagrant forwards port 8080 on the host to 80 on the guest. So 127.0.0.1:8080 works fine. But in some projects I want to have the exact same domain local as it will be in production. (without the :8080) Also I just like it more. ;-) To

How to extract xip archive using command line?

放肆的年华 提交于 2019-12-03 01:02:56
I searched around how to extract XIP archive using command line with no luck so I am leaving my own solution, as a bash function, here. I found my inspiration here . function unxip() { [ -z "$1" ] && echo "usage: unxip /path/to/archive.xip" && return # http://newosxbook.com/src.jl?tree=listings&file=pbzx.c PBZX="/usr/local/src/pbzx/pbzx" && [ ! -x "$PBZX" ] && echo "$PBZX not found." && return [ ! -f "$1" ] && echo "$1 not found." && return [ -f "Content" ] || [ -f "Metadata" ] && echo "Content or Metadata already exists." && return pkgutil --check-signature "$1" && xar -xf "$1" && "$PBZX"

brew install npm “npm: command not found”

送分小仙女□ 提交于 2019-12-02 21:44:52
I've installed node using brew install node and when I use the node -v I get following v5.0.0 . However when I try to run the npm command I get npm: command not found . I've tried to run brew install npm , however I just got following response node-5.0.0 already installed . It happened with node also returning command not found, but that I fixed by running brew link node , however npm still does not seem to work. How can I resolve this problem? You need to make sure that your $NODE_PATH environment variable is set: # Add this to your ~/.bash_profile file: export NODE_PATH="/usr/local/lib/node

Install wxPython 2.8 (For Ride) on OSX “El Capitan”

左心房为你撑大大i 提交于 2019-12-02 18:55:41
I'm trying to install wxPython 2.8 unicode version, to be able to use robotframework-ride. So far the installer downloaded from the site failed with an error saying "There was no software to install" And using Brew installs the 3.0 version, that is not compatible with ride. I would appreciate some help on this issue, I'm a new Mac user (just got given one at the office, and have to use it for my project) , and this is the only thing so far that I haven't been able to solve at all. The version I need to install is: wxPython2.8-osx-unicode-2.8.12.1-universal-py2.7 The installer doesn't seem to

Docker image running a Mac OS X installation

泪湿孤枕 提交于 2019-12-02 17:13:10
I am using Docker for Mac and wish to create Docker image running a Mac El Capitan with my development env. I am not finding any resources on this. All I see is Linux installations. On Linux I saw things as simple as: FROM sciensa2/docker-java8 RUN apt-get update RUN apt-get install -y wget unzip libgtk2.0-0:amd64 libxtst6 But what would be the FROM value for OS X to install and run other software? If you are trying to run Mac OS as the base system in a Docker container, unfortunately there is no way to do it. Docker container need to use the host machine's Linux Kernel, since Mac OS family is

brew install mysql on mac os el capitan

二次信任 提交于 2019-12-02 16:42:15
I'm trying to install mysql on MAC OS version 10.11.2 by following the methods in this link , The following command has been successfully executed, brew install mysql but when I type the following command, mysql_install_db --verbose --user=`whoami` --basedir="$(brew --prefix mysql)" --datadir=/usr/local/var/mysql --tmpdir=/tmp I get the following error: mysql_install_db: [ERROR] unknown variable 'tmpdir=/tmp' 2015-12-17 17:35:54 [ERROR] Unrecognized options Please help. Thanks in advance. All credit goes to coder wall Remove MySQL completely ps -ax | grep mysql stop and kill any MySQL

Python code to detect dark mode in OS X El Capitan to change the status bar menu icon

谁说我不能喝 提交于 2019-12-02 11:58:55
问题 I have objective C code to detect dark mode to change the status bar: [[NSDistributedNotificationCenter defaultCenter] addObserver:self selector:@selector(darkModeChanged:) name:@"AppleInterfaceThemeChangedNotification" object:nil]; Similarly, how can we do the same in python? 回答1: Try these following lines wherever you want to detect the mode (dark mode or light mode). center = NSDistributedNotificationCenter.defaultCenter() center.addObserver_selector_name_object_(self,"enableDarkMode",