# Changing Lua references



## SWIFTYLIFT (Apr 26, 2022)

I’ve learned Lua versions are indeed versions and installed 54 when it looks like I need 51:  How do I go about locating all 54 and removing them and anything that would be left thinking of it?  

This includes  Luasec luarocks - pretty much anything that ends in 54 and move properly to 51.


----------



## Alain De Vos (Apr 26, 2022)

I have in make.conf specified the lua version explicitly. You can change it to 5.1

```
DEFAULT_VERSIONS+=lua5=5.4
DEFAULT_VERSIONS+=lua=5.4
```


----------



## SirDice (Apr 26, 2022)

SWIFTYLIFT said:


> How do I go about locating all 54 and removing them and anything that would be left thinking of it?


Look at the list from `pkg info -r lua54` for example. That will give you a list of all ports that depend on lang/lua54.


----------



## T-Daemon (Apr 26, 2022)

SWIFTYLIFT said:


> How do I go about locating all 54 ...


`pkg info -x lua54`


SWIFTYLIFT said:


> ... and removing them and anything that would be left thinking of it?


`pkg delete -R -g 'lua54*'`

See pkg-delete(8) for option details.


----------



## SWIFTYLIFT (May 11, 2022)

Thanks - think I’ve read pkg-delete enough to write it by memory at this point.  Here is the output from the suggested commands:

 pkg info -x lua54
pkg: No package(s) matching lua54
pkg delete -R -g 'lua54*'
No packages matched for pattern 'lua54*'

Checking integrity... done (0 conflicting)
1 packages requested for removal: 0 locked, 1 missing


—- if I try to use prosodyctl shell I get the following (I was able to get much more detail when I attempted to use the prosody admin telnet console (module:load) but cannot remember which module.. 

prosodyctl shell
** LuaSocket unix socket support not available or incompatible, ensure your
** version is up to date.

Here’s my lua info: 

lua52-luasocket-3.0.r1_5,1     Socket support for the Lua language

This is driving me to drinking and close to abusing my laptop when I hear it complain like this..


----------



## SWIFTYLIFT (May 11, 2022)

Alain De Vos said:


> I have in make.conf specified the lua version explicitly. You can change it to 5.1
> 
> ```
> DEFAULT_VERSIONS+=lua5=5.4
> ...


Ooh - trying that now - didn’t have the second entry


----------

