summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
* init: rewrite project config when it's safe to do soHisham Muhammad2019-04-091-14/+18
|
* config: add modes for reading, writing and unsetting individual entriesHisham Muhammad2019-04-0311-198/+534
| | | | | | | | | | | | | | | | | | | | Includes special config keys `lua_dir` and `lua_version`, which are essentially persistent versions of --lua-dir and --lua-version: * `lua_dir` writes a number of LUA_* variables and cfg.lua_interpreter in the current scope's config file. * `lua_version` writes default-lua-version.lua to the given scope. Also deprecates the "flag" versions for various getters: * `--lua-incdir`: use `luarocks config variables.LUA_INCDIR` * `--lua-libdir`: use `luarocks config variables.LUA_LIBDIR` * `--lua-ver`: use `luarocks config lua_version` * `--system-config`: use `luarocks config config_files.system.file` * `--user-config`: use `luarocks config config_files.user.file` * `--rock-trees`: use `luarocks config rocks_trees`
* Add --global, improve relationship between project and --localHisham Muhammad2019-04-034-11/+18
|
* Simplify issue with superuser cache and avoid annoying messageHisham Muhammad2019-04-036-68/+20
| | | | | When running as root, simply switch to use /var/cache/luarocks as a cache.
* manif: use temp dir if local cache can't be createdHisham Muhammad2019-04-031-1/+6
|
* util: more informative message: "Lua 5.x interpreter not found"Hisham Muhammad2019-04-031-1/+4
|
* fs.lua: cache failures as wellHisham Muhammad2019-04-031-16/+34
|
* Cache manifest more aggressivelyHisham Muhammad2019-04-035-28/+65
| | | | | | | * Introduce cache_timeout config option (default 10 seconds) * Do not re-check for the last-modified time of a file to be downloaded for cfg.cache_timeout seconds * Do not re-unzip if zip file was fetched from cache
* update to luacov 0.13.1 + cluacov 0.1.1Hisham Muhammad2019-04-035-14/+17
|
* util: fix refactor mistakeHisham Muhammad2019-04-011-1/+1
|
* Reorder Travis testsHisham Muhammad2019-04-011-35/+35
|
* install, build, make: add --verify and --sign optionsHisham Muhammad2019-04-0110-95/+236
| | | | | | The --verify options of build and make check the signature of rockspec and src.rock files; the --sign option is meant to be used alongside --pack-binary-rock.
* Refactor opts_table from build to reuse in installHisham Muhammad2019-04-012-34/+37
|
* upload: add --sign optionHisham Muhammad2019-04-012-3/+34
|
* Add --sign option to `luarocks pack`Hisham Muhammad2019-04-0111-2/+53
| | | | | | | | * Introduce a new module, `luarocks.signing` * Add `--sign` option to `luarocks pack`, which produces a detached GPG signature * Includes a basic test, along with some fixtures with a password-less GPG key
* tar: do not attempt to create directory more than onceHisham Muhammad2019-04-011-3/+4
|
* fs: versions of exists, is_file, is_dir for Unix and Windows that do not forkHisham Muhammad2019-04-019-53/+97
| | | | | | | | Implements versions of exists, is_file, is_dir for POSIX and Windows using io.open only, based on the semantics of their error codes on these platforms. Drops the dependency on TEST.EXE on Windows.
* init: ensure --reset resets lua wrapper and config fileHisham Muhammad2019-04-011-20/+24
|
* fun: add find and memoize functionsHisham Muhammad2019-04-011-0/+40
|
* cmd: refactor detection code and improve detection of project dirHisham Muhammad2019-04-014-172/+189
|
* Add rockspecHisham Muhammad2019-04-011-0/+36
|
* upload: accept non-200 codesHisham Muhammad2019-03-291-3/+4
| | | | | | | | | This will try to JSON-decode any response, and if it succeds, will return it regardless of status code. If the body cannot be JSON-decoded, then the status code and URL are returned as an error. Fixes #975.
* appveyor: improve cachingHisham Muhammad2019-03-221-18/+45
|
* Remove spurious argumentsHisham Muhammad2019-03-181-2/+2
|
* core.cfg: produce quoted values in tool variables for WindowsHisham Muhammad2019-03-154-21/+21
| | | | | | | | | | | | Alternative solution to the problem described in #968. We can't use #968 because on Unix sometimes people set the value of those variables so they include arguments (even LuaRocks does it by default, setting `UNZIP="unzip -n"`). Now that the variables are quoted, we stop auto-quoting them in `luarocks.fs`. I expect this change to have to practical impact on Unix, where paths with spaces are uncommon (those can use explicit quotes in their values).
* deps: improve performance of external dependency checksHisham Muhammad2019-03-151-16/+33
| | | | | This is especially important now that the Lua library paths are detected using the dependency check machinery.
* cmd: improve detection of project dirHisham Muhammad2019-03-151-28/+31
| | | | | Perform detection of project dir earlier, so we can inspect what Lua version its config uses.
* refactor: move require_json from luarocks.upload.api to luarocks.utilHisham Muhammad2019-03-142-23/+23
|
* util: when bootstrapped, return self path as wrapperHisham Muhammad2019-03-141-1/+10
| | | | | | | | | | | | | | | | | Avoid reporting itself via the true path of the script; use the wrapper instead. That is, instead of ``` Error: Argument missing. See '$HOME/.luarocks/lib/luarocks/rocks-5.3/luarocks/dev-1/bin/luarocks help install'. ``` report ``` Error: Argument missing. See '$HOME/.luarocks/bin/luarocks help install'. ``` See https://github.com/luarocks/luarocks/issues/952#issuecomment-449966779
* init: support running from the root directoryHisham Muhammad2019-03-141-0/+3
| | | | | | | | Containers often run things from the root directory. This makes the <name> argument mandatory when running `luarocks init` from `/`. See https://github.com/luarocks/luarocks/issues/952#issuecomment-456528919
* Do not register system tree if installing to ~/.luarocksHisham Muhammad2019-03-142-2/+2
| | | | See https://github.com/luarocks/luarocks/issues/952#issuecomment-449966779
* core.cfg: make detection of sysconfdir version independentHisham Muhammad2019-03-141-3/+3
| | | | | When LuaRocks is running on Lua 5.3 and a user uses --lua-version=5.1, this allows sysconfdir to continue being detected correctly.
* cmd: be more lenient when --lua-version can't find an interpreterHisham Muhammad2019-03-141-1/+8
| | | | | This will still allow things like `luarocks list` and `luarocks search` to work.
* cmd: if ./.luarocks/config-5.x.lua exists, assume Lua version 5.x by defaultHisham Muhammad2019-03-141-10/+16
|
* Add info about lua-version option in helpJacekJaszczuk2019-03-141-0/+1
|
* fixup! core.sysdetect: Fallback to /proc to detect LinuxLuke Gorrie2019-03-121-5/+5
|
* core.sysdetect: Fallback to /proc to detect LinuxLuke Gorrie2019-03-121-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Check if /proc/sys/kernel/ostype reads as "Linux\n" to detect when a "sysv" platform is really Linux. This test is a fallback with lower priority than the existing heuristics based on ELF headers. This fixes a problem with Alpine Linux docker images where LuaRocks does not detect Linux because /bin/sh ELF headers don't contain have the expected clues: $ docker run -ti alpine / # apk add --no-cache build-base [...] / # readelf -h /bin/sh ELF Header: Magic: 7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00 Class: ELF64 Data: 2's complement, little endian Version: 1 (current) OS/ABI: UNIX - System V ABI Version: 0 Type: DYN (Shared object file) Machine: Advanced Micro Devices X86-64 Version: 0x1 Entry point address: 0xc410 Start of program headers: 64 (bytes into file) Start of section headers: 803616 (bytes into file) Flags: 0x0 Size of this header: 64 (bytes) Size of program headers: 56 (bytes) Number of program headers: 7 Size of section headers: 64 (bytes) Number of section headers: 22 Section header string table index: 21
* Support installations without documentationGeorge Roman2019-02-124-5/+45
|
* fix: make variable changes localSimone Livieri2019-02-121-0/+1
|
* Fix small misspellings (#957)Antonin Décimo2019-02-0914-17/+17
|
* core.cfg: fix sysconfdir detection trimming @ from debug.getinfoTomás Guisasola2019-01-081-0/+3
| | | | Signed-off-by: Hisham Muhammad <hisham@gobolinux.org>
* persist: handle keys that are keywords correctly.Hisham Muhammad2018-12-102-13/+70
| | | | Closes #947.
* fs.win32: fix setting permissions for all users (#943)FYP2018-11-211-1/+1
|
* only report on local cache ownership if we can check itHisham Muhammad2018-11-121-1/+5
| | | | Closes #901.
* makedist: add 'binary' and 'sign' stepsHisham Muhammad2018-10-301-0/+44
|
* Merge branch '3.0.4'Hisham Muhammad2018-10-301-36/+0
|\
| * Release 3.0.4v3.0.4Hisham Muhammad2018-10-305-9/+10
| |
| * Tests: add smoke testHisham Muhammad2018-10-303-4/+75
|/
* Tests: add tests for luarocks.core.sysdetect (#939)Hisham Muhammad2018-10-302-0/+74
|
* Smarter default rockspec, based on current dir basenameHisham Muhammad2018-10-301-0/+8
| | | | | | | | | | | | This allows the following to work: ``` git clone https://github.com/example/foo cd foo luarocks download --rockspec bar luarocks test # will still use the foo rockspec # regardless of the presence of bar rockspec ```