feat: brew and apt packages
This commit is contained in:
14
script/install.d/04-git.sh
Normal file
14
script/install.d/04-git.sh
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# -----------------------------------------------------------------------------
|
||||||
|
# Description:
|
||||||
|
# Configure git.
|
||||||
|
#
|
||||||
|
|
||||||
|
if ! command -v git &> /dev/null; then
|
||||||
|
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
|
||||||
|
sudo apt-get install -qq git
|
||||||
|
elif [[ "$OSTYPE" == "darwin"* ]]; then
|
||||||
|
brew install git
|
||||||
|
fi
|
||||||
|
fi
|
||||||
19
script/install.d/21-gh_cli.sh
Normal file
19
script/install.d/21-gh_cli.sh
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
# /bin/bash
|
||||||
|
|
||||||
|
# -----------------------------------------------------------------------------
|
||||||
|
# Description:
|
||||||
|
# Install GitHub CLI.
|
||||||
|
#
|
||||||
|
|
||||||
|
if ! command -v gh &>/dev/null; then
|
||||||
|
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
|
||||||
|
# https://github.com/cli/cli/blob/trunk/docs/install_linux.md#debian-ubuntu-linux-raspberry-pi-os-apt
|
||||||
|
sudo mkdir -p -m 755 /etc/apt/keyrings && wget -qO- https://cli.github.com/packages/githubcli-archive-keyring.gpg | sudo tee /etc/apt/keyrings/githubcli-archive-keyring.gpg >/dev/null &&
|
||||||
|
sudo chmod go+r /etc/apt/keyrings/githubcli-archive-keyring.gpg &&
|
||||||
|
echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list >/dev/null &&
|
||||||
|
sudo apt update &&
|
||||||
|
sudo apt install gh -y
|
||||||
|
elif [[ "$OSTYPE" == "darwin"* ]]; then
|
||||||
|
brew install gh
|
||||||
|
fi
|
||||||
|
fi
|
||||||
12
script/install.d/30-iterm2.sh
Normal file
12
script/install.d/30-iterm2.sh
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# -----------------------------------------------------------------------------
|
||||||
|
# Description:
|
||||||
|
# (macOS only) Install iTerm2.
|
||||||
|
#
|
||||||
|
|
||||||
|
if [[ "$OSTYPE" == "darwin"* ]]; then
|
||||||
|
if ! command -v iterm2 &> /dev/null; then
|
||||||
|
brew install --cask iterm2
|
||||||
|
fi
|
||||||
|
fi
|
||||||
12
script/install.d/70-cca.sh
Normal file
12
script/install.d/70-cca.sh
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# -----------------------------------------------------------------------------
|
||||||
|
# Description:
|
||||||
|
# (macOS only) Install Colour Contrast Analyser (CCA).
|
||||||
|
#
|
||||||
|
|
||||||
|
if [[ "$OSTYPE" == "darwin"* ]]; then
|
||||||
|
if ! command -v cca &> /dev/null; then
|
||||||
|
brew install --cask colour-contrast-analyser
|
||||||
|
fi
|
||||||
|
fi
|
||||||
Reference in New Issue
Block a user