Skip to content

Commit 887c5e1

Browse files
committed
azure pipelines -> github actions
1 parent 848a73e commit 887c5e1

File tree

8 files changed

+69
-79
lines changed

8 files changed

+69
-79
lines changed
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
inputs:
2+
env:
3+
default: ${{ matrix.env }}
4+
5+
runs:
6+
using: composite
7+
steps:
8+
- name: setup (windows)
9+
shell: bash
10+
if: runner.os == 'Windows'
11+
run: |
12+
set -x
13+
14+
echo 'TEMP=C:\TEMP' >> "$GITHUB_ENV"
15+
16+
echo "$CONDA\Scripts" >> "$GITHUB_PATH"
17+
18+
echo 'C:\Strawberry\perl\bin' >> "$GITHUB_PATH"
19+
echo 'C:\Strawberry\perl\site\bin' >> "$GITHUB_PATH"
20+
echo 'C:\Strawberry\c\bin' >> "$GITHUB_PATH"
21+
22+
testing/get-dart.sh
23+
pwsh testing/get-r.ps1
24+
- name: setup (linux)
25+
shell: bash
26+
if: runner.os == 'Linux'
27+
run: |
28+
set -x
29+
30+
sudo apt-get update
31+
sudo apt-get install -y --no-install-recommends \
32+
lua5.3 \
33+
liblua5.3-dev \
34+
luarocks \
35+
r-base
36+
37+
testing/get-coursier.sh
38+
testing/get-dart.sh
39+
testing/get-swift.sh
40+
- uses: asottile/workflows/.github/actions/latest-git@v1.2.0
41+
if: inputs.env == 'py38' && runner.os == 'Linux'

.github/workflows/main.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: main
2+
3+
on:
4+
push:
5+
branches: [main, test-me-*]
6+
tags:
7+
pull_request:
8+
9+
concurrency:
10+
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
11+
cancel-in-progress: true
12+
13+
jobs:
14+
main-windows:
15+
uses: asottile/workflows/.github/workflows/tox.yml@v1.2.0
16+
with:
17+
env: '["py38"]'
18+
os: windows-latest
19+
main-linux:
20+
uses: asottile/workflows/.github/workflows/tox.yml@v1.2.0
21+
with:
22+
env: '["py38", "py39", "py310"]'
23+
os: ubuntu-latest

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
[![Build Status](https://dev.azure.com/asottile/asottile/_apis/build/status/pre-commit.pre-commit?branchName=main)](https://dev.azure.com/asottile/asottile/_build/latest?definitionId=21&branchName=main)
2-
[![Azure DevOps coverage](https://img.shields.io/azure-devops/coverage/asottile/asottile/21/main.svg)](https://dev.azure.com/asottile/asottile/_build/latest?definitionId=21&branchName=main)
1+
[![build status](https://github.com/pre-commit/pre-commit/actions/workflows/main.yml/badge.svg)](https://github.com/pre-commit/pre-commit/actions/workflows/main.yml)
32
[![pre-commit.ci status](https://results.pre-commit.ci/badge/github/pre-commit/pre-commit/main.svg)](https://results.pre-commit.ci/latest/github/pre-commit/pre-commit/main)
43

54
## pre-commit

azure-pipelines.yml

Lines changed: 0 additions & 68 deletions
This file was deleted.

testing/get-coursier.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@ curl --location --silent --output "$ARTIFACT" "$COURSIER_URL"
1212
echo "$COURSIER_HASH $ARTIFACT" | sha256sum --check
1313
chmod ugo+x /tmp/coursier/cs
1414

15-
echo '##vso[task.prependpath]/tmp/coursier'
15+
echo '/tmp/coursier' >> "$GITHUB_PATH"

testing/get-dart.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ VERSION=2.13.4
55

66
if [ "$OSTYPE" = msys ]; then
77
URL="https://storage.googleapis.com/dart-archive/channels/stable/release/${VERSION}/sdk/dartsdk-windows-x64-release.zip"
8-
echo "##vso[task.prependpath]$(cygpath -w /tmp/dart-sdk/bin)"
8+
cygpath -w /tmp/dart-sdk/bin >> "$GITHUB_PATH"
99
else
1010
URL="https://storage.googleapis.com/dart-archive/channels/stable/release/${VERSION}/sdk/dartsdk-linux-x64-release.zip"
11-
echo '##vso[task.prependpath]/tmp/dart-sdk/bin'
11+
echo '/tmp/dart-sdk/bin' >> "$GITHUB_PATH"
1212
fi
1313

1414
curl --silent --location --output /tmp/dart.zip "$URL"

testing/get-lua.sh

Lines changed: 0 additions & 5 deletions
This file was deleted.

testing/get-swift.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,4 @@ fi
2626
mkdir -p /tmp/swift
2727
tar -xf "$TGZ" --strip 1 --directory /tmp/swift
2828

29-
echo '##vso[task.prependpath]/tmp/swift/usr/bin'
29+
echo '/tmp/swift/usr/bin' >> "$GITHUB_PATH"

0 commit comments

Comments
 (0)