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

[Geanylua] geany.choose doesn't list all files #1374

Closed
Johnmcenroyy opened this issue Sep 23, 2024 · 9 comments
Closed

[Geanylua] geany.choose doesn't list all files #1374

Johnmcenroyy opened this issue Sep 23, 2024 · 9 comments

Comments

@Johnmcenroyy
Copy link

Johnmcenroyy commented Sep 23, 2024

There is an example:
https://github.com/geany/geany-plugins/blob/master/geanylua/examples/info/list-open-files.lua

It gets info about all opened files in Geany and open this list in new tab of Geany or lists them in choose menu.
List in new tab works as expected but geany.choose function not - it lists only two first opened files.

@elextr
Copy link
Member

elextr commented Sep 24, 2024

Please note that Geanylua is orphaned and so unmaintained.

@Johnmcenroyy
Copy link
Author

@elextr yes, I know but maybe someone knows why this happened, will try to find myself also, but how I understand it is better to move to Peasy plugin (just compiled) with Libpeas support. Is Geanylua planned to be removed from Geany plugins ?

@Johnmcenroyy
Copy link
Author

Overall good simple plugin, but pity seems not all work.

@elextr
Copy link
Member

elextr commented Sep 24, 2024

Well clearly nobody needs it urgently enough to be willing to support it.

There is no specific policy for removing plugins from the plugins collection, in fact sometimes the threat of removal results in individual PRs to keep an almost dead plugin going (usually something like moving to a new library version as happened to Geanylua and whatever changes that needs). But that is individual PRs, it often does not result in a rush of offers to take up ownership of the plugin.

I don't know how many geanylua issues there are, but in the past many scripts have worked just fine, guess they didn't use your troublesome function. So that makes it even harder to let it go, even if its no longer perfect. I suspect it will limp along until either some major issue occurs or the oldest version of lua that is provided by distros is not compatible with the newest version of lua that geanylua uses. Or a white knight thunders in on a massive horse and takes over maintenance. 🏇

Merging Peasy to Geany-plugins is an issue because Peasy uses its own compile and build system, not Autotools. And also if the creator does not want to include it in Geany-plugins thats entirely their right, and its not unusual. Of course "somebody" could make a copy of Peasy and include it in Geany-plugins, thats GPL, but having done that for a plugin in the past myself, I would say its not a happy position to be, even if the originator didn't mind.

Unfortunately for Peasy it appears only Arch AUR seems to supply it as a package, not Ubuntu and dependants or Fedora (dunno about Debian, the package search is down, but its likely that Ubuntu would have it if Debian did). So Peasy is not really an option for those who don't compile stuff even though its a technical improvement.

@Johnmcenroyy
Copy link
Author

@elextr Ok, understood. Thanks for info. Peasy works fine in Arch, but like also Geanylua for more simplicity.

@Skif-off
Copy link
Contributor

@Johnmcenroyy, how many files? I haven't noticed any such problems yet.
(I use the patch from Issue 690, but I'm not sure it matters.)

P.S. But geany.activate has problem.

@Johnmcenroyy
Copy link
Author

Johnmcenroyy commented Sep 29, 2024

@Skif-off Only two files appear in choose dialog no matter how much files are opened in Geany - 3 or 7 etc.
in this script list-open-files.lua

This simple script is the same:

#! /usr/bin/env lua

files = {"file1","file2","file3","file4","file5"}

for i = 1, 5 do
  geany.status(files[i])
end

geany.choose("Choose your file:", files)

geany.status works as expected - in messages window there are all files
geany.choose lists only file1 and file2

@Johnmcenroyy
Copy link
Author

@Skif-off It seems that all files appear in Geany.choose it is just two lines always with scroll.
It seems that patch can solves it. Thanks for info.

@Johnmcenroyy
Copy link
Author

I confirm that this #690 (comment) patch solves this issue.

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

No branches or pull requests

4 participants