iOS/iPhone/iPad/watchOS/tvOS/MacOSX/Android プログラミング, Objective-C, Cocoa, Swiftなど
macOSでの開発環境の構築の手順を示します。
# Rosetta 2のインストール
$ sudo softwareupdate --install-rosetta --agree-to-license
# Homebrewのインストール
$ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
# .zprofile または .zshrc または .zshenv に設定を追加
eval "$(/opt/homebrew/bin/brew shellenv)"
# rbenvのインストール
$ brew install rbenv
# .zprofile または .zshrc または .zshenv に設定を追加
if which rbenv > /dev/null; then
eval "$(rbenv init -)"
fi
# Ruby 3.3.6をインストールして選択
$ rbenv install 3.3.6
$ rbenv global 3.3.6
# Bundlerのインストール
$ rbenv exec gem install bundler
$ rbenv rehash
# .zprofile または .zshrc または .zshenv に設定を追加
export PATH=$HOME/.gem/bin:$PATH
# CocoaPodsのインストール
$ sudo gem install cocoapods
$ pod setup
Visual Studio Codeをダウンロード
- https://code.visualstudio.com/download
Xcodeを入手
- https://developer.apple.com/jp/xcode/ Command Line Toolsもインストールする# Xcodeの選択 $ sudo sh -c 'xcode-select -s /Applications/Xcode.app/Contents/Developer && xcodebuild -runFirstLaunch' # ライセンスを確認 $ sudo xcodebuild -license
Android Studioを入手
- https://developer.android.com/studio/install?hl=ja Android SDK Command-line Toolsなどのインストールが必要。
Flutter SDKをインストール
- https://docs.flutter.dev/get-started/install Flutter SDKは公式サイトで説明されている ~/development ディレクトリの配置する。unzip ~/Downloads/flutter_macos_*-stable.zip -d ~/development/ # .zprofile または .zshrc または .zshenv に設定を追加 export PATH=$HOME/development/flutter/bin:$PATH
# Flutter doctorを実行して確認する
$ flutter doctor
エラーになった項目の対応を行う。