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

invalid order function for sorting #124

Open
maksimaliabyshev opened this issue Sep 25, 2024 · 7 comments
Open

invalid order function for sorting #124

maksimaliabyshev opened this issue Sep 25, 2024 · 7 comments

Comments

@maksimaliabyshev
Copy link
Contributor

PowerShell console:

lpm install plugin_manager language* lsp* ide* Widgets nodejs  --assume-yes --progress

Error invalid order function for sorting

@adamharrison
Copy link
Member

Interesting. Will investigate.

@adamharrison
Copy link
Member

Hrm. I don't get this on current master. (You though Widgets here is inappropriately capitalized). It must be on windows only. Will check when I next boot into it.

@maksimaliabyshev
Copy link
Contributor Author

Hrm. I don't get this on current master. (You though Widgets here is inappropriately capitalized). It must be on windows only. Will check when I next boot into it.

  1. The plugin manager should not abort the installation if a package does not meet some criteria.
  2. invalid order function for sorting - sorts the list incorrectly if there is a non-valid packet in the queue.

@adamharrison
Copy link
Member

The plugin manager should not abort the installation if a package does not meet some criteria.

I mean, in most cases, unless the full install is correctly specified (like in apt for example), it does result in things aborting usually.

invalid order function for sorting - sorts the list incorrectly if there is a non-valid packet in the queue.

Can you elaborate? What do you mean by "packet" here? Like if Widgets is given?

@maksimaliabyshev
Copy link
Contributor Author

maksimaliabyshev commented Oct 14, 2024

Can you elaborate? What do you mean by "packet" here? Like if Widgets is given?

Widgets - a non-valid plugin/package that does not exist.
non-valid plugin/package - any package/plugin that cannot recognize or install lpm.

lpm install plugin1 bad_plugin plugin2 --assume-yes --progress - lpm will stop installing after bad_plugin, but should output an error message to stdout and continue installing subsequent plugins.

@adamharrison
Copy link
Member

adamharrison commented Oct 14, 2024

OK; so for example, when I test this, I get:

adam@aurora:~/lite-xl/lite-xl-plugin-manager$ ./lpm install plugin_manager  Widgets nodejs  --assume-yes --progress --userdir /tmp/test 
   2.3 MB [   7.2 MB/s][100%]: Fetching https://github.com/lite-xl/lite-xl-plugin-manager.git:latest...
 340.5 kB [   4.2 MB/s][100%]: Fetching https://github.com/lite-xl/lite-xl-plugins.git:master...
  47.4 kB [   1.4 MB/s][100%]: Fetching https://github.com/lite-xl/lite-xl-colors.git:master...
  47.6 kB [   1.2 MB/s][100%]: Fetching https://github.com/jgmdev/lite-xl-threads:9299a9a6b778cb34b12f0286b9162779920a9197...
can't find addon Widgets

Which seems to be what you want? I'm not sure where the invalid sorting function is coming from though; it could be dependent on your setup. Can you try with master? Are you using ppm instead?

Regarding not installing after a bad plugin, I think this is the correct move. It shouldn't install anything if the command given cannot be resolved.

This is something you can potentially modify in the ppm repository, but I think in lpm it makes sense to keep it as atomic as possible -- in line with other package managers that I've used, like apt-get.

@maksimaliabyshev
Copy link
Contributor Author

ppm repository

I'm sorry, I was a little mistaken. Please run the command from the first post on Windows, after installing via Scoop.

scoop install lite-xl --global
scoop install https://raw.githubusercontent.com/lite-xl/lite-xl-plugin-manager/refs/heads/master/lite-xl-plugin-manager.json --global

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

No branches or pull requests

2 participants