@@ -79,7 +79,6 @@ def sdk_setup(self, path: Path):
79
79
80
80
def _publish (self ) -> Path :
81
81
base_path = Path (self .enterClassContext (tempfile .TemporaryDirectory ()))
82
-
83
82
server_path = base_path / "server"
84
83
self .project_path = server_path
85
84
self .config_path = server_path / "config.toml"
@@ -92,6 +91,7 @@ def generate_server(self, server_path: Path):
92
91
"""Generate the server code from the quickstart documentation."""
93
92
logging .info (f"Generating server code { self .lang } : { server_path } ..." )
94
93
self .spacetime ("init" , "--lang" , self .lang , server_path , capture_stderr = True )
94
+ shutil .copy2 (STDB_DIR / "rust-toolchain.toml" , server_path )
95
95
# Replay the quickstart guide steps
96
96
_write_file (server_path / self .server_file , _parse_quickstart (self .server_doc , self .lang ))
97
97
self .server_postprocess (server_path )
@@ -166,7 +166,7 @@ def project_init(self, path: Path):
166
166
capture_stderr = True )
167
167
168
168
def sdk_setup (self , path : Path ):
169
- sdk_rust_path = (STDB_DIR / "crates/sdk " ).absolute ()
169
+ sdk_rust_path = (STDB_DIR / "sdks/rust " ).absolute ()
170
170
sdk_rust_toml_escaped = str (sdk_rust_path ).replace ('\\ ' , '\\ \\ \\ \\ ' ) # double escape for re.sub + toml
171
171
sdk_rust_toml = f'spacetimedb-sdk = {{ path = "{ sdk_rust_toml_escaped } " }}\n log = "0.4"\n hex = "0.4"\n '
172
172
_append_to_file (path / "Cargo.toml" , sdk_rust_toml )
0 commit comments