From a8b57a2529abcfe263e4e9b38cbd61b60705d9ef Mon Sep 17 00:00:00 2001 From: Dino Date: Tue, 28 Jul 2026 13:30:14 +0100 Subject: [PATCH] feature_flags: Enable project panel undo everywhere except stable (#61457) # Objective Enable the Project Panel Undo/Redo feature flag in all channels except stable. This gives us control over when it lands in Stable, while also allowing us to have it sit in Preview for longer than a single week, if we want to. ## Solution Update `ProjectPanelUndoRedoFeatureFlag::enabled_for_all` to be true on all release channels except `ReleaseChannel::Stable`. The feature flag doesn't allow us to scope it per environment so there's no way we could enable the flag for all but only have it impact Preview, should have added that safeguard in the beginning as stable is already relying on the feature flag exclusively. ## Testing N/A ## Self-Review Checklist: - [x] I've reviewed my own diff for quality, security, and reliability - [ ] Unsafe blocks (if any) have justifying comments - [ ] The content adheres to Zed's UI standards ([UX/UI](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist) and [icon](https://github.com/zed-industries/zed/blob/main/crates/icons/README.md) guidelines) - [ ] Tests cover the new/changed behavior - [ ] Performance impact has been considered and is acceptable --- Release Notes: - N/A --- Cargo.lock | 1 + crates/feature_flags/Cargo.toml | 1 + crates/feature_flags/src/flags.rs | 7 +++++++ 3 files changed, 9 insertions(+) diff --git a/Cargo.lock b/Cargo.lock index 0b58f151b5..2a8077b622 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -6566,6 +6566,7 @@ dependencies = [ "fs", "gpui", "inventory", + "release_channel", "schemars 1.0.4", "serde_json", "settings", diff --git a/crates/feature_flags/Cargo.toml b/crates/feature_flags/Cargo.toml index 31ec5ec0da..8b1d9b18d6 100644 --- a/crates/feature_flags/Cargo.toml +++ b/crates/feature_flags/Cargo.toml @@ -17,6 +17,7 @@ feature_flags_macros.workspace = true fs.workspace = true gpui.workspace = true inventory.workspace = true +release_channel.workspace = true schemars.workspace = true serde_json.workspace = true settings.workspace = true diff --git a/crates/feature_flags/src/flags.rs b/crates/feature_flags/src/flags.rs index de6f03f1c6..8486c32d26 100644 --- a/crates/feature_flags/src/flags.rs +++ b/crates/feature_flags/src/flags.rs @@ -87,6 +87,13 @@ impl FeatureFlag for ProjectPanelUndoRedoFeatureFlag { fn enabled_for_staff() -> bool { true } + + fn enabled_for_all() -> bool { + !matches!( + *release_channel::RELEASE_CHANNEL, + release_channel::ReleaseChannel::Stable + ) + } } register_feature_flag!(ProjectPanelUndoRedoFeatureFlag);