дзеркало
https://github.com/l0ng-ai/openidea.git
синхронізовано 2026-11-29 05:52:23 +02:00
Порівняти коміти
| Автор | SHA1 | Дата | |
|---|---|---|---|
|
|
9bcbb09027 | ||
|
|
14e4881418 | ||
|
|
55bc093fe5 | ||
|
|
37ba544733 | ||
|
|
0fde75411a |
No files matched your search
Створено
+39
-39
@@ -4145,7 +4145,7 @@ checksum = "3d3067d79b975e8844ca9eb072e16b31c3c1c36928edf9c6789548c524d0d954"
|
||||
|
||||
[[package]]
|
||||
name = "ide-agent"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"dunce",
|
||||
"encoding_rs",
|
||||
@@ -4169,7 +4169,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-analysis"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ast-grep-core",
|
||||
"ide-core",
|
||||
@@ -4183,7 +4183,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-android"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ide-core",
|
||||
"serde",
|
||||
@@ -4194,7 +4194,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-build"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"blake3",
|
||||
"chardetng",
|
||||
@@ -4212,7 +4212,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-cli"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"dirs 6.0.0",
|
||||
"serde",
|
||||
@@ -4226,7 +4226,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-clipboard"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"gtk",
|
||||
"objc2 0.6.5",
|
||||
@@ -4236,7 +4236,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-core"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"dunce",
|
||||
"encoding_rs",
|
||||
@@ -4253,7 +4253,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-coverage"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ide-core",
|
||||
"ide-run",
|
||||
@@ -4267,7 +4267,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-dap"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"futures",
|
||||
"ide-core",
|
||||
@@ -4288,7 +4288,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-db"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"bb8",
|
||||
"blake3",
|
||||
@@ -4318,7 +4318,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-docker"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ide-core",
|
||||
"serde",
|
||||
@@ -4331,7 +4331,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-extension"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"base64 0.22.1",
|
||||
"blake3",
|
||||
@@ -4352,7 +4352,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-fonts"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"objc2-core-foundation",
|
||||
"objc2-core-text",
|
||||
@@ -4364,7 +4364,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-github"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ide-core",
|
||||
"ide-vcs",
|
||||
@@ -4377,7 +4377,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-host"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"base64 0.22.1",
|
||||
"blake3",
|
||||
@@ -4443,7 +4443,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-http"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ide-core",
|
||||
"ide-vfs",
|
||||
@@ -4462,7 +4462,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-index"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"blake3",
|
||||
"criterion",
|
||||
@@ -4484,7 +4484,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-jsonrpc"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"encoding_rs",
|
||||
"futures",
|
||||
@@ -4501,7 +4501,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-language"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"blake3",
|
||||
"criterion",
|
||||
@@ -4557,7 +4557,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-lsp"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"dunce",
|
||||
"futures",
|
||||
@@ -4583,7 +4583,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-mcp"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"bytes",
|
||||
"dunce",
|
||||
@@ -4602,7 +4602,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-notebook"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"futures",
|
||||
"ide-core",
|
||||
@@ -4625,7 +4625,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-plugin"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"blake3",
|
||||
"dunce",
|
||||
@@ -4648,7 +4648,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-profiler"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ide-core",
|
||||
"ide-run",
|
||||
@@ -4661,7 +4661,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-remote"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"dunce",
|
||||
"globset",
|
||||
@@ -4680,7 +4680,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-run"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"dunce",
|
||||
"encoding_rs",
|
||||
@@ -4704,7 +4704,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-sdk"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"dunce",
|
||||
"ide-core",
|
||||
@@ -4724,7 +4724,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-search"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"criterion",
|
||||
"globset",
|
||||
@@ -4744,7 +4744,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-spell"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ide-core",
|
||||
"parking_lot",
|
||||
@@ -4757,7 +4757,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-ssh"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"dirs 6.0.0",
|
||||
"flate2",
|
||||
@@ -4778,7 +4778,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-syntax"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ide-core",
|
||||
"ide-language",
|
||||
@@ -4793,7 +4793,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-terminal"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ide-core",
|
||||
"libc",
|
||||
@@ -4806,7 +4806,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-text"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"criterion",
|
||||
"ide-core",
|
||||
@@ -4819,7 +4819,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-tools"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"flate2",
|
||||
"hex",
|
||||
@@ -4840,7 +4840,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-vcs"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"blake3",
|
||||
"dunce",
|
||||
@@ -4861,7 +4861,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-vfs"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"chardetng",
|
||||
"dunce",
|
||||
@@ -4885,7 +4885,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-web"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"ide-core",
|
||||
"open",
|
||||
@@ -4901,7 +4901,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ide-workspace"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"blake3",
|
||||
"dunce",
|
||||
@@ -6479,7 +6479,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "openidea"
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
dependencies = [
|
||||
"base64 0.22.1",
|
||||
"blake3",
|
||||
|
||||
+1
-1
@@ -5,7 +5,7 @@ members = ["crates/*", "src-tauri"]
|
||||
exclude = ["sdk", "plugins"]
|
||||
|
||||
[workspace.package]
|
||||
version = "0.1.40"
|
||||
version = "0.1.41"
|
||||
edition = "2024"
|
||||
rust-version = "1.96"
|
||||
license = "Apache-2.0"
|
||||
|
||||
@@ -337,7 +337,7 @@ async fn start_inner(
|
||||
// what makes the setting take effect without reopening the project.
|
||||
if config.kind == "maven" {
|
||||
ide_sdk::apply::prepare_maven_run(&mut config, root, &settings);
|
||||
} else if matches!(config.kind.as_str(), "gradle" | "tomcat") {
|
||||
} else if matches!(config.kind.as_str(), "gradle" | "tomcat" | "junit") {
|
||||
ide_sdk::apply::apply_to_run_configs(std::slice::from_mut(&mut config), root, &settings);
|
||||
} else {
|
||||
ide_sdk::apply::resolve_run_command(&mut config, root, &settings);
|
||||
|
||||
@@ -130,6 +130,17 @@ pub fn run_system_env(_host: &Host, _window: &str) -> std::collections::BTreeMap
|
||||
ide_run::system_env()
|
||||
}
|
||||
|
||||
/// Variables of the `.env` files a debug launch names, in order (later files win):
|
||||
/// the same files a run loads, over the system environment debug adapters inherit.
|
||||
pub fn run_env_files(
|
||||
_host: &Host,
|
||||
_window: &str,
|
||||
files: Vec<std::path::PathBuf>,
|
||||
) -> IdeResult<std::collections::BTreeMap<String, String>> {
|
||||
ide_run::envfile::load(&files, &ide_run::system_env())
|
||||
.map_err(|e| IdeError::not_found(format!("cannot read .env file: {e}")))
|
||||
}
|
||||
|
||||
/// Writes the Gradle init script that adds `jvm_args` to the JVMs the build forks
|
||||
/// (`bootRun`, `run`, tests) and returns its path, for `--init-script`.
|
||||
pub async fn run_gradle_jvm_args_script(_host: &Host, _window: &str, jvm_args: Vec<String>) -> IdeResult<String> {
|
||||
@@ -332,6 +343,7 @@ pub(crate) fn register(d: &mut Dispatcher) {
|
||||
run_import_configs(&c.host, &c.window, c.arg("source")?, c.arg("existing")?)
|
||||
});
|
||||
d.add("run_system_env", |c| async move { Ok(run_system_env(&c.host, &c.window)) });
|
||||
d.add("run_env_files", |c| async move { run_env_files(&c.host, &c.window, c.arg("files")?) });
|
||||
d.add("run_gradle_jvm_args_script", |c| async move {
|
||||
run_gradle_jvm_args_script(&c.host, &c.window, c.arg("jvmArgs")?).await
|
||||
});
|
||||
|
||||
@@ -157,3 +157,22 @@ async fn gradle_init_scripts_are_written_by_the_host_that_runs_the_build() {
|
||||
let escaped = ops::run::run_gradle_init_script(&host, "main", "../escape".into(), String::new()).await;
|
||||
assert!(escaped.is_err(), "{escaped:?}");
|
||||
}
|
||||
|
||||
#[tokio::test(flavor = "multi_thread", worker_threads = 2)]
|
||||
async fn debug_env_files_load_in_order_like_a_run() {
|
||||
let tmp = tempfile::tempdir().unwrap();
|
||||
let host = host(tmp.path());
|
||||
let first = tmp.path().join("first.env");
|
||||
let second = tmp.path().join("second.env");
|
||||
std::fs::write(&first, "SHARED=one\nONLY_FIRST=1\nREF=${SHARED}-suffix\n").unwrap();
|
||||
std::fs::write(&second, "SHARED=two\nONLY_SECOND=2\n").unwrap();
|
||||
let vars = ops::run::run_env_files(&host, "main", vec![first, second]).unwrap();
|
||||
// Later files win; references resolve against earlier files, then the system environment.
|
||||
assert_eq!(vars.get("SHARED").map(String::as_str), Some("two"));
|
||||
assert_eq!(vars.get("ONLY_FIRST").map(String::as_str), Some("1"));
|
||||
assert_eq!(vars.get("ONLY_SECOND").map(String::as_str), Some("2"));
|
||||
assert_eq!(vars.get("REF").map(String::as_str), Some("one-suffix"));
|
||||
// An unreadable file is an error, like a run that names a missing `.env`.
|
||||
let missing = ops::run::run_env_files(&host, "main", vec![tmp.path().join("nope.env")]);
|
||||
assert!(missing.is_err(), "{missing:?}");
|
||||
}
|
||||
@@ -1561,6 +1561,24 @@ pub fn apply_to_run_configs(configs: &mut [RunConfig], root: &Path, s: &Settings
|
||||
c.env.entry("JAVA_HOME".into()).or_insert_with(|| jdk.home.to_string_lossy().into_owned());
|
||||
}
|
||||
}
|
||||
// A JUnit configuration runs the module's own Maven or Gradle command line: it needs
|
||||
// that build's environment (its JDK), not another launcher or extra options.
|
||||
"junit" => {
|
||||
let name = Path::new(&c.command).file_name().map(|n| n.to_string_lossy().to_ascii_lowercase());
|
||||
match name.as_deref() {
|
||||
Some(n) if n.starts_with("mvn") => apply_maven_env(c, root, s),
|
||||
Some(n) if n.starts_with("gradle") => {
|
||||
let build_dir =
|
||||
c.cwd.as_ref().map(|p| root.join(p.as_ref())).unwrap_or_else(|| root.to_path_buf());
|
||||
let env = gradle_build_env(root, &build_dir, &c.command, s, None);
|
||||
apply_java_home(c, &env, java_home_is_derived(c));
|
||||
for (key, value) in env {
|
||||
c.env.entry(key).or_insert(value);
|
||||
}
|
||||
}
|
||||
_ => {}
|
||||
}
|
||||
}
|
||||
"maven" => {
|
||||
apply_maven_env(c, root, s);
|
||||
if let Some(mvn) = &mvn
|
||||
|
||||
@@ -409,6 +409,19 @@ fn project_jdk_and_maven_settings() {
|
||||
);
|
||||
assert_eq!(configs[0].env["JAVA_HOME"], home);
|
||||
assert_eq!(configs[1].env["JAVA_HOME"], home);
|
||||
// JUnit runs the build's own command line: the build's JDK, its command and arguments unchanged.
|
||||
let mut junit = vec![
|
||||
run("junit", "./mvnw", &["test", "-Dtest=a.T"]),
|
||||
run("junit", "./gradlew", &[":api:test", "--tests", "a.T"]),
|
||||
];
|
||||
apply_to_run_configs(&mut junit, tmp.path(), &s);
|
||||
assert_eq!(
|
||||
(junit[0].command.as_str(), junit[0].args.as_slice()),
|
||||
("./mvnw", &["test".to_owned(), "-Dtest=a.T".to_owned()][..])
|
||||
);
|
||||
assert_eq!(junit[0].env["JAVA_HOME"], home);
|
||||
assert_eq!(junit[1].command, "./gradlew");
|
||||
assert_eq!(junit[1].env["JAVA_HOME"], home);
|
||||
apply_to_run_configs(&mut configs, tmp.path(), &s);
|
||||
assert_eq!(configs[0].args.len(), 6, "applied once");
|
||||
|
||||
|
||||
@@ -21,6 +21,30 @@ async function searchFiles(page: Page) {
|
||||
return dialog;
|
||||
}
|
||||
|
||||
for (const count of [1, 2, 24]) {
|
||||
test(`without the preview the results list shows its rows (${count} results)`, async ({ workbench: page }) => {
|
||||
await stubDesktop(page);
|
||||
await page.evaluate((count) => {
|
||||
window.__ipc.handlers.find_files = () =>
|
||||
Array.from({ length: count }, (_, i) => ({
|
||||
path: `/dev/acme-api/src/main${i}.js`,
|
||||
relPath: `src/main${i}.js`,
|
||||
score: 100 - i,
|
||||
indices: [],
|
||||
}));
|
||||
}, count);
|
||||
await doubleShift(page);
|
||||
const dialog = page.locator('[role="dialog"]:has(#se-query)');
|
||||
await dialog.getByRole("tab", { name: "Files", exact: true }).click();
|
||||
await dialog.getByRole("combobox", { name: "Search query" }).fill("main");
|
||||
await expect(dialog.getByRole("separator", { name: "Preview", exact: true })).toBeHidden();
|
||||
const list = dialog.getByRole("listbox", { name: "Results" });
|
||||
await expect
|
||||
.poll(async () => (await list.boundingBox())?.height ?? 0)
|
||||
.toBeGreaterThanOrEqual(Math.min(count, 5) * 24);
|
||||
});
|
||||
}
|
||||
|
||||
test("preview splitter resizes with mouse and keyboard, keeps query focus and remembers its ratio", async ({
|
||||
workbench: page,
|
||||
}) => {
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
"name": "openidea",
|
||||
"private": true,
|
||||
"description": "An open-source IDE inspired by IntelliJ IDEA",
|
||||
"version": "0.1.40",
|
||||
"version": "0.1.41",
|
||||
"license": "Apache-2.0",
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// The commit being prepared in the window the current command or event came
|
||||
/// from (the Commit tool window, or the Commit dialog while it is open): the
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Plugin-owned project data sources. Requires database.sources and project trust.
|
||||
/// Runs on the Database subsystem's host, including on remote project servers.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Project-scoped decorations (API 1.4). Requires project.read; paths must be inside
|
||||
/// an open project. Sets belong to the plugin and disappear when it stops.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// What the pane beside the Services tree shows for a plugin's node.
|
||||
interface detail-types {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Optional export (world `plugin-diagnostics`): problems in the current,
|
||||
/// possibly unsaved document, for the languages declared with the
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// HTTP endpoints found in a project (`[[contributes.endpoints]]`).
|
||||
interface endpoints-provider {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Workbench events, delivered in batches to `event-handler.handle`.
|
||||
interface events {
|
||||
@@ -32,6 +32,9 @@ interface events {
|
||||
/// API 1.4 also delivers `file-closed` (JSON path string), `settings-changed`
|
||||
/// (JSON array of the plugin's changed setting keys), and `input-mode-changed`
|
||||
/// (JSON {path, mode, sub}) through `other`. The last needs `events.input`.
|
||||
/// API 1.5 also delivers `extensions-changed` (JSON array of the extension
|
||||
/// points this plugin declares whose contributions changed) through `other`,
|
||||
/// to the declaring plugin only and without a capability.
|
||||
/// Kinds: `file-opened`, `file-saved`, `files-changed` (batched disk changes
|
||||
/// as `other`, with created/modified/removed path lists in JSON), `editor-focused` (the focused editor
|
||||
/// changed), `vcs-changed` (a repository's state changed: commit,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
interface lifecycle {
|
||||
use types.{context, error};
|
||||
@@ -73,3 +73,22 @@ interface syntax-provider {
|
||||
outline: func(language: string, text: string) -> list<symbol>;
|
||||
folding: func(language: string, text: string) -> list<fold>;
|
||||
}
|
||||
|
||||
/// Optional pre-launch gate for targets owned by this plugin (API 1.5).
|
||||
interface run-target-validation {
|
||||
enum operation { run, test }
|
||||
record launch-info {
|
||||
operation: operation,
|
||||
/// Bare program name before wrapping; no arguments or environment.
|
||||
program: string,
|
||||
/// Absolute working directory on the machine hosting the plugin.
|
||||
cwd: string,
|
||||
}
|
||||
/// Called after trust, ownership, process grants and executable pin checks.
|
||||
/// An error refuses the launch without changing the selected target. The
|
||||
/// host prefixes and bounds the message. Missing exports allow the launch.
|
||||
/// Calls wake reclaimed instances, use the host call timeout (5s by default),
|
||||
/// and are cancelled with the launch. Traps/timeouts refuse the launch.
|
||||
/// For remote projects this runs on the server, where the plugin lives.
|
||||
validate: func(project: string, target-id: string, launch: launch-info) -> result<_, string>;
|
||||
}
|
||||
@@ -0,0 +1,21 @@
|
||||
package openidea:[email protected];
|
||||
|
||||
/// What other plugins contributed to the extension points this plugin declares
|
||||
/// (`[[extension-points]]` in `plugin.toml`; the contributors list this plugin
|
||||
/// in `[[depends]]`). A change is announced by the `extensions-changed` event.
|
||||
interface extensions {
|
||||
use types.{error};
|
||||
|
||||
record contribution {
|
||||
/// The contributing plugin's id.
|
||||
plugin: string,
|
||||
/// Its `[[contributes."<point>"]]` table as JSON, checked by the host
|
||||
/// against the fields the point declares.
|
||||
data: string,
|
||||
}
|
||||
|
||||
/// The contributions to `point`, in the order the plugins started. Only the
|
||||
/// plugin that declares `point` may read it (`denied` otherwise); `not-found`
|
||||
/// when no running plugin declares it.
|
||||
contributions: func(point: string) -> result<list<contribution>, error>;
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Optional export (world `plugin-file-actions`): quick fixes and
|
||||
/// refactorings that create, rename or delete files, next to the text edits
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Files outside the open projects: the configuration of the program a
|
||||
/// plugin integrates with, a tool installed elsewhere, a licence file.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Writes to the IDE log, tagged with the plugin id.
|
||||
interface log {
|
||||
@@ -9,6 +9,7 @@ interface log {
|
||||
|
||||
interface ui {
|
||||
use types.{error, notification-level};
|
||||
use workspace.{project};
|
||||
|
||||
record status-item {
|
||||
text: string,
|
||||
@@ -50,6 +51,12 @@ interface ui {
|
||||
/// dismisses the balloon and runs the command in its window. An invalid
|
||||
/// action or an undeclared command fails the call and shows nothing.
|
||||
notify: func(level: notification-level, title: string, body: string, actions: list<notification-action>) -> result<_, error>;
|
||||
/// `notify` in a window of `target` only (API 1.5), with or without an
|
||||
/// invoking window: the most recently focused one when the project is open
|
||||
/// in several. Actions run in that window. A project closed by the time of
|
||||
/// the call fails it with `not-found` and shows nothing; there is no
|
||||
/// fallback to another window. A shown balloon goes away with its window.
|
||||
notify-project: func(target: borrow<project>, level: notification-level, title: string, body: string, actions: list<notification-action>) -> result<_, error>;
|
||||
/// Shows or updates the plugin's status bar item `id` in every window.
|
||||
set-status-item: func(id: string, item: status-item);
|
||||
remove-status-item: func(id: string);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Optional export (world `plugin-hover`): Markdown added to the hover of
|
||||
/// documents of the languages declared with the `hover` provider kind,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Cross-file associations a plugin publishes for the files it declares under
|
||||
/// `[[contributes.documentIndexers]]`. The host calls `index` in cancellable
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Embedded languages. The host routes plugin providers and configured language
|
||||
/// servers inside these ranges, preserving host-document UTF-16 coordinates.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Optional export (world `plugin-inlay-hints`): inline hints in documents of
|
||||
/// the languages declared with the `inlay-hints` provider kind, including
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Problems in files, shown in the editor and the Problems view.
|
||||
interface diagnostics {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Additional language features, called only for declared API 1.4 provider kinds.
|
||||
/// Editor calls have a 50 ms soft / 500 ms hard budget; formatting has 5 seconds.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Discovery of the IDE's built-in MCP server; never exposes its URL or token.
|
||||
interface mcp {
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
/// `fs` and `workspace`, and everything else goes through the imports below,
|
||||
/// gated by the capabilities granted in `plugin.toml` (a missing one returns
|
||||
/// `error::denied`).
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
world plugin {
|
||||
import log;
|
||||
@@ -37,6 +37,7 @@ world plugin {
|
||||
import database;
|
||||
import mcp;
|
||||
import settings;
|
||||
import extensions;
|
||||
|
||||
export lifecycle;
|
||||
export commands;
|
||||
@@ -200,3 +201,8 @@ world language-injections { export injections; }
|
||||
world plugin-mcp { include plugin; export mcp-provider; }
|
||||
/// Export-only MCP tools, composed with the base plugin world.
|
||||
world mcp-tools { export mcp-provider; }
|
||||
|
||||
/// A plugin that validates launches through its run targets (API 1.5).
|
||||
world plugin-run-target-validation { include plugin; export run-target-validation; }
|
||||
/// Export-only validation, composed with the base plugin world.
|
||||
world run-target-validator { export run-target-validation; }
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Editor features a plugin provides for the languages it declares under
|
||||
/// `[[contributes.providers]]` (the host calls only declared kinds). They run
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Project-scoped targets owned by the registering plugin (API 1.4).
|
||||
interface run-targets {
|
||||
@@ -16,10 +16,7 @@ interface run-targets {
|
||||
/// Without workdir-args the wrapper manages its container directory itself.
|
||||
/// The wrapper always starts in the configuration's LOCAL working directory.
|
||||
/// Environment reaches the wrapper; forwarding into a container depends on its conventions.
|
||||
/// Registration never selects the target. Debugging requires container-root and an
|
||||
/// explicitly supported language debugger placement. Connect-back adapters listen
|
||||
/// on the host; the target must configure the debuggee to connect to that host.
|
||||
/// Stdio adapters run inside the target and must be installed there.
|
||||
/// Registration never selects the target. Debugging plugin targets is invalid.
|
||||
record run-target {
|
||||
id: string,
|
||||
name: string,
|
||||
@@ -34,6 +31,29 @@ interface run-targets {
|
||||
/// Targets survive idle reclamation, and disappear on unregister or plugin stop.
|
||||
/// Remote project registration and execution take place on the server.
|
||||
register: func(project: borrow<project>, target: run-target) -> result<_, error>;
|
||||
/// Per-command prefix and optional replacement working-directory arguments (API 1.5).
|
||||
/// None inherits the target's workdir-args; some([]) omits them.
|
||||
/// Replacement arguments use the same {cwd} substitution and path restrictions.
|
||||
record command-override {
|
||||
name: string,
|
||||
args: list<string>,
|
||||
workdir-args: option<list<string>>,
|
||||
}
|
||||
|
||||
/// Like run-target, with per-command working-directory argument control (API 1.5).
|
||||
/// Matching commands use program + override args + selected workdir-args + command arguments.
|
||||
record run-target-with-overrides {
|
||||
id: string,
|
||||
name: string,
|
||||
program: string,
|
||||
args: list<string>,
|
||||
workdir-args: list<string>,
|
||||
container-root: option<string>,
|
||||
commands: list<command-override>,
|
||||
}
|
||||
|
||||
/// Same ownership, trust, process grant and pin checks as register (API 1.5).
|
||||
register-with-overrides: func(project: borrow<project>, target: run-target-with-overrides) -> result<_, error>;
|
||||
/// Removes only this plugin's target from the project; missing ids are harmless.
|
||||
unregister: func(project: borrow<project>, id: string);
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Launches this plugin's configurations in the invoking window's Run tool window.
|
||||
interface run {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Optional export (world `plugin-semantic-tokens`): semantic colouring of
|
||||
/// documents of the languages declared with the `semantic-tokens` provider
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Shared types. Positions are 0-based lines and UTF-16 code unit columns,
|
||||
/// as in the editor and LSP.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
/// Declarative views: tool windows declared
|
||||
/// under `[[contributes.views]]` and custom editors under
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package openidea:plugin@1.4.0;
|
||||
package openidea:plugin@1.5.0;
|
||||
|
||||
interface workspace {
|
||||
use types.{error, location};
|
||||
@@ -66,6 +66,12 @@ interface workspace {
|
||||
/// contents win over the disk. A missing path is `not-found`.
|
||||
/// Requires `project.read`.
|
||||
read-file: func(path: string) -> result<string, error>;
|
||||
/// Reads the bytes of a file inside the project (absolute, or
|
||||
/// relative to the root) — images, archives, fonts — at most 16 MiB,
|
||||
/// as `fs.read-bytes` allows; paths leaving the root are refused and
|
||||
/// a missing path is `not-found`. The file on disk: unsaved editor
|
||||
/// contents don't apply. Requires `project.read`.
|
||||
read-bytes: func(path: string) -> result<list<u8>, error>;
|
||||
/// Replaces the text of a file inside the project (absolute, or
|
||||
/// relative to the root), or creates it with missing parent
|
||||
/// directories; paths leaving the root are refused. Written in one
|
||||
|
||||
@@ -380,6 +380,7 @@ pub fn builder() -> tauri_specta::Builder<tauri::Wry> {
|
||||
run::run_import_sources,
|
||||
run::run_import_configs,
|
||||
run::run_system_env,
|
||||
run::run_env_files,
|
||||
run::run_start,
|
||||
run::run_stop,
|
||||
run::run_stdin,
|
||||
|
||||
@@ -179,6 +179,17 @@ pub fn run_system_env(state: State<'_, AppState>) -> std::collections::BTreeMap<
|
||||
ide_host::ops::run::run_system_env(&state.host, "")
|
||||
}
|
||||
|
||||
/// Variables of the `.env` files a debug launch names, for the debugger to start with.
|
||||
#[tauri::command]
|
||||
#[specta::specta]
|
||||
pub fn run_env_files(
|
||||
window: Window,
|
||||
state: State<'_, AppState>,
|
||||
files: Vec<std::path::PathBuf>,
|
||||
) -> IdeResult<std::collections::BTreeMap<String, String>> {
|
||||
ide_host::ops::run::run_env_files(&state.host, window.label(), files)
|
||||
}
|
||||
|
||||
/// Writes the Gradle init script adding `jvm_args` to the JVMs the build forks; returns its path.
|
||||
#[tauri::command]
|
||||
#[specta::specta]
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"$schema": "https://schema.tauri.app/config/2",
|
||||
"productName": "OpenIDEA",
|
||||
"version": "0.1.40",
|
||||
"version": "0.1.41",
|
||||
"identifier": "ai.l0ng.openidea",
|
||||
"build": {
|
||||
"beforeDevCommand": "pnpm dev",
|
||||
|
||||
@@ -733,6 +733,8 @@ export const commands = {
|
||||
runImportConfigs: (source: RunImportSource, existing: RunConfig_Deserialize[]) => typedError<RunImport_Serialize, IdeError>(__TAURI_INVOKE("run_import_configs", { source, existing })),
|
||||
/** The environment runs inherit when "Include system environment variables" is on. */
|
||||
runSystemEnv: () => __TAURI_INVOKE<{ [key in string]: string }>("run_system_env"),
|
||||
/** Variables of the `.env` files a debug launch names, for the debugger to start with. */
|
||||
runEnvFiles: (files: string[]) => typedError<{ [key in string]: string }, IdeError>(__TAURI_INVOKE("run_env_files", { files })),
|
||||
runStart: (config: RunConfig_Deserialize, onOutput: Channel<OutputChunk>, request: number | null) => typedError<RunInfo, IdeError>(__TAURI_INVOKE("run_start", { config, onOutput, request })),
|
||||
runStop: (id: RunId) => typedError<null, IdeError>(__TAURI_INVOKE("run_stop", { id })),
|
||||
runStdin: (id: RunId, data: string) => typedError<null, IdeError>(__TAURI_INVOKE("run_stdin", { id, data })),
|
||||
|
||||
@@ -471,6 +471,31 @@
|
||||
.markdown :global(ol) {
|
||||
margin: 0 0 8px;
|
||||
padding-left: 20px;
|
||||
list-style: none;
|
||||
}
|
||||
/* Markers are drawn as pseudo-elements: WebKit paints a selection box around a native marker,
|
||||
leaving a broken stripe down the gutter when a list is selected. */
|
||||
.markdown :global(li) {
|
||||
position: relative;
|
||||
}
|
||||
.markdown :global(li)::before {
|
||||
position: absolute;
|
||||
right: calc(100% + 6px);
|
||||
-webkit-user-select: none;
|
||||
user-select: none;
|
||||
}
|
||||
.markdown :global(ul > li)::before {
|
||||
content: "•";
|
||||
}
|
||||
.markdown :global(ul ul > li)::before {
|
||||
content: "◦";
|
||||
}
|
||||
.markdown :global(ul ul ul > li)::before {
|
||||
content: "▪";
|
||||
}
|
||||
.markdown :global(ol > li)::before {
|
||||
content: counter(list-item) ".";
|
||||
font-variant-numeric: tabular-nums;
|
||||
}
|
||||
.markdown :global(a) {
|
||||
color: var(--link);
|
||||
@@ -521,7 +546,9 @@
|
||||
}
|
||||
.markdown :global(li:has(> input[type="checkbox"])) {
|
||||
margin-left: -20px;
|
||||
list-style: none;
|
||||
}
|
||||
.markdown :global(li:has(> input[type="checkbox"]))::before {
|
||||
content: none;
|
||||
}
|
||||
.markdown > :global(:first-child) {
|
||||
margin-top: 0;
|
||||
|
||||
@@ -1,7 +1,18 @@
|
||||
import { afterEach, beforeEach, describe, expect, it } from "vitest";
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from "vitest";
|
||||
import type { RunConfig } from "@/platform/ipc";
|
||||
import { usePlatform } from "@/platform/platformInfo";
|
||||
import { debugUnsupportedReason, launchConfigFor } from "../launch";
|
||||
import { debugUnsupportedReason, launchConfigFor, withEnvFiles } from "../launch";
|
||||
|
||||
const ipc = vi.hoisted(() => {
|
||||
const ok = <T>(data: T) => Promise.resolve({ status: "ok" as const, data });
|
||||
return { ok, runEnvFiles: vi.fn((_files: string[]) => ok({} as Record<string, string>)) };
|
||||
});
|
||||
|
||||
vi.mock("@/platform/ipc", async (importOriginal) => {
|
||||
const real = await importOriginal<typeof import("@/platform/ipc")>();
|
||||
const { ok: _ok, ...cmds } = ipc;
|
||||
return { ...real, commands: { ...real.commands, ...cmds } };
|
||||
});
|
||||
|
||||
const rc = (p: Partial<RunConfig>): RunConfig => ({
|
||||
id: "x",
|
||||
@@ -20,7 +31,10 @@ const rc = (p: Partial<RunConfig>): RunConfig => ({
|
||||
const extra = (l: { extraJson: string | null } | null) => JSON.parse(l?.extraJson ?? "{}");
|
||||
|
||||
const originalPlatform = usePlatform.getState();
|
||||
beforeEach(() => usePlatform.setState({ os: "linux" }));
|
||||
beforeEach(() => {
|
||||
usePlatform.setState({ os: "linux" });
|
||||
vi.clearAllMocks();
|
||||
});
|
||||
afterEach(() => usePlatform.setState(originalPlatform));
|
||||
|
||||
describe("run config → launch config", () => {
|
||||
@@ -494,3 +508,18 @@ it("raw and typed Go debug configurations inherit custom tags unless explicitly
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
describe("withEnvFiles", () => {
|
||||
it("leaves configurations without .env files alone (no backend call)", async () => {
|
||||
const config = rc({ env: { A: "1" } });
|
||||
await expect(withEnvFiles(config, "/p")).resolves.toBe(config);
|
||||
expect(ipc.runEnvFiles).not.toHaveBeenCalled();
|
||||
});
|
||||
|
||||
it("loads .env files under the explicit variables, resolved against the project root", async () => {
|
||||
ipc.runEnvFiles.mockResolvedValueOnce({ status: "ok", data: { FROM_FILE: "file", A: "file" } });
|
||||
const out = await withEnvFiles(rc({ env: { A: "explicit" }, envFiles: [".env", "env/local.env"] }), "/p");
|
||||
expect(ipc.runEnvFiles).toHaveBeenCalledWith(["/p/.env", "/p/env/local.env"]);
|
||||
expect(out.env).toEqual({ FROM_FILE: "file", A: "explicit" });
|
||||
});
|
||||
});
|
||||
@@ -30,7 +30,7 @@ import { fieldAt, methodAt } from "./breakpoints/symbols";
|
||||
import { toggleBreakpointSmart } from "./breakpoints/toggle";
|
||||
import { isJavaAttachTarget, isJavaDebuggable, javaAttachConfig, javaLaunchConfig } from "./java";
|
||||
import { cancelHotSwapBuild, reloadChangedClasses } from "./hotswap";
|
||||
import { debugUnsupportedReason, launchConfigFor } from "./launch";
|
||||
import { debugUnsupportedReason, launchConfigFor, withEnvFiles } from "./launch";
|
||||
import {
|
||||
isPythonAttachTarget,
|
||||
isRemoteConfig,
|
||||
@@ -329,7 +329,7 @@ async function startConfig(arg: unknown) {
|
||||
// php-debug starts the PHP chosen in Settings unless the command names one.
|
||||
const php =
|
||||
config.debugAdapter === "php-debug" && isTauri() ? await call(commands.sdkPhpEffective()).catch(() => null) : null;
|
||||
const launch = launchConfigFor(prepared, root, php);
|
||||
const launch = launchConfigFor(await withEnvFiles(prepared, root), root, php);
|
||||
if (!launch) {
|
||||
notifications().notify({
|
||||
group: "run",
|
||||
@@ -399,7 +399,7 @@ export function registerDebugActions(): () => void {
|
||||
const config = await call(commands.pluginPrepareDebugRun(a.config));
|
||||
const root = useProject.getState().project?.root;
|
||||
if (!root) throw new Error("No project");
|
||||
const launch = launchConfigFor(config, root);
|
||||
const launch = launchConfigFor(await withEnvFiles(config, root), root);
|
||||
if (!launch) throw new Error("This configuration has no debugger");
|
||||
let id: number | null = null;
|
||||
let stopped = false;
|
||||
|
||||
@@ -16,6 +16,7 @@ import {
|
||||
type JavaPreparation,
|
||||
} from "@/platform/javaLaunch";
|
||||
import { maybeEditorService, notifications } from "@/workbench/contributions";
|
||||
import { withEnvFiles } from "./launch";
|
||||
|
||||
export const JAVA_ADAPTER = "java-debug";
|
||||
export const KOTLIN_ADAPTER = "kotlin-debug-adapter";
|
||||
@@ -111,6 +112,7 @@ export async function javaLaunchConfig(
|
||||
preparation?: JavaPreparation,
|
||||
): Promise<LaunchConfig> {
|
||||
const cwd = rc.cwd ? join(root, rc.cwd) : root;
|
||||
rc = await withEnvFiles(rc, root);
|
||||
const parsed = parseJavaArgs(rc.args);
|
||||
if (!parsed.mainClass) throw new Error(`No main class in '${rc.name}'`);
|
||||
preparation?.signal.throwIfAborted();
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { parseArgs, formatArgs } from "@/platform/commandLine";
|
||||
/** Run configuration → DAP launch configuration, per adapter. */
|
||||
import { workflowSettings } from "@/platform/workflowSettings";
|
||||
import type { LaunchConfig, RunConfig } from "@/platform/ipc";
|
||||
import { call, commands, type LaunchConfig, type RunConfig } from "@/platform/ipc";
|
||||
import { hostOs } from "@/platform/remote";
|
||||
|
||||
function isAbsolute(p: string) {
|
||||
@@ -37,6 +37,18 @@ function base(rc: RunConfig, adapter: string, cwd: string): LaunchConfig {
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* `rc` with its `.env` files loaded underneath its explicit variables (mirrors Run):
|
||||
* Debug used to drop them because `base` only copies `env`. Absolute paths go to the
|
||||
* backend, which parses with the same loader runs use.
|
||||
*/
|
||||
export async function withEnvFiles(rc: RunConfig, root: string): Promise<RunConfig> {
|
||||
const files = rc.envFiles?.filter((f) => f.trim()) ?? [];
|
||||
if (!files.length) return rc;
|
||||
const loaded = await call(commands.runEnvFiles(files.map((f) => join(root, f))));
|
||||
return { ...rc, env: { ...loaded, ...rc.env } };
|
||||
}
|
||||
|
||||
function cargoLaunch(rc: RunConfig, cwd: string, adapter: string): LaunchConfig {
|
||||
const [cargoArgs, programArgs] = splitAtDashDash(rc.args);
|
||||
const [sub, ...rest] = cargoArgs;
|
||||
|
||||
@@ -139,7 +139,9 @@
|
||||
height: 532px;
|
||||
}
|
||||
.results {
|
||||
flex: 1;
|
||||
/* `auto`, not `1`: without the preview `.content` has no definite height, and a 0% basis there
|
||||
collapses the list in the system WebKit of macOS 15 instead of using its inline height. */
|
||||
flex: 1 1 auto;
|
||||
min-height: 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
Reference in new issue
Заблокувати користувача