-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaction.yml
51 lines (41 loc) · 1.53 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: 'Setup git-annex'
description: 'Installs git-annex on Linux, macOS, or Windows'
branding:
icon: 'package'
color: 'purple'
runs:
using: 'composite'
steps:
- name: Linux
if: runner.os == 'Linux'
run: |
echo Downloading git-annex
curl --max-time 120 --silent --output git-annex-standalone-amd64.tar.gz https://downloads.kitenet.net/git-annex/linux/current/git-annex-standalone-amd64.tar.gz
echo Installing git-annex
mkdir -p "$(systemd-path user-binaries)"
tar --extract --gzip --strip-components 1 --file=git-annex-standalone-amd64.tar.gz --directory "$(systemd-path user-binaries)"
echo Removing download
rm git-annex-standalone-amd64.tar.gz
echo Success
git version
git annex version
shell: bash
- name: macOS
if: runner.os == 'macOS'
run: |
brew update
brew install git-annex
git annex version
shell: bash
- name: Windows
if: runner.os == 'Windows'
run: |
echo 'Downloading git-annex'
Invoke-WebRequest -TimeoutSec 120 -OutFile git-annex-installer.exe -Uri https://downloads.kitenet.net/git-annex/windows/current/git-annex-installer.exe
echo 'Installing git-annex'
Start-Process -Wait -Verb RunAs -FilePath git-annex-installer.exe -ArgumentList /S
echo 'Removing download'
Remove-Item -Path git-annex-installer.exe
echo 'Success'
git annex version
shell: powershell