Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Apr 08 20:57
    hishamhm commented #1256
  • Apr 08 20:57

    hishamhm on master

    fs.win32: Do not revoke permiss… (compare)

  • Apr 08 20:57
    hishamhm closed #1256
  • Apr 08 19:29
    hishamhm synchronize #1256
  • Apr 08 18:12
    hishamhm closed #614
  • Apr 08 18:12
    hishamhm commented #614
  • Apr 08 18:03
    dragonxtek commented #614
  • Apr 07 14:36
    hoylemd commented #1295
  • Apr 06 21:58
    hishamhm closed #1099
  • Apr 06 21:58
    hishamhm commented #1099
  • Apr 06 21:55
    hishamhm commented #1295
  • Apr 06 21:47
    carlsmedstad commented #1099
  • Apr 06 21:46
    carlsmedstad commented #1099
  • Apr 06 20:49
    hishamhm commented #1298
  • Apr 06 20:48

    hishamhm on master

    tests: add basic test for XDG_C… (compare)

  • Apr 06 20:26
    carlsmedstad commented #1298
  • Apr 06 20:24

    hishamhm on master

    Set cfg.home_tree even for root… Simplify the code in set_confdi… Respect the environment variabl… and 2 more (compare)

  • Apr 06 20:24
    hishamhm closed #1298
  • Apr 06 20:24
    hishamhm closed #1219
  • Apr 06 20:24
    hishamhm closed #1086
ryanford-dev
@ryanford-dev
oops. i see i have a discrepency in bin/jsmin vs bin/jsmin.lua but it didn't seem to matter in my previous trials
ryanford-dev
@ryanford-dev
hmm maybe that's exactly what it was :see_no_evil:
Andrew Starks
@andrewstarks

Hey all! First time using Gitter and my first time posting here...

I seem to remember a way to make a self-contained Lua environment, plus all required rocks, in a development directory. That way, testing and debugging is happening in an isolated environment.

I saw hererocks, but I don't think that's what I used. I thought it was some magic trick that I could perform using luarocks. Did I imagine that or is that a feature that I'm failing to find documentation for?

1 reply
Caleb Maclennan
@alerque
@andrewstarks I typically use luarocks --tree to manually specify a project local directory to install dependencies to, then add that to my code's search path.
Wil Thomason
@wbthomason
Hi! I'm currently adding LuaRocks support to a plugin manager for Neovim (https://github.com/wbthomason/packer.nvim), and want to add a mechanism for plugin authors to specify which rocks they need installed. However, because these plugins won't be on https://luarocks.org/, and also because I'm new to LuaRocks myself, I'm not sure if it's better to have plugin authors use a rockspec for this, or just have a file listing the rocks they need
Is rockspec appropriate for this use?
Michael Esch
@slipsnip_gitlab
New to lua and luarocks my debian bullseye system only supports luarocks 2.4.2, I wish to install two rocks luasocket and mobdebug for debugging which I did using luarocks install mobdebug --local however upon inspection it appears any rock I install is for lua5.1 and not what I wish to use lua 5.4 after some diging on the wiki for luarocks there appears to be an option --lua-version=5.4 to spesify which version to use as i can verify lua 5.4.2 is installed on my system but none of the installed rocks exist, instead they appear to install to $HOME/.luarocks/share/lua/5.1 my question is how can I force the use of 5.4, do I need to download the tarball for the latest luarocks and sudo make config install that? I would prefer not to do anything that the apt package manager in debian cannot track
Michael Esch
@slipsnip_gitlab
In followup to my question I was able to solve some problems while creating new ones, the lua.h header file for lua5.4 was missing from my system and sudo apt install liblua5.4-dev lua5.4 gives it to me at /usr/include/lua4.5/lua.h, though the old 2.4.2 version of luarocks seemed problematic still in installing the correct rock versions, so I uninstalled that and did a manual install of luarocks 3.5.0 which the ./config script seemed to agree with, it found the lua.h along with the binary and other dependancies. I did the system wide sudo make install but now when I attempt a luarocks --lua-version=5.4 --local install mobdebug I get Error: Failed finding Lua header files. You may need to install them or configure LUA_INCDIR. so it looks like my next step is configuring luarocks, not sure why its not finding the headers when the configure srcipt had no problems
Caleb Maclennan
@alerque

Is rockspec appropriate for this use?

@wbthomason Yes, I think it would be.

