Skip to content

Conversation

@vramaiah
Copy link

@vramaiah vramaiah commented Oct 2, 2025

This pulls upon the work here: #464 and enables a command line install.

Closes #11.

@vramaiah vramaiah closed this Oct 2, 2025
@vramaiah vramaiah reopened this Oct 2, 2025
@vramaiah vramaiah closed this Oct 2, 2025
@vramaiah vramaiah reopened this Oct 2, 2025
@calcmogul
Copy link
Member

You don't need to close and reopen the PR btw.

@vramaiah vramaiah requested a review from calcmogul October 2, 2025 21:52
@sciencewhiz
Copy link
Contributor

This has not been tested though,

Please mark the PR as draft until you've had a chance to test.

@vramaiah vramaiah marked this pull request as draft October 2, 2025 23:13
@vramaiah
Copy link
Author

vramaiah commented Oct 3, 2025

This has not been tested though,

Please mark the PR as draft until you've had a chance to test.

How should I test this?

@calcmogul
Copy link
Member

Run the installer with the CLI flags.

@vramaiah
Copy link
Author

vramaiah commented Oct 5, 2025

After testing, I have realized that VSCode is not being properly installed.

@vramaiah vramaiah marked this pull request as draft October 15, 2025 00:45
@vramaiah
Copy link
Author

I chose to make each installation function refactored into its own class. I also made the InstallPageViewModel class an observer, following the design pattern, which is how I ended up ensuring that progress can be displayed.

@vramaiah
Copy link
Author

vramaiah commented Nov 11, 2025

An example of how the class for gradle installing can be used:

                    // Install Gradle
                    {
                        ProgressTotal = 11;
                        TextTotal = "Installing Gradle";
                        GradleSetupTask task = new GradleSetupTask(
                            configurationProvider
                        );

                        task.Attach(this);
                        await task.Execute(token);
                        if (token.IsCancellationRequested) break;
                        task.Detach(this);
                    }

The braces are to make task scoped

@calcmogul
Copy link
Member

I assume the deduplication still needs to be done? That refactor ended up adding more code than it removed. Also, this PR needs to have main merged into it to fix conflicts.

@vramaiah
Copy link
Author

I assume the deduplication still needs to be done?

yeah, I haven't actually removed duplicate code from CLI, only the GUI installer.

Also, this PR needs to have main merged into it to fix conflicts.

I might do that on Thanksgiving week, when I have more time

@vramaiah
Copy link
Author

vramaiah commented Nov 13, 2025

I actually didn't merge properly; merging this is going to be hard because this has been made for so long.

There are currently 11 new commits, and since I completely refactored the installation process...

@vramaiah
Copy link
Author

Is there any way to uncommit the merge commit?

@calcmogul
Copy link
Member

calcmogul commented Nov 13, 2025

Option 1:
Find the commit from before the merge in git reflog's output, then git reset --hard commit-hash.

Option 2:
git revert -m N commit-hash where N is the parent you want to revert to and commit-hash is the commit hash of the merge commit.

@vramaiah
Copy link
Author

vramaiah commented Nov 14, 2025

I committed it from github web merge. Oh well.
EDIT: I seem to have removed it?

@vramaiah vramaiah marked this pull request as ready for review November 15, 2025 18:38
@vramaiah
Copy link
Author

It's finally done!

@vramaiah vramaiah requested a review from calcmogul November 15, 2025 18:44
@calcmogul
Copy link
Member

calcmogul commented Nov 15, 2025

I appreciate the time and effort you've put into this PR so far. However, I don't think it's taking the correct approach. The installer on the main branch is 3.5k lines of C# code, and this PR adds another 1.2k (34%) to implement what should ostensibly be up to 200 lines calling existing functions in a noninteractive, headless context. In my opinion, this PR currently adds repetitive boilerplate and technical debt we wouldn't want to merge and thus be responsible for maintaining.

Even if this PR were in a better state, we're now too close to the 2026 season to merge a change this large into a piece of infrastructure so central; it wouldn't get the amount of testing such a change warrants, so the risk is too high.

Given our installer requirements are changing for 2027 and beyond to serve both FRC and FTC, we're looking at replacing the Avalonia installer with something more standard like the Qt installer framework. See
2027 (view) and the Chief Delphi thread it links to for more discussion about it.

@Oblarg
Copy link

Oblarg commented Nov 15, 2025

It looks like you've used AI to help draft this - that's fine, i'm totally in favor of AI assistance in coding. However, AI is really bad at code factoring/normalization, and we cannot/will not relax code standards to expect less than handwritten and properly-deduplicated code.

I suggest giving this a comprehensive refactor pass; you should be able to reduce the number of LOC substantially, and make it read a lot more succinctly, without affecting the functionality.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add option for running by CLI args

6 participants