Make the name field in projects optional (#870)

Closes #858.

If a project is named `default.project.json`, it acts as an `init` file
and gains the name of the folder it's inside of. If it is named
something other than `default.project.json`, it gains the name of the
file with `.project.json` trimmed off. So e.g. `foo.project.json`
becomes `foo`.
This commit is contained in:
Micah
2024-02-20 17:25:57 -08:00
committed by GitHub
parent 42121a9fc9
commit 48bb760739
27 changed files with 486 additions and 32 deletions

View File

@@ -62,6 +62,9 @@ gen_build_tests! {
sync_rule_alone,
sync_rule_complex,
sync_rule_nested_projects,
no_name_default_project,
no_name_project,
no_name_top_level_project,
}
fn run_build_test(test_name: &str) {
@@ -73,7 +76,7 @@ fn run_build_test(test_name: &str) {
let output_path = output_dir.path().join(format!("{}.rbxmx", test_name));
let output = Command::new(ROJO_PATH)
.args(&[
.args([
"build",
input_path.to_str().unwrap(),
"-o",