Skip to content

Commit

Permalink
Define JIT format jobs as GitHub Actions instead of AzDO jobs (#103846)
Browse files Browse the repository at this point in the history
  • Loading branch information
jkoritzinsky authored Jun 24, 2024
1 parent 7df87e8 commit 98e7570
Show file tree
Hide file tree
Showing 4 changed files with 55 additions and 90 deletions.
55 changes: 55 additions & 0 deletions .github/workflows/jit-format.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
on:
pull_request:
paths:
- 'src/coreclr/jit/**'
branches: [ main ]

jobs:
format:
strategy:
matrix:
os:
- name: linux
image: ubuntu-latest
container: mcr.microsoft.com/dotnet-buildtools/prereqs:azurelinux-3.0-cross-amd64-net9.0
extension: '.sh'
cross: '--cross'
- name: windows
image: windows-latest
extension: '.cmd'
cross: ''
runs-on: ${{ matrix.os.image }}
container: ${{ matrix.os.container }}
steps:
- name: Checkout jitutils
uses: actions/checkout@v4
with:
path: jitutils
repository: dotnet/jitutils
ref: main
token: ${{ secrets.GITHUB_TOKEN }}
- name: Install .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: '8.0.x'
- name: Build jitutils
run: |
cd jitutils
./bootstrap${{ matrix.os.extension }}
- name: Checkout runtime
uses: actions/checkout@v4
with:
path: runtime
- name: Install Python
uses: actions/setup-python@v5

- name: Run jitformat.py
run: |
python3 runtime/src/coreclr/scripts/jitformat.py --jitutils jitutils -r ${{ github.workspace }}/runtime -o ${{ matrix.os.name }} -a x64 ${{ matrix.os.cross }}
- name: Publish format.patch
uses: actions/upload-artifact@v2
with:
path: format.patch
name: format.${{matrix.os.name}}.patch
if: failure()
3 changes: 0 additions & 3 deletions eng/pipelines/common/evaluate-default-paths.yml
Original file line number Diff line number Diff line change
Expand Up @@ -202,9 +202,6 @@ jobs:
- src/coreclr/jit/*
- src/coreclr/pal/*
- src/coreclr/vm/*
- subset: coreclr_jit
include:
- src/coreclr/jit/*

#
# ** WASM **
Expand Down
66 changes: 0 additions & 66 deletions eng/pipelines/coreclr/templates/format-job.yml

This file was deleted.

21 changes: 0 additions & 21 deletions eng/pipelines/runtime.yml
Original file line number Diff line number Diff line change
Expand Up @@ -442,27 +442,6 @@ extends:
eq(stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_runtimetests.containsChange'], true),
eq(variables['isRollingBuild'], true))
#
# Build CoreCLR Formatting Job
# Only when CoreCLR is changed, and only in the 'main' branch (no release branches;
# both Rolling and PR builds).
#
- template: /eng/pipelines/common/platform-matrix.yml
parameters:
jobTemplate: /eng/pipelines/coreclr/templates/format-job.yml
platforms:
- linux_x64
- windows_x64
jobParameters:
condition: >-
and(
or(
eq(variables['Build.SourceBranchName'], 'main'),
eq(variables['System.PullRequest.TargetBranch'], 'main')),
or(
eq(stageDependencies.EvaluatePaths.evaluate_paths.outputs['SetPathVars_coreclr_jit.containsChange'], true),
eq(variables['isRollingBuild'], true)))
#
# Build CoreCLR with no R2R
#
Expand Down

0 comments on commit 98e7570

Please sign in to comment.