diff options
| author | hisham <hisham@9ca3f7c1-7366-0410-b1a3-b5c78f85698c> | 2009-10-08 18:56:27 +0000 |
|---|---|---|
| committer | hisham <hisham@9ca3f7c1-7366-0410-b1a3-b5c78f85698c> | 2009-10-08 18:56:27 +0000 |
| commit | 18e8087302dc031cd551f16f7e1b0e36bd1fd77a (patch) | |
| tree | a86d8d349716320f0b6632821bb2df2626fc0b43 /src | |
| parent | 60a0f5c818a5319c47c07756f257ebbba16eaad1 (diff) | |
| download | luarocks-18e8087302dc031cd551f16f7e1b0e36bd1fd77a.tar.gz luarocks-18e8087302dc031cd551f16f7e1b0e36bd1fd77a.tar.bz2 luarocks-18e8087302dc031cd551f16f7e1b0e36bd1fd77a.zip | |
rock_manifest_file
git-svn-id: http://luarocks.org/svn/luarocks/trunk@73 9ca3f7c1-7366-0410-b1a3-b5c78f85698c
Diffstat (limited to 'src')
| -rw-r--r-- | src/luarocks/path.lua | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/luarocks/path.lua b/src/luarocks/path.lua index b63eaa43..f2d02ded 100644 --- a/src/luarocks/path.lua +++ b/src/luarocks/path.lua | |||
| @@ -81,6 +81,20 @@ function rockspec_file(name, version, rocks_dir) | |||
| 81 | return dir.path(rocks_dir or cfg.rocks_dir, name, version, name.."-"..version..".rockspec") | 81 | return dir.path(rocks_dir or cfg.rocks_dir, name, version, name.."-"..version..".rockspec") |
| 82 | end | 82 | end |
| 83 | 83 | ||
| 84 | --- Get the local filename of the rock_manifest file of an installed rock. | ||
| 85 | -- @param name string: The package name. | ||
| 86 | -- @param version string: The package version. | ||
| 87 | -- @param rocks_dir string or nil: If given, specifies the local repository to use. | ||
| 88 | -- @return string: The resulting path -- does not guarantee that | ||
| 89 | -- the package (and by extension, the file) exists. | ||
| 90 | function rock_manifest_file(name, version, rocks_dir) | ||
| 91 | assert(type(name) == "string") | ||
| 92 | assert(type(version) == "string") | ||
| 93 | assert(not rocks_dir or type(rocks_dir) == "string") | ||
| 94 | |||
| 95 | return dir.path(rocks_dir or cfg.rocks_dir, name, version, "rock_manifest") | ||
| 96 | end | ||
| 97 | |||
| 84 | --- Get the local installation directory for C libraries of a package. | 98 | --- Get the local installation directory for C libraries of a package. |
| 85 | -- @param name string: The package name. | 99 | -- @param name string: The package name. |
| 86 | -- @param version string: The package version. | 100 | -- @param version string: The package version. |