Wil Thomason
@wbthomason
@alerque Thanks!
pohchallenge
@pohchallenge
Hi, we would like to create own private package manager using luarocks, it seems that we need to setup a FTP for a rock server. Could someone please kindly share the details or documentations about how to configure/setup?
Vladislav Grubov
@orchaton
If you need rock server only to install your private libraries you may use just nginx and keep your rocks local to it. Or you may use github/gitlab pages to distribute manifest file and rocks. ex: https://moonlibs.github.io/rocks/
pohchallenge
@pohchallenge
Thanks, very appreciated
pohchallenge
@pohchallenge
Hi @orchaton, I am new with luarocks, I would like a bit more explaination, thanks in advance. 1. How to configure to distribute on page to list all rocks.2. Luarcoks-admin make-manifest is for one lua module, how to sync with the one that listed in the page.
iThorgrim
@iThorgrim-Hub
I have a small question: how to make an executable when you have a luarocks module? I search everywhere on the web and I can't find anything anywhere.
I have created an application in Lua with LuaRocks and I would like to distribute it but I don't know how to do it ..
Caleb Maclennan
@alerque
Your rockspec needs a install = { bin = { executable_name = "bin/executable_name" } } bit alongside your modules = ... declaration. Check out any existing project that does this. The busted project comes to mind as one that creates and installs an executable.
michal
@michal:kottman.xyz
[m]
Hello all, I was looking at creating a "standalone" lua/luajit + dependencies in a single folder, and found out that LuaDist/luadist.github.com@cc297b5 with LuaRocks being the recommendation. Is there a way to build lua/luajit with LuaRocks? I explicitly don't want to rely on the "system" binaries and modules.
Dennis Schridde
@devurandom
Hi! I am the owner of a rock that is currently in the root manifest. How can I swap my rock for another user's rock in the root manifest? I.e. I want xyz in the root manifest to no longer point at devurandom/xyz but to otheruser/xyz.
Dennis Schridde
@devurandom
P.S. Does LuaRocks know something like GitHub organisations? Ideally we would have a rock in the root manifest that collaboratively belongs to the same people that are in the corresponding GitHub organisation.
Caleb Maclennan
@alerque
@devurandom The LuaRocks site does not have any sort of org / team scoping (yet). It's one rock one maintainer. If what you are talking about is a fork situation that you as the original author approve of I think you can ping @hishamhm in here and he can re-parent it for you.
nasso
@nasso4991_twitter
hello! i am new to luarocks and i would like to know if its possible to integrate it to custom lua runtimes (other than a global installation)?
im working on a project that will extensively rely on user scripts written in Lua, and allowing the user to use rocks from the global luarocks registry would be awesome!
the thing is, my program comes with its own (bundled) lua implementation (currently it statically links to lua 5.3). how would the integration with luarocks be? is it even possible?
Alessandro Mecca
@protoboolean
QUESTION: luarocks install http fails because it can't find openssl/crypto.h. I'm on macOS, and I installed openssl and luarocks via Homebrew. I know I can specify the location of the .h files via an env variable, but this is the second time I have to do this manually and thought there might be a way to specify the search paths once and for all. I noticed luarocks config options: external_deps_dirs, external_deps_patterns, external_deps_subdirs, runtime_external_deps_patterns, etc. but I don't know what values to set to match Homebrew's installation tree (e.g. /usr/local/Cellar/openssl@1.1/1.1.1i/include/openssl/crypto.h). I find it tricky due to the version-numbers in the paths… Is there a tried and tested way to configure luarocks and/or homebrew so that they luarocks can automatically resolve the dependencies?
eladbs
@eladbs
Hi,
Quick question... I luarocks packed my module, run luarocks-admin make-manifest and uploaded the files to a web server.
I set this server in the config-5.1.lua file and luarocks search can find it.
when I try to luarocks install I get the error: Error: Couldn't extract archive which by the solved issues mean that my source.url in the rockspec isn't pointing to the right place.
The question is, why is it going to the source in the first place and not using the *.src.rock file in the "repo" that was created?
Thanks!
Hugo Soucy
@hs0ucy

Hi,

I made a copy of directory called sample with copy_directories, and now it's in my rock directory in lib ... after that with a command i would like to copy it in the $HOME directory ... Is there a way to do something like that? How to have access to this folder through my app?

