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

Lua 5.4 support in rockspec #22

Merged
merged 2 commits into from Oct 5, 2020
Merged

Lua 5.4 support in rockspec #22

merged 2 commits into from Oct 5, 2020

Conversation

leafo
Copy link
Contributor

@leafo leafo commented Oct 2, 2020

I decided to just bump the rockspec revision since the library already seems to work fine with no changes. I did notice the VERSION value was wrong though, so we could consider a minor version bump as well.

@leafo
Copy link
Contributor Author

leafo commented Oct 2, 2020

After this is merged the new rockspec should be uploaded to luarocks.org.

Currently if you try to install date with luarocks for 5.4 you get a very old version installed that had an unrestricted lua_version value

@Tieske Tieske merged commit a5c8be9 into Tieske:master Oct 5, 2020
@Tieske
Copy link
Owner

Tieske commented Oct 5, 2020

thx @leafo rock was uploaded, let me know if something is missing

@Tieske
Copy link
Owner

Tieske commented Oct 5, 2020

well that didn't work...

Thijss-MacBook:date thijs$ luarocks install date
Installing https://luarocks.org/date-2.1.2-3.src.rock

date 2.1.2-3 depends on lua >= 5.0, < 5.5 (5.1-1 provided by VM)

Error: Build error: Failed installing src/date.lua in /usr/local/Cellar/openresty@1.15.8.3/1.15.8.3/luarocks/lib/luarocks/rocks-5.1/date/2.1.2-3/lua/date.lua: src/date.lua: No such file or directory
Thijss-MacBook:date thijs$

@Tieske
Copy link
Owner

Tieske commented Oct 5, 2020

beats me...

$ luarocks pack date-2.1.2-3.rockspec
Packed: /Users/thijs/code/date/date-2.1.2-3.src.rock
$ luarocks install date-2.1.2-3.src.rock

date 2.1.2-3 depends on lua >= 5.0, < 5.5 (5.1-1 provided by VM)

Error: Build error: Failed installing src/date.lua in /usr/local/Cellar/openresty@1.15.8.3/1.15.8.3/luarocks/lib/luarocks/rocks-5.1/date/2.1.2-3/lua/date.lua: src/date.lua: No such file or directory
$

(LuaRocks 3.3.1)

@leafo
Copy link
Contributor Author

leafo commented Oct 5, 2020

https://luarocks.org/modules/tieske/date

it looks like the new revision wasn't uploaded, I only see revision 2 here and not 3. How did you upload it? Maybe bug prevented it from going up?

@Tieske
Copy link
Owner

Tieske commented Oct 6, 2020

I removed it again, since it fails to install, but haven't figured out why it fails (see msgs above)

@leafo
Copy link
Contributor Author

leafo commented Nov 20, 2020

Not sure what happened but I pushed the latest version to the module owned by your account. It appears to be working https://luarocks.org/modules/tieske/date/2.1.2-3

@leafo
Copy link
Contributor Author

leafo commented Nov 20, 2020

Actually it's still broken, but I see what's wrong. I'll have a fix in a moment

@leafo
Copy link
Contributor Author

leafo commented Nov 20, 2020

Okay so the issue is that you moved the source file to the src directory, and updated the versioned rockspec to the new path, but the version'd rockspec depends on the tar created by the tag which was created before things were moved. So the rockspec no longer works with the tag.

Generally on my projects I tend to run a -dev rockspec that is used to point to the master branch (using git checkout source mode), then when I'm ready to push a new version I'll copy that rockspec file as the base for the versioned one.

(Also it probably didn't look broken locally because it would looking at the current directory instead of installing for the tar file when using luarocks make).

I think to solve all this though a new version should just be pushed.

But in the meantime I've pushed a hotfixed rockspec to luarocks.org.

@Tieske
Copy link
Owner

Tieske commented Nov 21, 2020

pushed a new version. Thx for the troubleshooting!

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

2 participants