summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormo8it <mo8it@proton.me>2024-04-07 23:57:54 +0200
committermo8it <mo8it@proton.me>2024-04-07 23:57:54 +0200
commit394ca402a8883581dc040546b4ca18b07d76a7f2 (patch)
treebc2725f234fc73d740c0b5179a198589b1cd27a5 /src
parentdb25cc91576a05b02edd3754df85eb5668cec83f (diff)
Remove the info_toml_content field
Diffstat (limited to 'src')
-rw-r--r--src/embedded.rs1
-rw-r--r--src/exercise.rs2
2 files changed, 1 insertions, 2 deletions
diff --git a/src/embedded.rs b/src/embedded.rs
index 56b4b61..1e2d677 100644
--- a/src/embedded.rs
+++ b/src/embedded.rs
@@ -65,7 +65,6 @@ struct ExercisesDir {
}
pub struct EmbeddedFiles {
- pub info_toml_content: &'static str,
exercises_dir: ExercisesDir,
}
diff --git a/src/exercise.rs b/src/exercise.rs
index ae47d5e..c9fb331 100644
--- a/src/exercise.rs
+++ b/src/exercise.rs
@@ -52,7 +52,7 @@ impl InfoFile {
if let Ok(file_content) = fs::read_to_string("info.toml") {
toml_edit::de::from_str(&file_content)
} else {
- toml_edit::de::from_str(EMBEDDED_FILES.info_toml_content)
+ toml_edit::de::from_str(include_str!("../info.toml"))
}
.context("Failed to parse `info.toml`")
}