Skip to content

Commit 6bb5c5e

Browse files
authored
Merge pull request #6 from dev-satoshi/brew
brewのセットアップスクリプトを作成
2 parents 0e18205 + 0f9b561 commit 6bb5c5e

5 files changed

Lines changed: 49 additions & 2 deletions

File tree

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@ jobs:
1717
- name: Run ShellCheck
1818
run: |
1919
find . -type f -name '*.sh' -not -path './.github/*' -print0 \
20-
| xargs -0 shellcheck
20+
| xargs -0 shellcheck --shell=bash

homebrew/Brewfile

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,29 +2,40 @@ tap "homebrew/bundle"
22
brew "act"
33
brew "asdf"
44
brew "btop"
5+
brew "coturn"
56
brew "curl"
67
brew "git"
8+
brew "gnupg"
79
brew "gstreamer"
810
brew "jq"
11+
brew "just"
912
brew "libyaml"
1013
brew "mas"
14+
brew "mkcert"
1115
brew "nmap"
1216
brew "tbls"
1317
brew "tree"
18+
brew "wget"
1419
brew "zsh-autosuggestions"
1520
brew "zsh-completions"
1621
cask "alfred"
17-
cask "android-sdk"
22+
cask "android-commandlinetools"
1823
cask "android-studio"
1924
cask "arc"
2025
cask "clipy"
2126
cask "drawio"
2227
cask "figma"
28+
cask "font-udev-gothic"
2329
cask "google-chrome"
2430
cask "notion"
2531
cask "orbstack"
32+
cask "protonvpn"
33+
cask "rectangle"
2634
cask "sequel-ace"
2735
cask "slack"
2836
cask "visual-studio-code"
2937
cask "warp"
38+
cask "wireshark"
39+
mas "TestFlight", id: 899247664
40+
mas "Transporter", id: 1450874784
3041
mas "Xcode", id: 497799835

scripts/homebrew_setup.sh

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#!/usr/bin/env zsh
2+
set -euo pipefail
3+
4+
echo "「Homebrew」のセットアップを開始しました"
5+
6+
# brewのインストール
7+
if ! command -v brew >/dev/null 2>&1; then
8+
echo "「Homebrew」が見つかりません。インストールを開始します..."
9+
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
10+
else
11+
echo "「Homebrew」は既にインストールされています"
12+
fi
13+
14+
# パッケージリストを更新
15+
brew update
16+
17+
# インストール済みのbrewパッケージを書き出す(VSCode関連を除く)
18+
brew bundle dump --force --file=~/dotfiles/homebrew/Brewfile
19+
sed -i '' '/^vscode /d' ~/dotfiles/homebrew/Brewfile
20+
21+
# Brewfileを元にインストール
22+
brew bundle --file=~/dotfiles/homebrew/Brewfile
23+
24+
echo "「Homebrew」のセットアップが完了しました"

scripts/setup.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
#!/usr/bin/env zsh
2+
set -euo pipefail
3+
4+
echo "「dotfiles」のセットアップを開始しました"
5+
6+
INSTALL_DIR="$HOME/dotfiles"
7+
8+
sh "$INSTALL_DIR/scripts/homebrew_setup.sh"
9+
10+
echo "「dotfiles」のセットアップが完了しました"

zsh/.zshenv

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Homebrew
2+
eval "$(/opt/homebrew/bin/brew shellenv)"

0 commit comments

Comments
 (0)