feature: add iterm2-themes
authorAJ ONeal <aj@therootcompany.com>
Fri, 19 Nov 2021 10:32:04 +0000 (10:32 +0000)
committerAJ ONeal <aj@therootcompany.com>
Fri, 19 Nov 2021 10:47:53 +0000 (10:47 +0000)
iterm-color-schemes/install.sh [new file with mode: 0644]
iterm-themes/install.sh [new file with mode: 0644]
iterm2-color-schemes/install.sh [new file with mode: 0644]
iterm2-themes/README.md [new file with mode: 0644]
iterm2-themes/install.sh [new file with mode: 0644]

diff --git a/iterm-color-schemes/install.sh b/iterm-color-schemes/install.sh
new file mode 100644 (file)
index 0000000..3f4d484
--- /dev/null
@@ -0,0 +1,10 @@
+# title: iterm-color-schemes (iterm2-themes alias)
+# homepage: https://webinstall.dev/iterm2-themes
+# tagline: Alias for https://webinstall.dev/iterm2-themes
+# alias: iterm2-themes
+# description: |
+#   See https://webinstall.dev/iterm2-themes
+
+echo "'iterm-color-schemes@${WEBI_TAG:-stable}' is an alias for 'iterm2-themes@${WEBI_VERSION:-}'"
+WEBI_HOST=${WEBI_HOST:-"https://webinstall.dev"}
+curl -fsSL "$WEBI_HOST/iterm2-themes@${WEBI_VERSION:-}" | bash
diff --git a/iterm-themes/install.sh b/iterm-themes/install.sh
new file mode 100644 (file)
index 0000000..7a675e7
--- /dev/null
@@ -0,0 +1,10 @@
+# title: iterm-themes (iterm2-themes alias)
+# homepage: https://webinstall.dev/iterm2-themes
+# tagline: Alias for https://webinstall.dev/iterm2-themes
+# alias: iterm2-themes
+# description: |
+#   See https://webinstall.dev/iterm2-themes
+
+echo "'iterm-themes@${WEBI_TAG:-stable}' is an alias for 'iterm2-themes@${WEBI_VERSION:-}'"
+WEBI_HOST=${WEBI_HOST:-"https://webinstall.dev"}
+curl -fsSL "$WEBI_HOST/iterm2-themes@${WEBI_VERSION:-}" | bash
diff --git a/iterm2-color-schemes/install.sh b/iterm2-color-schemes/install.sh
new file mode 100644 (file)
index 0000000..fa9233d
--- /dev/null
@@ -0,0 +1,10 @@
+# title: iterm2-color-schemes (iterm2-themes alias)
+# homepage: https://webinstall.dev/iterm2-themes
+# tagline: Alias for https://webinstall.dev/iterm2-themes
+# alias: iterm2-themes
+# description: |
+#   See https://webinstall.dev/iterm2-themes
+
+echo "'iterm2-color-schemes@${WEBI_TAG:-stable}' is an alias for 'iterm2-themes@${WEBI_VERSION:-}'"
+WEBI_HOST=${WEBI_HOST:-"https://webinstall.dev"}
+curl -fsSL "$WEBI_HOST/iterm2-themes@${WEBI_VERSION:-}" | bash
diff --git a/iterm2-themes/README.md b/iterm2-themes/README.md
new file mode 100644 (file)
index 0000000..7cb3186
--- /dev/null
@@ -0,0 +1,88 @@
+---
+title: iTerm2 Themes
+homepage: https://iterm2colorschemes.com/
+tagline: |
+  iTerm2 Themes: the best color schemes for iTerm2 (the macOS terminal that does amazing things).
+---
+
+## Cheat Sheet
+
+> There are [216+ color schemes](https://iterm2colorschemes.com/) for
+> [iTerm2](./iterm2). Here's my shortlist. I chose them because they are easy on
+> the eyes and distinct.
+
+![](https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/tomorrow_night.png)
+
+The installer will download them to `~/Downloads/webi/iterm2-themes`
+
+```txt
+~/Downloads/webi/iterm2-themes/Tomorrow\ Night.itermcolors
+~/Downloads/webi/iterm2-themes/Firewatch.itermcolors
+~/Downloads/webi/iterm2-themes/Dracula.itermcolors
+~/Downloads/webi/iterm2-themes/Elemental.itermcolors
+~/Downloads/webi/iterm2-themes/Ubuntu.itermcolors
+~/Downloads/webi/iterm2-themes/cyberpunk.itermcolors
+~/Downloads/webi/iterm2-themes/Hivacruz.itermcolors
+~/Downloads/webi/iterm2-themes/ToyChest.itermcolors
+```
+
+It's up to you to open them, and then iTerm2 will ask you to confirm.
+
+```bash
+open ~/Downloads/webi/iterm2-themes/*.itermcolors
+```
+
+### Previews
+
+Two-finger click "Save Link As" (or similar) to download.
+
+- <a href="/packages/iterm2/schemes/Tomorrow%20Night.itermcolors" download>Tomorrow
+  Night</a>
+  ![](https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/tomorrow_night.png)
+- <a href="/packages/iterm2/schemes/Firewatch.itermcolors" download>Firewatch</a>
+  ![](https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/firewatch.png)
+- <a href="/packages/iterm2/schemes/Dracula.itermcolors" download>Dracula</a>
+  ![](https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/dracula.png)
+- <a href="/packages/iterm2/schemes/Elemental.itermcolors" download>Elemental</a>
+  ![](https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/elemental.png)
+- <a href="/packages/iterm2/schemes/Ubuntu.itermcolors" download>Ubuntu</a>
+  ![](https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/ubuntu.png)
+- <a href="/packages/iterm2/schemes/cyberpunk.itermcolors" download>cyberpunk</a>
+  ![](https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/cyberpunk.png)
+- <a href="/packages/iterm2/schemes/Hivacruz.itermcolors" download>Hivacruz</a>
+  ![](https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/hivacruz.png)
+- <a href="/packages/iterm2/schemes/Builtin%20Solarized%20Dark.itermcolors" download>Builtin
+  Solarized Dark</a>
+  ![](https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/builtin_solarized_dark.png)
+- <a href="/packages/iterm2/schemes/ToyChest.itermcolors" download>ToyChest</a>
+  (not for the colorblind)
+  ![](https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/toy_chest.png)
+
+<!--
+Other considerations:
+Grape
+-->
+
+If you're using [fish](https://webinstall.dev/fish) (as you should be!), be sure
+to set your shell color theme to the same or similar:
+
+```bash
+fish_config colors
+```
+
+### How to set up profile switching
+
+I suggest using different profiles:
+
+- Default (no matching hosts)
+- Local (matching my local `hostname`)
+- Remote (matching `app@` for VPSes and cloud environments)
+- Prod (matching specific `app@hostname`s for production systems)
+- Root (matching `root@`)
+
+You need to "Install Shell Integration" on each host for profile switching to
+work.
+
+!["Install iTerm2 Shell Integrations"](https://i.imgur.com/PRuQViC.png)
+
+!["Enable iTerm2 Profile Switching"](https://i.imgur.com/syRmikE.png)
diff --git a/iterm2-themes/install.sh b/iterm2-themes/install.sh
new file mode 100644 (file)
index 0000000..b41961c
--- /dev/null
@@ -0,0 +1,52 @@
+#!/bin/bash
+set -u
+set -e
+
+function __install_iterm2_color_schemes() {
+    WEBI_HOST=${WEBI_HOST:-https://webinstall.dev}
+
+    echo ''
+    mkdir -p ~/Downloads/webi/iterm2-themes/
+
+    echo 'Downloading themes ...'
+    echo ''
+    curl -sSL "${WEBI_HOST}"'/packages/iterm2/schemes/Tomorrow%20Night.itermcolors' \
+        -o ~/Downloads/webi/iterm2-themes/'Tomorrow Night.itermcolors'
+    echo '    Tomorrow Night'
+
+    curl -sSL "${WEBI_HOST}"'/packages/iterm2/schemes/Firewatch.itermcolors' \
+        -o ~/Downloads/webi/iterm2-themes/'Firewatch.itermcolors'
+    echo '    Firewatch'
+
+    curl -sSL "${WEBI_HOST}"'/packages/iterm2/schemes/Dracula.itermcolors' \
+        -o ~/Downloads/webi/iterm2-themes/'Dracula.itermcolors'
+    echo '    Dracula'
+
+    curl -sSL "${WEBI_HOST}"'/packages/iterm2/schemes/Elemental.itermcolors' \
+        -o ~/Downloads/webi/iterm2-themes/'Elemental.itermcolors'
+    echo '    Elemental'
+
+    curl -sSL "${WEBI_HOST}"'/packages/iterm2/schemes/Ubuntu.itermcolors' \
+        -o ~/Downloads/webi/iterm2-themes/'Ubuntu.itermcolors'
+    echo '    Ubuntu'
+
+    curl -sSL "${WEBI_HOST}"'/packages/iterm2/schemes/cyberpunk.itermcolors' \
+        -o ~/Downloads/webi/iterm2-themes/'cyberpunk.itermcolors'
+    echo '    cyberpunk'
+
+    curl -sSL "${WEBI_HOST}"'/packages/iterm2/schemes/Hivacruz.itermcolors' \
+        -o ~/Downloads/webi/iterm2-themes/'Hivacruz.itermcolors'
+    echo '    Hivacruz'
+
+    curl -sSL "${WEBI_HOST}"'/packages/iterm2/schemes/ToyChest.itermcolors' \
+        -o ~/Downloads/webi/iterm2-themes/'ToyChest.itermcolors'
+    echo '    ToyChest'
+
+    echo ''
+    echo 'IMPORTANT: You must open the themes to install them:'
+    echo ''
+    echo '    open ~/Downloads/webi/iterm2-themes/*.itermcolors'
+    echo ''
+}
+
+__install_iterm2_color_schemes