1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
|
What's new in LuaRocks 3.0
==========================
* *Breaking change:* The support for deprecated unversioned paths
(e.g. `/usr/local/lib/luarocks/rocks/` and `/etc/luarocks/config.lua`)
was removed, LuaRocks will now only create and use paths versioned
to the specific Lua version in use
(e.g. `/usr/local/lib/luarocks/rocks-5.3/` and `/etc/luarocks/config-5.3.lua`).
* *New rockspec format:* if you add `rockspec_format = "3.0"` to your
rockspec, you can use all features listed in the section "[Rockspec 3.0]" below.
Note that these rockspecs will only work with LuaRocks 3.0 and above, but
older versions will detect that directive and fail gracefully, giving the
user a message telling them to upgrade.
* *New feature:* [namespaces](https://github.com/luarocks/luarocks/wiki/Namespaces):
you can use `luarocks install user/package` to install a package from a
specific user of the repository.
* *New command:* `luarocks test`. It runs a rock's test suite, as specified
in the new `test` section of the rockspec file. It also does some
autodetection, so it already works with many existing rocks as well.
* *New command:* `luarocks which`. Given the name of an installed, it tells
you which rock it is a part of. For example, `luarocks which lfs`
will tell you it is a part of `luafilesystem` (and give the full
path name to the module). In this sense, `luarocks which` is the
dual command to `luarocks show`.
* *New flag* `--temp-key` for `luarocks upload`, allowing you to easily
upload rocks into an alternate account without disrupting the
stored configuration of your main account.
* *New flag* `--dev`, for enabling development-branch sub-repositories.
This adds support for easily requesting `dev` modules from LuaRocks.org, as in:
`luarocks install --dev luafilesystem`. The list of URLs configured
in `rocks_servers` is prepended with a list containing "/dev" in their paths.
* `luarocks path` now exports versioned variables `LUA_PATH_5_x` and
`LUA_CPATH_5_x` instead of `LUA_PATH` and `LUA_CPATH`
when those are in use in your system.
* Package paths are sanitized to only reference the current Lua version.
For example, if you have `/some/dir/lua/5.1/` in your `$LUA_PATH` and
you are running Lua 5.2, `luarocks.loader` and the `luarocks` command-line
tool will convert it to `/some/dir/lua/5.2/`.
* Wrappers installed using `--tree` now prepend the tree's prefix to their
package paths.
* `luarocks-admin` commands no longer creates an `index.html` file in the
repository by default (it does update it if it alroady exists)
* `luarocks-admin add` now works with `file://` repositories
Rockspec 3.0
------------
These features are only enabled if `rockspec_format = "3.0"` is set in the rockspec:
* Build type `builtin` is the default if `build.type` is not specified.
* New table `build_dependencies`: dependencies used only for running `luarocks build`
but not when installing binary rocks.
* New table `test_dependencies`: dependencies used only for running `luarocks test`
* New table `test`: settings for configuring the behavior of `luarocks test`.
Supports a `test.type` field so that the test backend can be specified.
Currently supported test backends are:
* `"busted"`, for running [Busted](https://olivinelabs.com/busted)
* `"command"`, for running a plain command.
* Custom backends can be loaded via `test_dependencies`
* New field `build.macosx_deployment_target = "10.9"` is supported in Mac platforms,
and adjusts `$(CC)` and `$(LD)` variables to export the corresponding
environment variable.
* LuaJIT can be detected in dependencies and uses version reported by the
running interpreter: e.g. `"luajit >= 2.1"`.
* Auto-detection of `source.dir` is improved: when the tarball contains
only one directory at the root, assume that is where the sources are.
* New `description` fields:
* `labels`, an array of strings;
* `issues_url`, URL to the project's bug tracker.
* `cmake` build type now supports `build.build_pass` and `build_install_pass`
to disable `make` passes.
* `git` fetch type fetches submodules by default.
* Patches added in `patches` can create and delete files, following standard
patch rules.
Internal changes
----------------
* Modules needed by `luarocks.loader` were moved into the `luarocks.core` namespace.
Modules in `luarocks.core` only depend on other `luarocks.core` modules.
(Notably, `luarocks.core` does not use `luarocks.fs`.)
* Modules representing `luarocks` commands were moved into the `luarocks.cmd` namespace.
* Modules representing `luarocks-admin` commands were moved into the `luarocks.admin.cmd` namespace.
* New internal objects for representing interaction with the repostories:
`luarocks.queries` and `luarocks.results`
* Type checking rules of file formats were moved into the `luarocks.type` namespace.
|