clockworklabs / SpacetimeDB

Multiplayer at the speed of light
https://spacetimedb.com
Other
4.41k stars 110 forks source link

Directory structure impl #1879

Closed coolreader18 closed 1 week ago

coolreader18 commented 1 month ago

Description of Changes

Implements the new directory structure proposal, using strongly-typed newtypes to represent paths. All places in the database/server/cli that previously would have been passing around PathBufs and .join()ing them now instead pass around these types, calling methods on them that internally call .join() and return another strongly-typed child node in the directory hierarchy.

Changes from the proposal implemented here:

Changes that are not directly related to that, but facilitate it:

mamcx commented 4 weeks ago

Some other nits:

mamcx commented 3 weeks ago

Question: Is for a later pr the changes to the scripts:

?

coolreader18 commented 3 weeks ago

I think so - someone mentioned that they aren't really used anymore, anyway.

bfops commented 3 weeks ago

@coolreader18 Two things:

  1. Can you update the PR description to have all the usual details?

  2. Is it possible/reasonable to split this into one PR that does the internal refactor and switches everything to use strongly-typed paths, and a separate PR that changes the user-facing behavior and moves the files into the new paths? I'm having trouble figuring out what's happening where, and I'm worried I'll miss something.