This fork is slightly different than the original in that is supports true sudo-less install of Gems
Setup developer workstation for Android and iOS mobile development
- A fresh installed OS X 10.10+
- User with admin rights
- Apple developer account (for Xcode)
- Internet connection
On your developer machine run:
bash <(curl -s https://raw.githubusercontent.com/jinjorge/mobile-dev-bootstrap/master/mobile-dev-bootstrap.sh)At the end you will have:
- Android and iOS 📱 development ready environment
To save time
All the process is automated, it asks the user password and Apple Developer password at the beginning.
OS X optimised mobile Android and iOS development.
XcodexctoolCocoapodsCarthage- Fastlane bundle:
fastlanedeliversnapshotframeitpemsighproducecertcodesspaceshippilotgymmatch - nomad-cli bundle:
iosapnpkiapipa - Code quality tools:
oclintlcovgcovrslatherclocswiftlint - XCTest utilities:
ocunit2junitxcpretty - Simulator utility:
ios-sim - Other utilities:
synxsplunk-mobile-uploadnexus-uploadcrashlytics-upload-ipaiosbuilder
To update installed software you can use the mobile-dev-update utility. By default it will update the OSX, Xcode, Android SDK Componets, Ruby packages, Brew packages, NPM packages, PHP packages.
mobile-dev-updateOr if you need to update specific component:
mobile-dev-update xcodeAvailable options are:
osx- Updates the OSX.xcode- Installs the latest Xcode.android- Updates installed Android SDKbrew- Updates installed brew packagescask- Updates installed Brew casks (e.g. java, java7, oclint)gem- Updates installed Ruby gemsnpm- Updates installed npm packagesphp- Updates installed php packages.
The Java environment is controlled by jenv.
To get current java versions:
jenv versionTo list installed java versions:
jenv versionsTo change default java version:
jenv global 1.8To change shell session default java version:
jenv shell 1.8In case you prefer upgrading the software manually.
Install all updates:
packages=""
for package in $(android list sdk --no-ui | \
grep -v -e "Obsolete" -e "Sources" -e "x86" -e "Samples" \
-e "ARM EABI" -e "ARM System Image" -e "API 8" -e "API 8" -e "API 10" -e "API 15" \
-e "API 16" -e "API 17" -e "API 18" -e "API 20" -e "rc" \
-e "Documentation" -e "MIPS" -e "Android TV" \
-e "Build-tools, revision 19.1" -e "Build-tools, revision 20" -e "Build-tools, revision 21.1.2" \
-e "Glass" -e "XML" -e "URL" -e "Packages available" \
-e "Fetch" -e "Web Driver" | \
cut -d'-' -f1)
do
packages=$(printf "${packages},${package}")
done
( sleep 5 && while [ 1 ]; do sleep 1; echo y; done ) | android update sdk --no-ui --filter "$packages"All installed Xcodes are following the Xcode-<version>.app naming convention.
The /Applications/Xcode.app is a symbolic link to the current default Xcode.
To install a new version of Xcode use xcode-install:
export XCODE_INSTALL_USER="[email protected]"
XCODE_INSTALL_PASSWORD="secret"
xcversion install 7.1
sudo xcodebuild -license acceptUpdate all packages:
brew update
brew upgradeandroid-sdk was updated also run the steps from the Android SDK.
Update all packages:
brew update
brew upgrade brew-cask
brew cask updatesudo when updating Ruby packages, because we are using rbenv.
Update all packages:
gem update -pgem uninstall psych --all
gem install psych -v 2.0.0Update all packages:
npm update -g