From 68a8da9c667ef59c03ca5b0188d2fc3e41639ea3 Mon Sep 17 00:00:00 2001 From: C0D3 M4513R <28912031+C0D3-M4513R@users.noreply.github.com> Date: Wed, 29 May 2024 20:54:41 +0200 Subject: [PATCH] Use Arc instead of String --- generate.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/generate.sh b/generate.sh index 78332af..25659d0 100755 --- a/generate.sh +++ b/generate.sh @@ -94,6 +94,9 @@ cp patches/tags.rs src/models echo "pub mod tags;" >> src/models/mod.rs sed -i 's/tags: Vec/tags: Vec/g' src/models/*.rs +sed -Ei 's/(:[a-zA-Z0-9 \-_<>]*)String/\1std::sync::Arc/g' src/models/*.rs +sed -Ei 's/serde = "(.*)"/serde = {version = "\1", features = ["rc"]}/g' Cargo.toml +sed -Ei 's/#\[derive\((.*)(, )?Default(, )?/#[derive(\1/g' src/models/*.rs echo "" >> Cargo.toml echo "[dependencies.log]" >> Cargo.toml echo "version = \"0.4\"" >> Cargo.toml