Dennis Schridde
@devurandom
@alerque Thanks!
Hi @hishamhm! I am the owner of the devurandom/lualdap rock that is currently in the root manifest as lualdap (https://luarocks.org/modules/devurandom/lualdap). Could you please change the owner of that rock to @fperrad (https://luarocks.org/modules/fperrad)?
Thijs Schreijer
@Tieske
I'm trying to upload a rock to the luarocks repo, but it fails. I cannot use the commandline (the upload command only supports rockspecs, not rocks), adding the rock file via the GUI fails with "error: missing file". If I add both rockspec and rock in the gui, only the rockspec gets uploaded.
How to get around this?
@leafo any ideas?
eladbs
@eladbs
I managed to pack and publish rocks to our server. It turned out that I packed the src and rockspec instead of the "binary" rock.
Dennis Schridde
@devurandom
Hi @hishamhm ! @alerque mentioned that you could change the lualdap entry in the root manifest. Is that correct? Would you be able to assist us (@fperrad and me) with a transfer? See my post from 2021-02-03 just a few lines above: https://gitter.im/luarocks/luarocks?at=601a882a9238c531ad1fa81c
Thijs Schreijer
@Tieske
@devurandom you might have more luck sending an email
Wbertro
@HolterPhylo
Hi, new to luarocks. On win10 x64, I installed lua 5.4.2 and [[lua -e "print('hello world')"]] works fine. Trying to install luarocks. Donwloaded luarocks.exe for x64 and running it in x64 Native Tools Command Prompt for VS 2019 says Warning: Lua 5.3 interpreter not found at C:\temp
Wbertro
@HolterPhylo
Question is: Can luarocks support 5.4.2 or not? What config file information I need to setup, if any?
Wbertro
@HolterPhylo
or where better can I ask these questions?
Wbertro
@HolterPhylo
ok, made progress. luarocks is installed!

Why is luarocks saying : Error: unknown option '-e' when...
```Installing https://luarocks.org/luacheck-0.24.0-2.src.rock
Missing dependencies for luacheck 0.24.0-2:
argparse >= 0.6.0 (not installed)

luacheck 0.24.0-2 depends on lua >= 5.1 (5.3-1 provided by VM)
luacheck 0.24.0-2 depends on argparse >= 0.6.0 (not installed)
Installing https://luarocks.org/argparse-0.7.1-1.src.rock

argparse 0.7.1-1 depends on lua >= 5.1, < 5.5 (5.3-1 provided by VM)
argparse 0.7.1-1 is now installed in C:/Lua (license: MIT)

luacheck 0.24.0-2 depends on luafilesystem >= 1.6.3 (1.8.0-1 installed)
Usage: luarocks [-h] [--version] [--dev] [--server <server>]
[--only-server <server>] [--only-sources <url>]
[--namespace <namespace>] [--lua-dir <prefix>]
[--lua-version <ver>] [--tree <tree>] [--local] [--global]
[--verbose] [--timeout <seconds>] [--pin] [<command>] ...

Error: unknown option '-e'
Did you mean '-h'?
Usage: luarocks [-h] [--version] [--dev] [--server <server>]
[--only-server <server>] [--only-sources <url>]
[--namespace <namespace>] [--lua-dir <prefix>]
[--lua-version <ver>] [--tree <tree>] [--local] [--global]
[--verbose] [--timeout <seconds>] [--pin] [<command>] ...

Error: unknown option '-e'
Did you mean '-h'?
luacheck 0.24.0-2 is now installed in C:/Lua (license: MIT)```

meandmymind
@meandmymind

hello, guys. I use lua project with cpp library and build it with cmake

cmake installation goes well

Scanning dependencies of target xxx
[ 33%] Building CXX object CMakeFiles/xxx.dir/src/xxx.cc.o
[ 66%] Building CXX object CMakeFiles/xxx.dir/src/xxx.cc.o
[100%] Linking CXX shared library xxx.so
[100%] Built target xxx

and then I get error make: *** No rule to make target 'install'. Stop.

generated Makefile in fact does not contain target install

how is it possible?

relevant rockspec

build = {
    type= "cmake",
    install = {
        lib = {
            "./build.luarocks/xxx.so",
             ["xxx"]="./xxx/xxx",
             ["xxx"]="./xxx/xxx",
             ["xxx"]="./xxx/xxx",
             ["xxx"]="./xxx/xxx"
        }
    }
}

furthermore, I build my project in docker container, and when I run this same code with same docker image in CI target install is found normally.

LuaRocks version 3.0.3

Dennis Schridde
@devurandom

@devurandom you might have more luck sending an email

@Tieske: Thanks, that worked!

iThorgrim
@iThorgrim-Hub

Hello,

Since the last time I still haven't managed to build my application with LuaRocks.

If someone would be available to give me a little tutorial, I'm interested. I explain my problem:

I used LuaRocks to install a module, now I would like to create an executable for my software, but I can't generate it with my LuaRocks module.

I have looked everywhere, I can't find any guide, no tutorial, nothing that can explain step by step how to do it.

Caleb Maclennan
@alerque
Is the current state of your project FOSS and posted somewhere the whole thing could be looked over?
I would probably compare to some other app that is using LuaRocks to create an executable, but finding one that's a rough match for the other bits will make it easier to compare.
BONNAURE Olivier
@solisoft
Hi there, I'm trying to use lapis with openresty and all my rocks are in ~/.luarocks
but when I run lapis I have that :
~/.luarocks/bin/lapis serve
nginx: [alert] lua_code_cache is off; this will hurt performance in /Users/olivierbonnaure/workspace/fasty/nginx.conf.compiled:33
nginx: [error] init_by_lua error: init_by_lua:4: module 'ltn12' not found:
none of my rocks are available for openresty
OSX apple M1
Thijs Schreijer
@Tieske
@iThorgrim-Hub check the lua-mailing list archives. There are utilities that pack everything up into 1 executable file. An alternative, more dynamic, approach would be to ship laurocks with your application, have LuaRocks install everything in a tree within your app structure, and the use a "relative require" (Penlight has some stuff for that) to load the modules
@solisoft you need to update your LUA_PATH settings such that OpenResty looks in the right places. With OpenResty you can use: https://github.com/openresty/lua-nginx-module#lua_package_path to set it