mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-11-23 07:33:48 +00:00
Upgraded to Rust v1.100.0 and .NET v10.0.15 (#1218)
This commit is contained in:
1 parent
78f5066bfd
commit
f96025529a
10 files changed
+72
-50
No files matched your search
+4
-4
@@ -136,11 +136,11 @@ fn update_cargo_toml(cargo_path: &str, version: &str) {
|
||||
let cargo_toml_lines = cargo_toml.lines();
|
||||
let mut new_cargo_toml = String::new();
|
||||
|
||||
// Return early when the version already matches to avoid unnecessary rewrites.
|
||||
// Return early when the version already matches to avoid unnecessary rewrites. The version of the
|
||||
// package is the one line which starts with `version = `, the same line the loop below replaces:
|
||||
// version = "26.11.1"
|
||||
let current_version = cargo_toml.lines().find_map(|line| {
|
||||
let trimmed = line.trim_start();
|
||||
let rest = trimmed.strip_prefix("\"version\": ")?;
|
||||
let quoted = rest.strip_prefix('"')?;
|
||||
let quoted = line.strip_prefix("version = \"")?;
|
||||
let end_idx = quoted.find('"')?;
|
||||
Some("ed[..end_idx])
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user