Detailed changes
@@ -29,10 +29,10 @@ jobs:
node-version: '20'
cache: pnpm
cache-dependency-path: script/danger/pnpm-lock.yaml
- - name: danger::install_deps
+ - name: danger::danger_job::install_deps
run: pnpm install --dir script/danger
shell: bash -euxo pipefail {0}
- - name: danger::run
+ - name: danger::danger_job::run
run: pnpm run --dir script/danger danger ci
shell: bash -euxo pipefail {0}
env:
@@ -1,97 +0,0 @@
-# Generated from xtask::workflows::nix_build
-# Rebuild with `cargo xtask workflows`.
-name: nix_build
-env:
- CARGO_TERM_COLOR: always
- RUST_BACKTRACE: '1'
- CARGO_INCREMENTAL: '0'
-on:
- pull_request:
- branches:
- - '**'
- paths:
- - nix/**
- - flake.*
- - Cargo.*
- - rust-toolchain.toml
- - .cargo/config.toml
- push:
- branches:
- - main
- - v[0-9]+.[0-9]+.x
- paths:
- - nix/**
- - flake.*
- - Cargo.*
- - rust-toolchain.toml
- - .cargo/config.toml
- workflow_call: {}
-jobs:
- build_nix_linux_x86_64:
- if: github.repository_owner == 'zed-industries'
- runs-on: namespace-profile-32x64-ubuntu-2004
- env:
- ZED_CLIENT_CHECKSUM_SEED: ${{ secrets.ZED_CLIENT_CHECKSUM_SEED }}
- ZED_MINIDUMP_ENDPOINT: ${{ secrets.ZED_SENTRY_MINIDUMP_ENDPOINT }}
- ZED_CLOUD_PROVIDER_ADDITIONAL_MODELS_JSON: ${{ secrets.ZED_CLOUD_PROVIDER_ADDITIONAL_MODELS_JSON }}
- GIT_LFS_SKIP_SMUDGE: '1'
- steps:
- - name: steps::checkout_repo
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- with:
- clean: false
- - name: nix_build::install_nix
- uses: cachix/install-nix-action@02a151ada4993995686f9ed4f1be7cfbb229e56f
- with:
- github_access_token: ${{ secrets.GITHUB_TOKEN }}
- - name: nix_build::cachix_action
- uses: cachix/cachix-action@0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad
- with:
- name: zed
- authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
- cachixArgs: -v
- pushFilter: -zed-editor-[0-9.]*-nightly
- - name: nix_build::build
- run: nix build .#debug -L --accept-flake-config
- shell: bash -euxo pipefail {0}
- timeout-minutes: 60
- continue-on-error: true
- build_nix_mac_aarch64:
- if: github.repository_owner == 'zed-industries'
- runs-on: self-mini-macos
- env:
- ZED_CLIENT_CHECKSUM_SEED: ${{ secrets.ZED_CLIENT_CHECKSUM_SEED }}
- ZED_MINIDUMP_ENDPOINT: ${{ secrets.ZED_SENTRY_MINIDUMP_ENDPOINT }}
- ZED_CLOUD_PROVIDER_ADDITIONAL_MODELS_JSON: ${{ secrets.ZED_CLOUD_PROVIDER_ADDITIONAL_MODELS_JSON }}
- GIT_LFS_SKIP_SMUDGE: '1'
- steps:
- - name: steps::checkout_repo
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- with:
- clean: false
- - name: nix_build::set_path
- run: |
- echo "/nix/var/nix/profiles/default/bin" >> "$GITHUB_PATH"
- echo "/Users/administrator/.nix-profile/bin" >> "$GITHUB_PATH"
- shell: bash -euxo pipefail {0}
- - name: nix_build::cachix_action
- uses: cachix/cachix-action@0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad
- with:
- name: zed
- authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
- cachixArgs: -v
- pushFilter: -zed-editor-[0-9.]*-nightly
- - name: nix_build::build
- run: nix build .#debug -L --accept-flake-config
- shell: bash -euxo pipefail {0}
- - name: nix_build::limit_store
- run: |-
- if [ "$(du -sm /nix/store | cut -f1)" -gt 50000 ]; then
- nix-collect-garbage -d || true
- fi
- shell: bash -euxo pipefail {0}
- timeout-minutes: 60
- continue-on-error: true
-concurrency:
- group: ${{ github.workflow }}-${{ github.ref_name }}-${{ github.ref_name == 'main' && github.sha || 'anysha' }}
- cancel-in-progress: true
@@ -467,7 +467,7 @@ jobs:
shell: bash -euxo pipefail {0}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- - name: release::create_sentry_release
+ - name: release::auto_release_preview::create_sentry_release
uses: getsentry/action-release@526942b68292201ac6bbb99b9a0747d4abee354c
with:
environment: production
@@ -201,9 +201,6 @@ jobs:
uses: matbour/setup-sentry-cli@3e938c54b3018bdd019973689ef984e033b0454b
with:
token: ${{ secrets.SENTRY_AUTH_TOKEN }}
- - name: release_nightly::add_rust_to_path
- run: echo "$HOME/.cargo/bin" >> "$GITHUB_PATH"
- shell: bash -euxo pipefail {0}
- name: ./script/linux
run: ./script/linux
shell: bash -euxo pipefail {0}
@@ -242,9 +239,6 @@ jobs:
uses: matbour/setup-sentry-cli@3e938c54b3018bdd019973689ef984e033b0454b
with:
token: ${{ secrets.SENTRY_AUTH_TOKEN }}
- - name: release_nightly::add_rust_to_path
- run: echo "$HOME/.cargo/bin" >> "$GITHUB_PATH"
- shell: bash -euxo pipefail {0}
- name: ./script/linux
run: ./script/linux
shell: bash -euxo pipefail {0}
@@ -298,11 +292,11 @@ jobs:
"nightly" | Set-Content -Path "crates/zed/RELEASE_CHANNEL"
shell: pwsh
working-directory: ${{ env.ZED_WORKSPACE }}
- - name: release_nightly::build_zed_installer
+ - name: run_bundling::bundle_windows
run: script/bundle-windows.ps1 -Architecture x86_64
shell: pwsh
working-directory: ${{ env.ZED_WORKSPACE }}
- - name: release_nightly::upload_zed_nightly_windows
+ - name: release_nightly::upload_zed_nightly
run: script/upload-nightly.ps1 -Architecture x86_64
shell: pwsh
working-directory: ${{ env.ZED_WORKSPACE }}
@@ -340,11 +334,11 @@ jobs:
"nightly" | Set-Content -Path "crates/zed/RELEASE_CHANNEL"
shell: pwsh
working-directory: ${{ env.ZED_WORKSPACE }}
- - name: release_nightly::build_zed_installer
+ - name: run_bundling::bundle_windows
run: script/bundle-windows.ps1 -Architecture aarch64
shell: pwsh
working-directory: ${{ env.ZED_WORKSPACE }}
- - name: release_nightly::upload_zed_nightly_windows
+ - name: release_nightly::upload_zed_nightly
run: script/upload-nightly.ps1 -Architecture aarch64
shell: pwsh
working-directory: ${{ env.ZED_WORKSPACE }}
@@ -365,17 +359,17 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
clean: false
- - name: nix_build::install_nix
+ - name: nix_build::build_nix::install_nix
uses: cachix/install-nix-action@02a151ada4993995686f9ed4f1be7cfbb229e56f
with:
github_access_token: ${{ secrets.GITHUB_TOKEN }}
- - name: nix_build::cachix_action
+ - name: nix_build::build_nix::cachix_action
uses: cachix/cachix-action@0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad
with:
name: zed
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
cachixArgs: -v
- - name: nix_build::build
+ - name: nix_build::build_nix::build
run: nix build .#default -L --accept-flake-config
shell: bash -euxo pipefail {0}
timeout-minutes: 60
@@ -396,21 +390,21 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
clean: false
- - name: nix_build::set_path
+ - name: nix_build::build_nix::set_path
run: |
echo "/nix/var/nix/profiles/default/bin" >> "$GITHUB_PATH"
echo "/Users/administrator/.nix-profile/bin" >> "$GITHUB_PATH"
shell: bash -euxo pipefail {0}
- - name: nix_build::cachix_action
+ - name: nix_build::build_nix::cachix_action
uses: cachix/cachix-action@0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad
with:
name: zed
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
cachixArgs: -v
- - name: nix_build::build
+ - name: nix_build::build_nix::build
run: nix build .#default -L --accept-flake-config
shell: bash -euxo pipefail {0}
- - name: nix_build::limit_store
+ - name: nix_build::build_nix::limit_store
run: |-
if [ "$(du -sm /nix/store | cut -f1)" -gt 50000 ]; then
nix-collect-garbage -d || true
@@ -434,7 +428,7 @@ jobs:
with:
clean: false
fetch-depth: 0
- - name: release_nightly::update_nightly_tag
+ - name: release_nightly::update_nightly_tag_job::update_nightly_tag
run: |
if [ "$(git rev-parse nightly)" = "$(git rev-parse HEAD)" ]; then
echo "Nightly tag already points to current commit. Skipping tagging."
@@ -445,7 +439,7 @@ jobs:
git tag -f nightly
git push origin nightly --force
shell: bash -euxo pipefail {0}
- - name: release_nightly::create_sentry_release
+ - name: release_nightly::update_nightly_tag_job::create_sentry_release
uses: getsentry/action-release@526942b68292201ac6bbb99b9a0747d4abee354c
with:
environment: production
@@ -444,18 +444,18 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
clean: false
- - name: nix_build::install_nix
+ - name: nix_build::build_nix::install_nix
uses: cachix/install-nix-action@02a151ada4993995686f9ed4f1be7cfbb229e56f
with:
github_access_token: ${{ secrets.GITHUB_TOKEN }}
- - name: nix_build::cachix_action
+ - name: nix_build::build_nix::cachix_action
uses: cachix/cachix-action@0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad
with:
name: zed
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
cachixArgs: -v
pushFilter: -zed-editor-[0-9.]*-nightly
- - name: nix_build::build
+ - name: nix_build::build_nix::build
run: nix build .#debug -L --accept-flake-config
shell: bash -euxo pipefail {0}
timeout-minutes: 60
@@ -475,22 +475,22 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
with:
clean: false
- - name: nix_build::set_path
+ - name: nix_build::build_nix::set_path
run: |
echo "/nix/var/nix/profiles/default/bin" >> "$GITHUB_PATH"
echo "/Users/administrator/.nix-profile/bin" >> "$GITHUB_PATH"
shell: bash -euxo pipefail {0}
- - name: nix_build::cachix_action
+ - name: nix_build::build_nix::cachix_action
uses: cachix/cachix-action@0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad
with:
name: zed
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
cachixArgs: -v
pushFilter: -zed-editor-[0-9.]*-nightly
- - name: nix_build::build
+ - name: nix_build::build_nix::build
run: nix build .#debug -L --accept-flake-config
shell: bash -euxo pipefail {0}
- - name: nix_build::limit_store
+ - name: nix_build::build_nix::limit_store
run: |-
if [ "$(du -sm /nix/store | cut -f1)" -gt 50000 ]; then
nix-collect-garbage -d || true
@@ -1,11 +1,13 @@
use gh_workflow::*;
-use crate::tasks::workflows::steps::named;
+use crate::tasks::workflows::steps::{NamedJob, named};
use super::{runners, steps};
/// Generates the danger.yml workflow
pub fn danger() -> Workflow {
+ let danger = danger_job();
+
named::workflow()
.on(
Event::default().pull_request(PullRequest::default().add_branch("main").types([
@@ -15,39 +17,43 @@ pub fn danger() -> Workflow {
PullRequestType::Edited,
])),
)
- .add_job(
- "danger",
- Job::default()
- .cond(Expression::new(
- "github.repository_owner == 'zed-industries'",
- ))
- .runs_on(runners::LINUX_SMALL)
- .add_step(steps::checkout_repo())
- .add_step(steps::setup_pnpm())
- .add_step(
- steps::setup_node()
- .add_with(("cache", "pnpm"))
- .add_with(("cache-dependency-path", "script/danger/pnpm-lock.yaml")),
- )
- .add_step(install_deps())
- .add_step(run()),
- )
+ .add_job(danger.name, danger.job)
}
-pub fn install_deps() -> Step<Run> {
- named::bash("pnpm install --dir script/danger")
-}
+fn danger_job() -> NamedJob {
+ pub fn install_deps() -> Step<Run> {
+ named::bash("pnpm install --dir script/danger")
+ }
+
+ pub fn run() -> Step<Run> {
+ named::bash("pnpm run --dir script/danger danger ci")
+ // This GitHub token is not used, but the value needs to be here to prevent
+ // Danger from throwing an error.
+ .add_env(("GITHUB_TOKEN", "not_a_real_token"))
+ // All requests are instead proxied through an instance of
+ // https://github.com/maxdeviant/danger-proxy that allows Danger to securely
+ // authenticate with GitHub while still being able to run on PRs from forks.
+ .add_env((
+ "DANGER_GITHUB_API_BASE_URL",
+ "https://danger-proxy.fly.dev/github",
+ ))
+ }
-pub fn run() -> Step<Run> {
- named::bash("pnpm run --dir script/danger danger ci")
- // This GitHub token is not used, but the value needs to be here to prevent
- // Danger from throwing an error.
- .add_env(("GITHUB_TOKEN", "not_a_real_token"))
- // All requests are instead proxied through an instance of
- // https://github.com/maxdeviant/danger-proxy that allows Danger to securely
- // authenticate with GitHub while still being able to run on PRs from forks.
- .add_env((
- "DANGER_GITHUB_API_BASE_URL",
- "https://danger-proxy.fly.dev/github",
- ))
+ NamedJob {
+ name: "danger".to_string(),
+ job: Job::default()
+ .cond(Expression::new(
+ "github.repository_owner == 'zed-industries'",
+ ))
+ .runs_on(runners::LINUX_SMALL)
+ .add_step(steps::checkout_repo())
+ .add_step(steps::setup_pnpm())
+ .add_step(
+ steps::setup_node()
+ .add_with(("cache", "pnpm"))
+ .add_with(("cache-dependency-path", "script/danger/pnpm-lock.yaml")),
+ )
+ .add_step(install_deps())
+ .add_step(run()),
+ }
}
@@ -14,6 +14,55 @@ pub(crate) fn build_nix(
cachix_filter: Option<&str>,
deps: &[&NamedJob],
) -> NamedJob {
+ // on our macs we manually install nix. for some reason the cachix action is running
+ // under a non-login /bin/bash shell which doesn't source the proper script to add the
+ // nix profile to PATH, so we manually add them here
+ pub fn set_path() -> Step<Run> {
+ named::bash(indoc! {r#"
+ echo "/nix/var/nix/profiles/default/bin" >> "$GITHUB_PATH"
+ echo "/Users/administrator/.nix-profile/bin" >> "$GITHUB_PATH"
+ "#})
+ }
+
+ pub fn install_nix() -> Step<Use> {
+ named::uses(
+ "cachix",
+ "install-nix-action",
+ "02a151ada4993995686f9ed4f1be7cfbb229e56f", // v31
+ )
+ .add_with(("github_access_token", vars::GITHUB_TOKEN))
+ }
+
+ pub fn cachix_action(cachix_filter: Option<&str>) -> Step<Use> {
+ let mut step = named::uses(
+ "cachix",
+ "cachix-action",
+ "0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad", // v16
+ )
+ .add_with(("name", "zed"))
+ .add_with(("authToken", vars::CACHIX_AUTH_TOKEN))
+ .add_with(("cachixArgs", "-v"));
+ if let Some(cachix_filter) = cachix_filter {
+ step = step.add_with(("pushFilter", cachix_filter));
+ }
+ step
+ }
+
+ pub fn build(flake_output: &str) -> Step<Run> {
+ named::bash(&format!(
+ "nix build .#{} -L --accept-flake-config",
+ flake_output
+ ))
+ }
+
+ pub fn limit_store() -> Step<Run> {
+ named::bash(indoc! {r#"
+ if [ "$(du -sm /nix/store | cut -f1)" -gt 50000 ]; then
+ nix-collect-garbage -d || true
+ fi"#
+ })
+ }
+
let runner = match platform {
Platform::Windows => unimplemented!(),
Platform::Linux => runners::LINUX_X86_BUNDLER,
@@ -55,52 +104,3 @@ pub(crate) fn build_nix(
job,
}
}
-
-// on our macs we manually install nix. for some reason the cachix action is running
-// under a non-login /bin/bash shell which doesn't source the proper script to add the
-// nix profile to PATH, so we manually add them here
-pub fn set_path() -> Step<Run> {
- named::bash(indoc! {r#"
- echo "/nix/var/nix/profiles/default/bin" >> "$GITHUB_PATH"
- echo "/Users/administrator/.nix-profile/bin" >> "$GITHUB_PATH"
- "#})
-}
-
-pub fn install_nix() -> Step<Use> {
- named::uses(
- "cachix",
- "install-nix-action",
- "02a151ada4993995686f9ed4f1be7cfbb229e56f", // v31
- )
- .add_with(("github_access_token", vars::GITHUB_TOKEN))
-}
-
-pub fn cachix_action(cachix_filter: Option<&str>) -> Step<Use> {
- let mut step = named::uses(
- "cachix",
- "cachix-action",
- "0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad", // v16
- )
- .add_with(("name", "zed"))
- .add_with(("authToken", vars::CACHIX_AUTH_TOKEN))
- .add_with(("cachixArgs", "-v"));
- if let Some(cachix_filter) = cachix_filter {
- step = step.add_with(("pushFilter", cachix_filter));
- }
- step
-}
-
-pub fn build(flake_output: &str) -> Step<Run> {
- named::bash(&format!(
- "nix build .#{} -L --accept-flake-config",
- flake_output
- ))
-}
-
-pub fn limit_store() -> Step<Run> {
- named::bash(indoc! {r#"
- if [ "$(du -sm /nix/store | cut -f1)" -gt 50000 ]; then
- nix-collect-garbage -d || true
- fi"#
- })
-}
@@ -45,7 +45,28 @@ pub(crate) fn release() -> Workflow {
.add_job(auto_release_preview.name, auto_release_preview.job)
}
+struct ReleaseBundleJobs {
+ linux_arm64: NamedJob,
+ linux_x86_64: NamedJob,
+ mac_arm64: NamedJob,
+ mac_x86_64: NamedJob,
+ windows_arm64: NamedJob,
+ windows_x86_64: NamedJob,
+}
+
fn auto_release_preview(deps: &[&NamedJob; 1]) -> NamedJob {
+ fn create_sentry_release() -> Step<Use> {
+ named::uses(
+ "getsentry",
+ "action-release",
+ "526942b68292201ac6bbb99b9a0747d4abee354c", // v3
+ )
+ .add_env(("SENTRY_ORG", "zed-dev"))
+ .add_env(("SENTRY_PROJECT", "zed"))
+ .add_env(("SENTRY_AUTH_TOKEN", "${{ secrets.SENTRY_AUTH_TOKEN }}"))
+ .add_with(("environment", "production"))
+ }
+
named::job(
dependant_job(deps)
.runs_on(runners::LINUX_SMALL)
@@ -66,27 +87,6 @@ fn auto_release_preview(deps: &[&NamedJob; 1]) -> NamedJob {
)
}
-fn create_sentry_release() -> Step<Use> {
- named::uses(
- "getsentry",
- "action-release",
- "526942b68292201ac6bbb99b9a0747d4abee354c", // v3
- )
- .add_env(("SENTRY_ORG", "zed-dev"))
- .add_env(("SENTRY_PROJECT", "zed"))
- .add_env(("SENTRY_AUTH_TOKEN", "${{ secrets.SENTRY_AUTH_TOKEN }}"))
- .add_with(("environment", "production"))
-}
-
-struct ReleaseBundleJobs {
- linux_arm64: NamedJob,
- linux_x86_64: NamedJob,
- mac_arm64: NamedJob,
- mac_x86_64: NamedJob,
- windows_arm64: NamedJob,
- windows_x86_64: NamedJob,
-}
-
fn upload_release_assets(deps: &[&NamedJob], bundle_jobs: &ReleaseBundleJobs) -> NamedJob {
fn download_workflow_artifacts() -> Step<Use> {
named::uses(
@@ -1,6 +1,6 @@
use crate::tasks::workflows::{
nix_build::build_nix,
- run_bundling::bundle_mac,
+ run_bundling::{bundle_mac, bundle_windows},
run_tests::run_platform_tests,
runners::{Arch, Platform},
steps::NamedJob,
@@ -135,7 +135,6 @@ fn bundle_linux_nightly(arch: Arch, deps: &[&NamedJob]) -> NamedJob {
.runs_on(arch.linux_bundler())
.add_step(steps::checkout_repo())
.add_step(steps::setup_sentry())
- .add_step(add_rust_to_path())
.add_step(steps::script("./script/linux"));
// todo(ci) can we do this on arm too?
@@ -163,12 +162,37 @@ fn bundle_windows_nightly(arch: Arch, deps: &[&NamedJob]) -> NamedJob {
.add_step(steps::checkout_repo())
.add_step(steps::setup_sentry())
.add_step(set_release_channel_to_nightly(platform))
- .add_step(build_zed_installer(arch))
- .add_step(upload_zed_nightly_windows(arch)),
+ .add_step(bundle_windows(arch))
+ .add_step(upload_zed_nightly(platform, arch)),
}
}
fn update_nightly_tag_job(deps: &[&NamedJob]) -> NamedJob {
+ fn update_nightly_tag() -> Step<Run> {
+ named::bash(indoc::indoc! {r#"
+ if [ "$(git rev-parse nightly)" = "$(git rev-parse HEAD)" ]; then
+ echo "Nightly tag already points to current commit. Skipping tagging."
+ exit 0
+ fi
+ git config user.name github-actions
+ git config user.email github-actions@github.com
+ git tag -f nightly
+ git push origin nightly --force
+ "#})
+ }
+
+ fn create_sentry_release() -> Step<Use> {
+ named::uses(
+ "getsentry",
+ "action-release",
+ "526942b68292201ac6bbb99b9a0747d4abee354c", // v3
+ )
+ .add_env(("SENTRY_ORG", "zed-dev"))
+ .add_env(("SENTRY_PROJECT", "zed"))
+ .add_env(("SENTRY_AUTH_TOKEN", vars::SENTRY_AUTH_TOKEN))
+ .add_with(("environment", "production"))
+ }
+
NamedJob {
name: "update_nightly_tag".to_owned(),
job: steps::release_job(deps)
@@ -197,10 +221,6 @@ fn set_release_channel_to_nightly(platform: Platform) -> Step<Run> {
}
}
-fn add_rust_to_path() -> Step<Run> {
- named::bash(r#"echo "$HOME/.cargo/bin" >> "$GITHUB_PATH""#)
-}
-
fn upload_zed_nightly(platform: Platform, arch: Arch) -> Step<Run> {
match platform {
Platform::Linux => named::bash(&format!("script/upload-nightly linux-targz {arch}")),
@@ -214,44 +234,3 @@ fn upload_zed_nightly(platform: Platform, arch: Arch) -> Step<Run> {
}
}
}
-
-fn build_zed_installer(arch: Arch) -> Step<Run> {
- let cmd = match arch {
- Arch::X86_64 => "script/bundle-windows.ps1 -Architecture x86_64",
- Arch::ARM64 => "script/bundle-windows.ps1 -Architecture aarch64",
- };
- named::pwsh(cmd).working_directory("${{ env.ZED_WORKSPACE }}")
-}
-
-fn upload_zed_nightly_windows(arch: Arch) -> Step<Run> {
- let cmd = match arch {
- Arch::X86_64 => "script/upload-nightly.ps1 -Architecture x86_64",
- Arch::ARM64 => "script/upload-nightly.ps1 -Architecture aarch64",
- };
- named::pwsh(cmd).working_directory("${{ env.ZED_WORKSPACE }}")
-}
-
-fn update_nightly_tag() -> Step<Run> {
- named::bash(indoc::indoc! {r#"
- if [ "$(git rev-parse nightly)" = "$(git rev-parse HEAD)" ]; then
- echo "Nightly tag already points to current commit. Skipping tagging."
- exit 0
- fi
- git config user.name github-actions
- git config user.email github-actions@github.com
- git tag -f nightly
- git push origin nightly --force
- "#})
-}
-
-fn create_sentry_release() -> Step<Use> {
- named::uses(
- "getsentry",
- "action-release",
- "526942b68292201ac6bbb99b9a0747d4abee354c", // v3
- )
- .add_env(("SENTRY_ORG", "zed-dev"))
- .add_env(("SENTRY_PROJECT", "zed"))
- .add_env(("SENTRY_AUTH_TOKEN", vars::SENTRY_AUTH_TOKEN))
- .add_with(("environment", "production"))
-}
@@ -144,7 +144,7 @@ pub(crate) fn bundle_windows_job(arch: runners::Arch, deps: &[&NamedJob]) -> Job
)
}
-fn bundle_windows(arch: runners::Arch) -> Step<Run> {
+pub fn bundle_windows(arch: runners::Arch) -> Step<Run> {
let step = match arch {
runners::Arch::X86_64 => named::pwsh("script/bundle-windows.ps1 -Architecture x86_64"),
runners::Arch::ARM64 => named::pwsh("script/bundle-windows.ps1 -Architecture aarch64"),