rojo-rbx / rojo

Rojo enables Roblox developers to use professional-grade software engineering tools
https://rojo.space
Mozilla Public License 2.0
947 stars 179 forks source link

Add rojo open #896

Open nezuo opened 6 months ago

nezuo commented 6 months ago

Closes #305.

nezuo commented 6 months ago

My current thoughts on the API:

rojo open <PROJECT_FILE>

Flags: --output (-o) <PATH>: Builds the place from scratch and output it at <PATH>. --place (-p) <PATH_OR_CLOUD_PLACE_ID>: Opens an existing place, doesn't build anything from scratch and doesn't skip the initial sync.

--output and --place can't both be specified.

I also want a flag to skip initial sync even with --place. I have projects that are fully managed but part of the build step uses Lune. This means I have existing place files that I can't build from scratch with Rojo but I still want to skip the initial sync. I'm worried that this flag might introduce confusion for users and I don't know what to call it.

Thoughts?

nezuo commented 6 months ago

One flaw with injecting a StringValue is that if the user opens an existing place and doesn't save it, the next time they open it the StringValue will still be there.

Maybe existing places shouldn't automatically connect? That would be really unfortunate.

Yumacide commented 2 months ago

Rojo saves previous hosts/ports you've connected to. When we generate a port, we don't want that to be saved.

It might be better not to randomize the port then. The behavior shouldn't be different from rojo serve.