Skip to content

Commit 01fbfc1

Browse files
committed
feat(teraminal): Add GitHub Copilot installer
Signed-off-by: Mateusz Łoskot <mateusz@loskot.net>
1 parent 6ae46ef commit 01fbfc1

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

install/terminal/app-copilot.sh

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
#!/bin/bash
2+
source ~/.dotfiles/err.sh "${BASH_SOURCE[0]}"
3+
source ~/.dotfiles/log.sh "${BASH_SOURCE[0]}"
4+
5+
echolog "Installing copilot"
6+
7+
VERSION=$(curl -s "https://api.github.com/repos/github/copilot-cli/releases/latest" | grep -Po '"tag_name":\s*"v?\K[0-9.]+')
8+
echolog "Downloading copilot ${VERSION}"
9+
10+
curl -fsSL https://gh.io/copilot-install | VERSION="v${VERSION}" PREFIX="$HOME/.local" bash
11+
12+
installed_cmd="$(command -v copilot)"
13+
installed_ver="$(copilot --version | head -n 1)"
14+
echolog "Installed ${installed_cmd} ${installed_ver}"

0 commit comments

Comments
 (0)