Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat(plugins): Install and update plugins within ES #64

Closed
wants to merge 277 commits into from

Conversation

RisingLeaf
Copy link
Member

Feature Details

endless-sky#9058 -> Discussion
endless-sky#707 -> Issue that requests this.
RFC -> RFC from the issue

This pull request implements a feature that is supposed to make plugins easier to install and update, cause with this PR, you can do it in game (requires a restart though, don't annoy me with details).

What I am doing is downloading this json file via curl, parsing it with the nlohmann json library and extract all necessary data about the plugins, they are then displayed in a new sub tab of the plugins menu, where you can install them, which happens over curl and libarchive.

After a quick restart the plugin will then be available.

To update a plugin one again has to go to the sub tab, navigate to the plugin and press "update", the name of the plugin will be yellow if it is outdated, which deletes the plugin directory and downloads it again.

Pages for the list are already implemented,with buttons to switch between them.

The json file gets updated everytime you open the preferences panel, as long as you have an active internet connection.

UI Screenshots

2023-07-28_10-25

Testing Done

linux, yes
mac, yes
windows, yes, thx quyykk

Automated Tests Added

No?

Performance Impact

N/A

TODO List:

  • Download the json file every time ES gets opened
  • Think about life, then remove gitlib2 and just download zips (people will probably have to force me to that)
  • Make the UI look nice
  • Add buttons for the pages so that people dont have to know that "e" and "r" switch pages
  • polish
  • limit file size

now for delta cause why not?

@Zitchas
Copy link
Member

Zitchas commented Jul 21, 2024

Is this fully up to date? Just looking at the changed files, GitHub is saying there are 205 of them, and a lot of it is stuff that I am fairly sure it's other PRs, not yours. Not really sure what GitHub is doing with them, but it makes it hard to examine.

@RisingLeaf
Copy link
Member Author

There is definitely something broken going on. Is delta up to date with master?

@Zitchas
Copy link
Member

Zitchas commented Jul 22, 2024

It was when I last posted, but it's currently out of date with the most recent set, which have a few conflicts. If they're simple I can take care of it now. If they're not... Should be able to within the next 48h unless they're really bad.

edit: the conflict was so minor as to make me wonder why it was one at all. Basically just a conflict with the fact that our experiment completing Sol had the planet Uranus created in the same spot of the map file as an Incipias planet. So just an extremely minor conflict resolution to ensure both are kept. It'll be merged as soon as the checks are complete.

@Zitchas
Copy link
Member

Zitchas commented Jul 22, 2024

Regarding the conflict with the keys panel.png, just choose to overwrite with yours. When I merge I will do a follow up with any changes needed to keep things looking good (if necessary).

(and Delta is now up to date with upstream once again)

@Zitchas
Copy link
Member

Zitchas commented Jul 22, 2024

Just looking through the changelist, and it looks like almost every change that has happened to upstream in the several months, maybe longer. My only idea is that the conflict is causing github to rollback to the last place in Delta's history that this PR wouldn't conflict with, and display the diff based on that.

As mentioned in my previous post, I'm good this PR overwriting the keys panel.png. I have access to the old files (and svg if necessary to recreate things), so best case, it works with your ovewritten version (which I think it might, but not 100%), and worst case, I have to do a follow up PR to resolve the panels. I'm good with that too. But I'll know better once I can see a proper diff.

@warp-core
Copy link

Something about the way GitHub handles PRs seems to just lead it to not really update the diff when the same commits are applied to both the head and base branches after the PR is opened.
If you start the process of opening a new PR with these same branches, you can see it only shows 176 commits and 17 changed files with 801 additions and 34 deletions (at the moment).

@Zitchas
Copy link
Member

Zitchas commented Jul 22, 2024

Interesting observation. I'm fairly sure I've seen it resolved somewhere in the past, but not sure how.

@RisingLeaf
Copy link
Member Author

I might just try to open a new one

@RisingLeaf RisingLeaf closed this Jul 23, 2024
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.

None yet