Skip to content

Commit

Permalink
ci(.github): prepare new pipelines for migration from ADO (#33202)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hotell authored Nov 6, 2024
1 parent c16cd22 commit 2aa7c97
Show file tree
Hide file tree
Showing 14 changed files with 64 additions and 50 deletions.
1 change: 1 addition & 0 deletions .github/actions/run-publish-vr-screenshot/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ runs:
uses: actions/upload-artifact@v4
with:
name: vrscreenshot${{ inputs.fluentVersion }}
retention-days: 1
path: screenshots

# ==========================================================
Expand Down
30 changes: 29 additions & 1 deletion .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1 +1,29 @@
'Type: RFC': 'rfcs/**/*.md'
'Type: RFC':
- changed-files:
- any-glob-to-any-file: 'docs/react-v9/contributing/rfcs/**'

'CI':
- changed-files:
- any-glob-to-any-file:
- '.github/**'
- '.devops/**'
- 'azure-pipelines*.yml'

'NX: core':
- changed-files:
- any-glob-to-any-file:
- 'tools/workspace-plugin/**'
- 'nx.json'
- '**/project.json'

'NX: workspace generators':
- changed-files:
- any-glob-to-any-file: 'tools/workspace-plugin/src/generators/*'

'NX: workspace executors':
- changed-files:
- any-glob-to-any-file: 'tools/workspace-plugin/src/executors/*'

'NX: workspace eslint-rules':
- changed-files:
- any-glob-to-any-file: 'tools/eslint-rules/*'
14 changes: 3 additions & 11 deletions .github/workflows/bundle-size-base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,29 +10,21 @@ concurrency:
cancel-in-progress: true

env:
NX_PARALLEL: 6 # ubuntu-latest = 4-core CPU / 16 GB of RAM | macos-14-xlarge (arm) = 6-core CPU / 14 GB of RAM
NX_PARALLEL: 4 # ubuntu-latest = 4-core CPU / 16 GB of RAM | macos-14-xlarge (arm) = 6-core CPU / 14 GB of RAM
NX_PREFER_TS_NODE: true
NX_VERBOSE_LOGGING: true

BROWSERSLIST_IGNORE_OLD_DATA: true

jobs:
bundle-size-base:
runs-on: macos-14-xlarge
# TODO: use macos-14-xlarge (arm) for faster builds once https://github.com/Azure/cli/issues/172 will be fixed
runs-on: ubuntu-latest
permissions:
contents: 'read'
actions: 'read'
id-token: 'write'

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Derive appropriate SHAs for base and head for `nx affected` commands
uses: nrwl/nx-set-shas@v4
with:
main-branch-name: 'master'

- uses: actions/setup-node@v4
with:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/bundle-size.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ jobs:
- uses: actions/upload-artifact@v4
with:
name: monosize-report
retention-days: 1
if-no-files-found: error
path: |
monosize-report.md
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/check-packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ jobs:
dependency-deduplication:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: 20.x
cache: 'yarn'
Expand Down Expand Up @@ -38,15 +38,15 @@ jobs:
dependency-mismatches:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: 20.x

- uses: actions/github-script@v6
- uses: actions/github-script@v7
with:
script: |
const syncpackVersion = require('./package.json').devDependencies.syncpack;
Expand All @@ -64,15 +64,15 @@ jobs:
change-files:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: 20.x

- uses: actions/github-script@v6
- uses: actions/github-script@v7
with:
script: |
const beachballVersion = require('./package.json').devDependencies.beachball;
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/docsite-publish-ghpages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
status: ${{ steps.verify-react-components-changed.outputs.any_changed == 'true' || github.event_name == 'workflow_dispatch' }}

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
name: Checkout [master]

- name: Verify react-compoenents has changed
Expand All @@ -31,11 +31,11 @@ jobs:
if: needs.check.outputs.status == 'true'

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0

- uses: actions/setup-node@v3
- uses: actions/setup-node@v4
with:
node-version: 20.x
cache: 'yarn'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/issues.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ jobs:
issues: write

steps:
- uses: actions/checkout@v3
- uses: actions/github-script@v6
- uses: actions/checkout@v4
- uses: actions/github-script@v7
with:
script: |
const config = require('./.github/triage-bot.config.json');
Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/pr-housekeeping.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,12 @@ jobs:
label:
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@v3
- uses: actions/labeler@v5
with:
repo-token: '${{ secrets.GITHUB_TOKEN }}'
sync-labels: true
configuration-path: .github/labeler.yml

assign-to-current-milestone:
runs-on: ubuntu-latest
steps:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/pr-website-deploy-comment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ jobs:
if: ${{ github.event.workflow_run.event == 'pull_request' && github.event.workflow_run.conclusion == 'success' }}
permissions:
pull-requests: write
statuses: write
steps:
- uses: actions/checkout@v4

Expand Down
17 changes: 2 additions & 15 deletions .github/workflows/pr-website-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,21 +14,6 @@ env:

BROWSERSLIST_IGNORE_OLD_DATA: true

# Deploy host and URL
# DEPLOY_BASE_PATH: ''
DEPLOY_HOST: fluentuipr.z22.web.core.windows.net
DEPLOY_URL: https://fluentuipr.z22.web.core.windows.net/${{ github.event.pull_request.number || github.ref_name }}
# DEPLOY_BASE_PATH: pull/${{github.event.pull_request.number}}
DEPLOY_BASE_PATH: ${{ github.event.pull_request.number != '' && format('pull/{0}', github.event.pull_request.number) || format('heads/{0}', github.ref_name) }}

IS_PR: ${{ github.event_name == 'pull_request' }}
TARGET_BRANCH: ${{ github.event.pull_request.base.ref || '' }}

# GitHub Secrets for Azure access
# This service principal ("subscription" is a misleading name) only has access to the fluentuipr storage account
AZURE_SUBSCRIPTION: Azure PR deploy - NEW
AZURE_STORAGE: fluentuipr

jobs:
bundle:
runs-on: macos-14-xlarge
Expand Down Expand Up @@ -66,6 +51,7 @@ jobs:
- uses: actions/upload-artifact@v4
with:
name: pr-website-artifacts
retention-days: 1
if-no-files-found: error
path: |
apps/pr-deploy-site/dist/
Expand All @@ -75,6 +61,7 @@ jobs:
- uses: actions/upload-artifact@v4
with:
name: pr-number
retention-days: 1
if-no-files-found: error
path: |
pr.txt
6 changes: 0 additions & 6 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ env:

DEPLOY_HOST: fluentuipr.z22.web.core.windows.net
DEPLOY_URL: https://fluentuipr.z22.web.core.windows.net/${{ github.event.pull_request.number || github.ref_name }}
# DEPLOY_BASE_PATH: pull/${{github.event.pull_request.number}}
DEPLOY_BASE_PATH: ${{ github.event.pull_request.number != '' && format('pull/{0}', github.event.pull_request.number) || format('heads/{0}', github.ref_name) }}

jobs:
Expand Down Expand Up @@ -116,9 +115,4 @@ jobs:
run: yarn cypress verify

- name: Cypress/Playwright E2E tests
if: github.event_name == 'pull_request'
run: yarn nx affected -t e2e --nxBail --parallel 1

- name: Cypress/Playwright E2E tests (non-PR)
if: github.event_name != 'pull_request'
run: yarn nx run-many -t e2e --nxBail --parallel 1
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "none",
"comment": "chore: resolve TS errors within web-components build",
"packageName": "@fluentui/web-components",
"email": "martinhochel@microsoft.com",
"dependentChangeType": "none"
}
4 changes: 2 additions & 2 deletions packages/web-components/src/tooltip/tooltip.ts
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ export class Tooltip extends FASTElement {
public showTooltip(delay: number = this.defaultDelay): void {
setTimeout(() => {
this.setAttribute('aria-hidden', 'false');
// @ts-expect-error - Baseline 2024
//// @ts-expect-error - Baseline 2024
this.showPopover();
}, delay);
}
Expand All @@ -189,7 +189,7 @@ export class Tooltip extends FASTElement {
}

this.setAttribute('aria-hidden', 'true');
// @ts-expect-error - Baseline 2024
//// @ts-expect-error - Baseline 2024
this.hidePopover();
}, delay);
}
Expand Down
2 changes: 1 addition & 1 deletion scripts/triage-bot/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/github-script@v6
- uses: actions/github-script@v7
with:
script: |
const config = require('./.github/triage-bot.config.json');
Expand Down

0 comments on commit 2aa7c97

Please sign in to comment.