Compare commits
10 commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
cebd007473 | ||
![]() |
e80c010079 | ||
![]() |
60871a5846 | ||
![]() |
ea09051a92 | ||
![]() |
0c090b6e05 | ||
![]() |
c8233f0d26 | ||
![]() |
26a6fac992 | ||
![]() |
643d60c2e7 | ||
![]() |
e1dbc7e998 | ||
![]() |
7499aa3be4 |
10 changed files with 50 additions and 41 deletions
2
Cargo.lock
generated
2
Cargo.lock
generated
|
@ -10094,7 +10094,7 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "zed"
|
||||
version = "0.110.0"
|
||||
version = "0.110.2"
|
||||
dependencies = [
|
||||
"activity_indicator",
|
||||
"ai",
|
||||
|
|
|
@ -968,7 +968,6 @@ impl CompletionsMenu {
|
|||
self.selected_item -= 1;
|
||||
} else {
|
||||
self.selected_item = self.matches.len() - 1;
|
||||
self.list.scroll_to(ScrollTarget::Show(self.selected_item));
|
||||
}
|
||||
self.list.scroll_to(ScrollTarget::Show(self.selected_item));
|
||||
self.attempt_resolve_selected_completion_documentation(project, cx);
|
||||
|
@ -1539,7 +1538,6 @@ impl CodeActionsMenu {
|
|||
self.selected_item -= 1;
|
||||
} else {
|
||||
self.selected_item = self.actions.len() - 1;
|
||||
self.list.scroll_to(ScrollTarget::Show(self.selected_item));
|
||||
}
|
||||
self.list.scroll_to(ScrollTarget::Show(self.selected_item));
|
||||
cx.notify();
|
||||
|
@ -1548,11 +1546,10 @@ impl CodeActionsMenu {
|
|||
fn select_next(&mut self, cx: &mut ViewContext<Editor>) {
|
||||
if self.selected_item + 1 < self.actions.len() {
|
||||
self.selected_item += 1;
|
||||
self.list.scroll_to(ScrollTarget::Show(self.selected_item));
|
||||
} else {
|
||||
self.selected_item = 0;
|
||||
self.list.scroll_to(ScrollTarget::Show(self.selected_item));
|
||||
}
|
||||
self.list.scroll_to(ScrollTarget::Show(self.selected_item));
|
||||
cx.notify();
|
||||
}
|
||||
|
||||
|
|
|
@ -9,4 +9,4 @@ pub use notification::*;
|
|||
pub use peer::*;
|
||||
mod macros;
|
||||
|
||||
pub const PROTOCOL_VERSION: u32 = 65;
|
||||
pub const PROTOCOL_VERSION: u32 = 66;
|
||||
|
|
|
@ -16,7 +16,7 @@ actions!(branches, [OpenRecent]);
|
|||
|
||||
pub fn init(cx: &mut AppContext) {
|
||||
Picker::<BranchListDelegate>::init(cx);
|
||||
cx.add_async_action(toggle);
|
||||
cx.add_action(toggle);
|
||||
}
|
||||
pub type BranchList = Picker<BranchListDelegate>;
|
||||
|
||||
|
@ -24,30 +24,29 @@ pub fn build_branch_list(
|
|||
workspace: ViewHandle<Workspace>,
|
||||
cx: &mut ViewContext<BranchList>,
|
||||
) -> Result<BranchList> {
|
||||
Ok(Picker::new(BranchListDelegate::new(workspace, 29, cx)?, cx)
|
||||
.with_theme(|theme| theme.picker.clone()))
|
||||
let delegate = workspace.read_with(cx, |workspace, cx| {
|
||||
BranchListDelegate::new(workspace, cx.handle(), 29, cx)
|
||||
})?;
|
||||
|
||||
Ok(Picker::new(delegate, cx).with_theme(|theme| theme.picker.clone()))
|
||||
}
|
||||
|
||||
fn toggle(
|
||||
_: &mut Workspace,
|
||||
workspace: &mut Workspace,
|
||||
_: &OpenRecent,
|
||||
cx: &mut ViewContext<Workspace>,
|
||||
) -> Option<Task<Result<()>>> {
|
||||
Some(cx.spawn(|workspace, mut cx| async move {
|
||||
workspace.update(&mut cx, |workspace, cx| {
|
||||
// Modal branch picker has a longer trailoff than a popover one.
|
||||
let delegate = BranchListDelegate::new(cx.handle(), 70, cx)?;
|
||||
workspace.toggle_modal(cx, |_, cx| {
|
||||
cx.add_view(|cx| {
|
||||
Picker::new(delegate, cx)
|
||||
.with_theme(|theme| theme.picker.clone())
|
||||
.with_max_size(800., 1200.)
|
||||
})
|
||||
});
|
||||
Ok::<_, anyhow::Error>(())
|
||||
})??;
|
||||
Ok(())
|
||||
}))
|
||||
) -> Result<()> {
|
||||
// Modal branch picker has a longer trailoff than a popover one.
|
||||
let delegate = BranchListDelegate::new(workspace, cx.handle(), 70, cx)?;
|
||||
workspace.toggle_modal(cx, |_, cx| {
|
||||
cx.add_view(|cx| {
|
||||
Picker::new(delegate, cx)
|
||||
.with_theme(|theme| theme.picker.clone())
|
||||
.with_max_size(800., 1200.)
|
||||
})
|
||||
});
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub struct BranchListDelegate {
|
||||
|
@ -62,15 +61,16 @@ pub struct BranchListDelegate {
|
|||
|
||||
impl BranchListDelegate {
|
||||
fn new(
|
||||
workspace: ViewHandle<Workspace>,
|
||||
workspace: &Workspace,
|
||||
handle: ViewHandle<Workspace>,
|
||||
branch_name_trailoff_after: usize,
|
||||
cx: &AppContext,
|
||||
) -> Result<Self> {
|
||||
let project = workspace.read(cx).project().read(&cx);
|
||||
|
||||
let project = workspace.project().read(&cx);
|
||||
let Some(worktree) = project.visible_worktrees(cx).next() else {
|
||||
bail!("Cannot update branch list as there are no visible worktrees")
|
||||
};
|
||||
|
||||
let mut cwd = worktree.read(cx).abs_path().to_path_buf();
|
||||
cwd.push(".git");
|
||||
let Some(repo) = project.fs().open_repo(&cwd) else {
|
||||
|
@ -79,13 +79,14 @@ impl BranchListDelegate {
|
|||
let all_branches = repo.lock().branches()?;
|
||||
Ok(Self {
|
||||
matches: vec![],
|
||||
workspace,
|
||||
workspace: handle,
|
||||
all_branches,
|
||||
selected_index: 0,
|
||||
last_query: Default::default(),
|
||||
branch_name_trailoff_after,
|
||||
})
|
||||
}
|
||||
|
||||
fn display_error_toast(&self, message: String, cx: &mut ViewContext<BranchList>) {
|
||||
const GIT_CHECKOUT_FAILURE_ID: usize = 2048;
|
||||
self.workspace.update(cx, |model, ctx| {
|
||||
|
|
|
@ -3,7 +3,7 @@ authors = ["Nathan Sobo <nathansobo@gmail.com>"]
|
|||
description = "The fast, collaborative code editor."
|
||||
edition = "2021"
|
||||
name = "zed"
|
||||
version = "0.110.0"
|
||||
version = "0.110.2"
|
||||
publish = false
|
||||
|
||||
[lib]
|
||||
|
|
|
@ -1 +1 @@
|
|||
dev
|
||||
stable
|
|
@ -2,8 +2,6 @@
|
|||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>com.apple.developer.associated-domains</key>
|
||||
<array><string>applinks:zed.dev</string></array>
|
||||
<key>com.apple.security.automation.apple-events</key>
|
||||
<true/>
|
||||
<key>com.apple.security.cs.allow-jit</key>
|
||||
|
@ -12,8 +10,14 @@
|
|||
<true/>
|
||||
<key>com.apple.security.device.camera</key>
|
||||
<true/>
|
||||
<key>com.apple.security.keychain-access-groups</key>
|
||||
<array><string>MQ55VZLNZQ.dev.zed.Shared</string></array>
|
||||
<key>com.apple.security.personal-information.addressbook</key>
|
||||
<true/>
|
||||
<key>com.apple.security.personal-information.calendars</key>
|
||||
<true/>
|
||||
<key>com.apple.security.personal-information.location</key>
|
||||
<true/>
|
||||
<key>com.apple.security.personal-information.photos-library</key>
|
||||
<true/>
|
||||
<!-- <key>com.apple.security.cs.disable-library-validation</key>
|
||||
<true/> -->
|
||||
</dict>
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
use anyhow::{anyhow, Result};
|
||||
use anyhow::{anyhow, ensure, Result};
|
||||
use async_trait::async_trait;
|
||||
use futures::StreamExt;
|
||||
pub use language::*;
|
||||
|
@ -98,7 +98,10 @@ impl super::LspAdapter for VueLspAdapter {
|
|||
)
|
||||
.await?;
|
||||
}
|
||||
assert!(fs::metadata(&server_path).await.is_ok());
|
||||
ensure!(
|
||||
fs::metadata(&server_path).await.is_ok(),
|
||||
"@vue/language-server package installation failed"
|
||||
);
|
||||
if fs::metadata(&ts_path).await.is_err() {
|
||||
self.node
|
||||
.npm_install_packages(
|
||||
|
@ -108,7 +111,10 @@ impl super::LspAdapter for VueLspAdapter {
|
|||
.await?;
|
||||
}
|
||||
|
||||
assert!(fs::metadata(&ts_path).await.is_ok());
|
||||
ensure!(
|
||||
fs::metadata(&ts_path).await.is_ok(),
|
||||
"typescript for Vue package installation failed"
|
||||
);
|
||||
*self.typescript_install_path.lock() = Some(ts_path);
|
||||
Ok(LanguageServerBinary {
|
||||
path: self.node.binary_path().await?,
|
||||
|
|
|
@ -147,8 +147,9 @@ if [[ -n $MACOS_CERTIFICATE && -n $MACOS_CERTIFICATE_PASSWORD && -n $APPLE_NOTAR
|
|||
security set-key-partition-list -S apple-tool:,apple:,codesign: -s -k "$MACOS_CERTIFICATE_PASSWORD" zed.keychain
|
||||
|
||||
# sequence of codesign commands modeled after this example: https://developer.apple.com/forums/thread/701514
|
||||
/usr/bin/codesign --force --timestamp --sign "Zed Industries, Inc." "${app_path}/Contents/Frameworks/WebRTC.framework" -v
|
||||
/usr/bin/codesign --force --timestamp --options runtime --sign "Zed Industries, Inc." "${app_path}/Contents/MacOS/cli" -v
|
||||
/usr/bin/codesign --deep --force --timestamp --sign "Zed Industries, Inc." "${app_path}/Contents/Frameworks/WebRTC.framework" -v
|
||||
/usr/bin/codesign --deep --force --timestamp --options runtime --sign "Zed Industries, Inc." "${app_path}/Contents/MacOS/cli" -v
|
||||
/usr/bin/codesign --deep --force --timestamp --options runtime --entitlements crates/zed/resources/zed.entitlements --sign "Zed Industries, Inc." "${app_path}/Contents/MacOS/zed" -v
|
||||
/usr/bin/codesign --force --timestamp --options runtime --entitlements crates/zed/resources/zed.entitlements --sign "Zed Industries, Inc." "${app_path}" -v
|
||||
|
||||
security default-keychain -s login.keychain
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue