Skip to content

MacOS : lpm doesn't seem to work #156

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

Open
rom100main opened this issue Jan 16, 2025 · 6 comments
Open

MacOS : lpm doesn't seem to work #156

rom100main opened this issue Jan 16, 2025 · 6 comments
Labels

Comments

@rom100main
Copy link

rom100main commented Jan 16, 2025

A lot of commands seem to not work on MacOS, here some I tested

lpm install plugin_manager --assume-yes --verbose
lpm.lua:1621: attempt to index a nil value (field 'integer index')
stack traceback:
	lpm.lua:1621: in method 'all_addons'
	lpm.lua:1697: in method 'get_addon'
	lpm.lua:1927: in field 'retrieve_addons'
	lpm.lua:2007: in field 'install'
	lpm.lua:2317: in field 'command'
	lpm.lua:2340: in field 'run'
	lpm.lua:2859: in function <lpm.lua:2858>
	[C]: in field 'flock'
	lpm.lua:555: in upvalue 'engage_locks'
	lpm.lua:2858: in function <lpm.lua:2374>
	[C]: in function 'xpcall'
	lpm.lua:2374: in main chunk
lpm self-upgrade --verbose
lpm.lua:2210: cannot get undefined global variable: EXEFILE
stack traceback:
	[C]: in function 'error'
	lpm.lua:3: in metamethod 'index'
	lpm.lua:2210: in field 'self_upgrade'
	lpm.lua:2847: in function <lpm.lua:2374>
	[C]: in function 'xpcall'
	lpm.lua:2374: in main chunk
lpm upgrade --verbose
lpm.lua:1621: attempt to index a nil value (field 'integer index')
stack traceback:
	lpm.lua:1621: in method 'all_addons'
	lpm.lua:1650: in method 'installed_addons'
	lpm.lua:2200: in function <lpm.lua:2199>
	(...tail calls...)
	lpm.lua:2340: in field 'run'
	lpm.lua:2859: in function <lpm.lua:2858>
	[C]: in field 'flock'
	lpm.lua:555: in upvalue 'engage_locks'
	lpm.lua:2858: in function <lpm.lua:2374>
	[C]: in function 'xpcall'
	lpm.lua:2374: in main chunk

I installed LiteXL with the official downloader

I installed lpm with this command in my Download folder
wget https://github.com/lite-xl/lite-xl-plugin-manager/releases/download/latest/lpm.aarch64-darwin -O lpm && chmod +x lpm

lpm --version gives me -aarch64-darwin, I don't know if it is the right behaviour. My version is this one.

Since the command to get the plugin manager doesn't work I installed it manually but putting in ~/config/lite-xl/plugin_manager init.lua, lpm.aarch64-darwin and plugin_view.lua.
Inside Lite XL installing a plugin work, upgrading seems to also work.
But adding a repo doesn't
Capture d’écran 2025-01-16 à 10 55 59

@adamharrison
Copy link
Member

Hrm. Odd. I'll review this. I'm going to be releasing a new verison of lpm which may solve of these problems soon anyway. The issue I don't really have a mac to test on, and apple just nuked the tool that was letting non-mac developers test mac software, so there's no good way to test it on mac at the moment for me.

But when I release the new version, let's try that, and see if it helps.

@rom100main
Copy link
Author

I'm back

I tested the new version (177167f) and it seems everything is now working except lpm self-upgrade which gives me now this error :

./lpm self-upgrade --verbose                       
lpm.lua:2232: cannot get undefined global variable: EXEFILE
stack traceback:
	[C]: in function 'error'
	lpm.lua:4: in metamethod 'index'
	lpm.lua:2232: in field 'self_upgrade'
	lpm.lua:2950: in function <lpm.lua:2467>
	[C]: in function 'xpcall'
	lpm.lua:2467: in main chunk

@adamharrison
Copy link
Member

Well, I'm glad it's at least mostly working.

And yeah, I think I see the issue with this one. I pulled the logic from lxl, but mac actually has different logic to determine final location.

I'll just copy that logic over for the next release. Might be able to get around to it today.

@adamharrison
Copy link
Member

OK. This should be handled as of b1a1e27. Can you verify on the continuous release?

@rom100main
Copy link
Author

Sadly I get the same error on d7cead3
It seems the if/else doesn't work

@adamharrison
Copy link
Member

Huh. If you stick #error test in the __APPLE__ block, and then compile, does it crash your compile?

@Guldoman Guldoman added the mac label May 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants