Repository navigation
65 lines (62 loc) · 2.06 KB
/
Copy pathpush.yml
File metadata and controls
65 lines (62 loc) · 2.06 KB
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
name: Push to master
on:
push:
branches: [ master ]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
r-version: [ '4.5.0' ]
os: [macos-latest, windows-latest]
arch: [ x64, arm64 ]
exclude:
- os: windows-latest
arch: arm64
steps:
- uses: actions/checkout@master
- uses: r-lib/actions/setup-r@v2
name: Setup R
with:
r-version: ${{ matrix.r-version }}
- name: Set R_HOME environment variable
run: |
if [ "$RUNNER_OS" == "Linux" ]; then
mkdir -p ~/.local/lib/R
echo "R_LIBS_USER=~/.local/lib/R" >> "$GITHUB_ENV"
echo "R_HOME=$(R RHOME)" >> "$GITHUB_ENV"
elif [ "$RUNNER_OS" == "macOS" ]; then
echo "R_HOME=$(R RHOME)" >> "$GITHUB_ENV"
elif [ "$RUNNER_OS" == "Windows" ]; then
echo "R_HOME=$(R RHOME)" >> "$GITHUB_ENV"
else
echo "$RUNNER_OS not supported"
exit 1
fi
shell: bash
- name: Install R package dependencies
run: Rscript -e "install.packages(c('tseries', 'zoo', 'ggplot2', 'svglite'), repos = 'https://cran.r-project.org')"
shell: bash
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 10.0.100
- name: Restore tool dependencies
run: dotnet tool restore
- name: Restore paket dependencies
run: dotnet paket restore
- name: Restore dependencies
run: dotnet restore RProvider.sln
- name: Build
run: dotnet fsi build.fsx
- name: Deploy documentation from master
if: matrix.os == 'macos-latest'
uses: peaceiris/actions-gh-pages@v3
with:
personal_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./output
publish_branch: gh-pages
force_orphan: true
- name: Publish NuGets (if this version not published before)
if: matrix.os == 'macos-latest'
run: dotnet nuget push bin/*.nupkg -s https://api.nuget.org/v3/index.json -k ${{ secrets.NUGETKEY }} --skip-duplicate