File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -12,6 +12,3 @@ tokio = { version = "1.47.1", features = ["full"] }
1212zip = " 4.5.0"
1313toml = " 0.9.5"
1414chrono = " 0.4.42"
15-
16- [env ]
17- Config-version = " V1"
Original file line number Diff line number Diff line change @@ -8,8 +8,6 @@ use std::{
88#[ derive( Deserialize , Serialize , Debug , Clone ) ]
99#[ serde( default ) ]
1010pub struct Config {
11- pub config_version : String ,
12-
1311 /// Path to the folder containing the mod jar's
1412 pub target_path : PathBuf ,
1513
@@ -34,7 +32,6 @@ pub struct Config {
3432impl Default for Config {
3533 fn default ( ) -> Self {
3634 Self {
37- config_version : std:: env:: var ( "Config-version" ) . expect ( "Something went very wrong because why doesnt a config version exist" ) ,
3835 target_path : Path :: new ( "." ) . into ( ) ,
3936 server_version : String :: new ( ) ,
4037 loader_version : String :: new ( ) ,
@@ -63,6 +60,7 @@ impl Config {
6360
6461 let mut parsed_config: Self = toml:: from_str ( & input_str) . unwrap ( ) ;
6562 parsed_config. path = path. as_ref ( ) . to_path_buf ( ) ;
63+ parsed_config. save ( ) ?;
6664
6765 Ok ( parsed_config)
6866 }
You can’t perform that action at this time.
0 commit comments