Skip to content

Setup Mac_M2


% git --version
xcode-select: note: no developer tools were found at '/Applications/', requesting install. Choose an option in the dialog to download the command line developer tools.
% git --version
git version 2.32.1 (Apple Git-133)

brew (not necessary now)

% brew --version
zsh: command not found: brew

% /bin/bash -c "$(curl -fsSL"
==> Next steps:
- Run these two commands in your terminal to add Homebrew to your PATH:
    echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> /Users/yuichi/.zprofile
    eval "$(/opt/homebrew/bin/brew shellenv)"

% echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> /Users/yuichi/.zprofile
% eval "$(/opt/homebrew/bin/brew shellenv)"
% brew --version
Homebrew 3.6.0

git config

% git config -l

% git config --global "myname"
% git config --global ""

% git config -l                                           


% cd ~
% ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (/Users/yuichi/.ssh/id_rsa):
Created directory '/Users/yuichi/.ssh'.
Your identification has been saved in /Users/yuichi/.ssh/id_rsa
Your public key has been saved in /Users/yuichi/.ssh/

% cd .ssh
% ls
% cat | pbcopy


Right top icon -> Edit profile -> SSH Keys -> command+V

SSH (optional)

% ssh -T
The authenticity of host ' (' can't be established.
ED25519 key fingerprint is SHA256:WnuB9nH4cmBJGz2iMuj8ckmYNCq/M.
This key is not known by any other names
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added '' (ED25519) to the list of known hosts.
Enter passphrase for key '/Users/yuichi/.ssh/id_rsa':
Welcome to GitLab, @yuichitamiya!

git clone

% cd ~
% cd repos
% git clone fa2022_kannai_site
% ls

Python, pip

% python3 -V
Python 3.8.9
% pip -V
zsh: command not found: pip
% cd Downloads
% curl -o
% python3
WARNING: The scripts pip, pip3 and pip3.8 are installed in '/Users/yuichi/Library/Python/3.8/bin' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
Successfully installed pip-22.2.2

% pip -V
zsh: command not found: pip
% pip3 -V
pip 22.2.2 from /Users/yuichi/Library/Python/3.8/lib/python/site-packages/pip (python 3.8)


% cd repos/fa2022_kannai_site
% ls       docs            requirements.txt
agreements      mkdocs.yml
% pip3 install -r requirements.txt
WARNING: The script watchmedo is installed in '/Users/yuichi/Library/Python/3.8/bin' which is not on PATH.
Successfully installed GitPython-3.1.27 Jinja2-3.0.3 Markdown-3.4.1 MarkupSafe-2.1.1 PyYAML-6.0 babel-2.10.3 click-8.1.3 ghp-import-2.1.0 gitdb-4.0.9 importlib-metadata-4.12.0 mergedeep-1.3.4 mkdocs-1.2.4 mkdocs-git-revision-date-localized-plugin-0.11.1 mkdocs-material-8.2.7 mkdocs-material-extensions-1.0.3 packaging-21.3 pygments-2.13.0 pymdown-extensions-9.5 pyparsing-3.0.9 python-dateutil-2.8.2 pytz-2022.2.1 pyyaml-env-tag-0.1 smmap-5.0.0 watchdog-2.1.9 zipp-3.8.1

% mkdocs serve
zsh: command not found: mkdocs

% pip3 install mkdocs
Requirement already satisfied: mkdocs in /Users/yuichi/Library/Python/3.8/lib/python/site-packages (1.2.4)


$ cd ~
% echo $SHELL
% nano .zshrc


export PATH="/Users/yuichi/Library/Python/3.8/bin:$PATH"
control+X -> Yes

mkdocs serve

% cd repos/fa2022_kannai_site
% mkdocs serve
zsh: command not found: mkdocs

% source ~/.zshrc

% mkdocs serve
INFO     -  Building documentation...
INFO     -  [00:49:25] Serving on


install atom

instal packages

Atom -> Preferences -> Setting -> Install -> Search packages “tree-view-copy-relative-path”

open atom from Terminal

% open -a atom


% cd ~
% nano .zshrc


alias atom="open -a atom"

% source ~/.zshrc

% cd repos/fa2022_kannai_site
% atom .
Ref. ターミナルでのコマンドを短縮するためにエイリアスを設定する。〜快適にコマンドを打とう〜
Ref. Open Any Application from the Terminal

open Chrome

% cd
% cd /Applications
% ls
% open -a "Google chrome"

% cd ~
% nano .zshrc


alias chrome='open -a "Google chrome"'

% source ~/.zshrc

% cd/repos/fa2022_kannai_site
% chrome
% mkdocs serve
-> open Mkdocs on chrome!!!

Last update: September 11, 2022