| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
|
|
|
|
|
|
|
| |
Adds the `build_dependencies` key to the rockspec format,
for dependencies that are only triggered when building from
source (e.g. via `luarocks build` or running `luarocks install`
on a rockspec) and not when building from a packaged `.rock`
file using `luarocks install`.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add asserts to uses of `name` arguments to check that they
are not namespaced; rename namespace-able name arguments
to `ns_name` and avoid some unrelated uses of the `name`
argument that don't represent rock names (there are still
others around, to be fixed eventually).
This may cause some failures in some untested code paths
with namespaced packages, but we hope to catch them
with better testing. Better to be safe here than to
perform filesystem operations on incorrect paths.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For details of the new feature, see
https://github.com/luarocks/luarocks/wiki/Namespaces
This ended up being a huge commit because of some major refactoring
motivated by the new feature:
* new modules for some object types:
* `luarocks.queries` - all functions that look for rocks in local or
remote repositories now use objects constructed by this module:
query objects contain the name, namespace and query constraints.
Dependencies in a rockspec are also stored as query objects.
* `luarocks.results` - all individual results produces from queries
are returned in this format: result objects contain the name,
namespace, version, arch and repo.
* the `results` object was renamed to `result_tree`, to better
reflect that it is not an array of `result` objects.
* `luarocks.vers` was removed, its functionality was moved to better locations.
Specifically on namespaces:
* Commands that take a rock `name` can now take `namespace/name`
(and alternately `--flags=namespace` so that URLs can be
also installed with a nominal namespace).
* Rocks installed from a namespace now create a `rock_namespace`
file alongside `rock_manifest`, which is used when matching
namespaced dependencies against locally-installed rocks.
* Using namespaced dependencies in a rockspec, requires
`rockspec_format = "3.0"`.
* Tests under the `#namespaces` hashtag, all using a local repository.
|
| |
|
| |
|
|
|
|
|
|
|
| |
luarocks.deps module used to contain version and dependency parsing
functions as well as some high-level dependency handling:
matching and resolving them. A lot of modules only need the parsing
half. Split it into its own module, luarocks.vers.
|
|
|
|
|
|
|
|
|
|
| |
This is now a parameter, because depending on the rockspec version the set of
default rocks_provided for a rockspec may change. This is to maintain
compatibility with rocks provided by LuaRocks versions in rockspec format 1.0.
When checking dependencies for a rockspec, we ensure we respect that to keep
backward compatibility. When we check dependencies for the manifest as a
whole, we can use the larger set of rocks_provided known by the current
LuaRocks version.
|
|\ |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Isolate all modules used by luarocks.loader in a
luarocks.core.* namespace. Core modules can only require
other core modules, and they only use require() at the
top-level chunk. In other words, after luarocks.loader
is setup, package.path can be altered at will and it
should not affect the ability of luarocks.loader to run,
and the luarocks.loader modules should not interfere
with modules loaded later.
This was motivated by @robooo's GSoC work on porting
the LuaRocks test suite to Lua using Busted. Busted itself
runs using luarocks.loader, and we need to ensure that
the modules loaded by the tests do not conflict with
the ones used by luarocks.loader.
A circular dependency between luarocks.manif and
luarocks.search was removed by creating a separate
luarocks.manif.writer module.
Also, luarocks-admin commands were moved to a
luarocks.admin.* namespace.
|
| | |
|
| |\ |
|
| |\ \ |
|
| |\ \ \ |
|
| |\ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Conflicts:
src/luarocks/deps.lua
|
| | | | | | |
|
| |\ \ \ \ \ |
|
| | | | | | | |
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
For utility, add deps.format_is_at_least(rockspec, version) function.
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Do not report missing dependencies on manifest update, which is now
done more often. Instead do it at the end of commands
that may alter manifest (install, build, make, remove - excluding
purge).
For reporting reuse format used when showing missing deps to be
installed. Do not report missing indirect dependencies,
only direct ones.
|
| |_|_|_|_|/
|/| | | | | |
|
| |_|_|_|/
|/| | | | |
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
* Instead of applying blacklist and sorting versions
in separate steps do a single pass over the list.
* On success return just the version instead of
{name = name, version = version} since rock name is stored
inside dependency table already.
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Instead of lising all missing deps before installing all of them,
announce each missing dep right before installing it.
Also show current rock versions for missing deps.
|
| |_|_|/
|/| | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Instead of mentioning URL twice in
Installing URL...
Using URL... switching to 'build' mode
simply print
Installing URL
and don't print URL at all when it's the argument to `luarocks install`
(it's a bit redundant), only when it's a result of a search.
|
| |_|/
|/| | |
|
| | |
| | |
| | |
| | |
| | |
| | | |
In practice search.find_suitable_rock is always
called with a precise query (no fuzzy name matching),
and not all callers handle table as return value correctly.
|
| | | |
|
| |/
|/| |
|
| |
| |
| |
| |
| | |
Ensure consistent output for Lua 5.3 where key order of pairs() can
change between two runs.
|
|/ |
|
| |
|
|
|
|
|
|
| |
module table
Thanks to Metalua for the possibility to automate this.
|
| |
|
|
|
|
| |
The first returns an iterator, the second one a table.
|
| |
|
| |
|
|\
| |
| | |
Add a configuration option to specify manually installed rocks (#177)
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The patch adds a new configuration option - cfg.rocks_provided.
This option contains a list of packages that are either builtin or
manually installed outside of LuaRocks package management system:
rocks_provided = {
[module_name] = module_version.."-"..rockspec_version,
-- ...
}
These settings are taken into account during dependency resolution
and when search and install commands are used. An attempt to install
a rock from the list causes an error.
LuaRocks automatically adds following modules to the list:
rocks_provided = {
lua = lua_version.."-1",
-- For Lua 5.2 or later:
bit32 = lua_version.."-1",
-- For LuaJIT:
luajit = lj_version.."-1",
jit = lj_version.."-1",
ffi = lj_version.."-1",
bit = lj_version.."-1",
luabitop = lj_version.."-1"
}
where lua_version extracted from _VERSION (e.g. 5.2),
lj_version extracted from jit.version (e.g. 2.0.2).
Built-in values can be overridden by configuration options.
Closes #177.
|
|/ |
|
| |
|
| |
|
| |
|
| |
|
|\ |
|
| | |
|
| | |
|