Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

ci: Use GitHub context for artifact name (#53559)

Finn Evers60a8b6f0034b
diff --git a/.github/workflows/compliance_check.yml b/.github/workflows/compliance_check.yml
index e74c38ec5d3..144185f95ba 100644
--- a/.github/workflows/compliance_check.yml
+++ b/.github/workflows/compliance_check.yml
@@ -42,12 +42,12 @@ jobs:
GITHUB_APP_KEY: ${{ secrets.ZED_ZIPPY_APP_PRIVATE_KEY }}
LATEST_TAG: ${{ steps.determine-version.outputs.tag }}
continue-on-error: true
- - name: '@actions/upload-artifact compliance-report-${GITHUB_REF_NAME}.md'
+ - name: '@actions/upload-artifact compliance-report-${{ github.ref_name }}.md'
if: always()
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4
with:
- name: compliance-report-${GITHUB_REF_NAME}.md
- path: compliance-report-${GITHUB_REF_NAME}.md
+ name: compliance-report-${{ github.ref_name }}.md
+ path: compliance-report-${{ github.ref_name }}.md
if-no-files-found: error
- name: send_compliance_slack_notification
if: always()
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 17178ab3054..80819559208 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -314,12 +314,12 @@ jobs:
GITHUB_APP_ID: ${{ secrets.ZED_ZIPPY_APP_ID }}
GITHUB_APP_KEY: ${{ secrets.ZED_ZIPPY_APP_PRIVATE_KEY }}
continue-on-error: true
- - name: '@actions/upload-artifact compliance-report-${GITHUB_REF_NAME}.md'
+ - name: '@actions/upload-artifact compliance-report-${{ github.ref_name }}.md'
if: always()
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4
with:
- name: compliance-report-${GITHUB_REF_NAME}.md
- path: compliance-report-${GITHUB_REF_NAME}.md
+ name: compliance-report-${{ github.ref_name }}.md
+ path: compliance-report-${{ github.ref_name }}.md
if-no-files-found: error
- name: send_compliance_slack_notification
if: always()
@@ -682,12 +682,12 @@ jobs:
env:
GITHUB_APP_ID: ${{ secrets.ZED_ZIPPY_APP_ID }}
GITHUB_APP_KEY: ${{ secrets.ZED_ZIPPY_APP_PRIVATE_KEY }}
- - name: '@actions/upload-artifact compliance-report-${GITHUB_REF_NAME}.md'
+ - name: '@actions/upload-artifact compliance-report-${{ github.ref_name }}.md'
if: always()
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4
with:
- name: compliance-report-${GITHUB_REF_NAME}.md
- path: compliance-report-${GITHUB_REF_NAME}.md
+ name: compliance-report-${{ github.ref_name }}.md
+ path: compliance-report-${{ github.ref_name }}.md
if-no-files-found: error
overwrite: true
- name: send_compliance_slack_notification
diff --git a/tooling/xtask/src/tasks/workflows/release.rs b/tooling/xtask/src/tasks/workflows/release.rs
index d3ad064a665..e3e0fb78a86 100644
--- a/tooling/xtask/src/tasks/workflows/release.rs
+++ b/tooling/xtask/src/tasks/workflows/release.rs
@@ -158,6 +158,8 @@ pub(crate) fn create_sentry_release() -> Step<Use> {
}
pub(crate) const COMPLIANCE_REPORT_PATH: &str = "compliance-report-${GITHUB_REF_NAME}.md";
+pub(crate) const COMPLIANCE_REPORT_ARTIFACT_PATH: &str =
+ "compliance-report-${{ github.ref_name }}.md";
pub(crate) const COMPLIANCE_STEP_ID: &str = "run-compliance-check";
const NEEDS_REVIEW_PULLS_URL: &str = "https://github.com/zed-industries/zed/pulls?q=is%3Apr+is%3Aclosed+label%3A%22PR+state%3Aneeds+review%22";
@@ -206,7 +208,7 @@ pub(crate) fn add_compliance_steps(
(job, result)
}
- let upload_step = upload_artifact(COMPLIANCE_REPORT_PATH)
+ let upload_step = upload_artifact(COMPLIANCE_REPORT_ARTIFACT_PATH)
.if_condition(Expression::new("always()"))
.when(
matches!(context, ComplianceContext::Release { .. }),