diff options
| author | Hisham Muhammad <hisham@gobolinux.org> | 2015-03-23 23:56:47 -0300 |
|---|---|---|
| committer | Hisham Muhammad <hisham@gobolinux.org> | 2015-03-23 23:56:47 -0300 |
| commit | 876d9c892274aa2a0caa47c5db465517388249a7 (patch) | |
| tree | b580ce620b8a38d2afaa743839f2e75adee84d5d | |
| parent | 294e08fa074d47063e3a83bc9f62587d39ce1d44 (diff) | |
| download | luarocks-876d9c892274aa2a0caa47c5db465517388249a7.tar.gz luarocks-876d9c892274aa2a0caa47c5db465517388249a7.tar.bz2 luarocks-876d9c892274aa2a0caa47c5db465517388249a7.zip | |
Fix inconsistency in --homepage flag in `luarocks doc` and `luarocks write_rockspec`.
`luarocks doc` now uses --home.
| -rw-r--r-- | src/luarocks/doc.lua | 4 | ||||
| -rw-r--r-- | src/luarocks/util.lua | 2 | ||||
| -rwxr-xr-x | test/testing.sh | 1 |
3 files changed, 4 insertions, 3 deletions
diff --git a/src/luarocks/doc.lua b/src/luarocks/doc.lua index 6dee1069..034e2a16 100644 --- a/src/luarocks/doc.lua +++ b/src/luarocks/doc.lua | |||
| @@ -21,7 +21,7 @@ Without any flags, tries to load the documentation | |||
| 21 | using a series of heuristics. | 21 | using a series of heuristics. |
| 22 | With these flags, return only the desired information: | 22 | With these flags, return only the desired information: |
| 23 | 23 | ||
| 24 | --homepage Open the home page of project. | 24 | --home Open the home page of project. |
| 25 | --list List documentation files only. | 25 | --list List documentation files only. |
| 26 | 26 | ||
| 27 | For more information about a rock, see the 'show' command. | 27 | For more information about a rock, see the 'show' command. |
| @@ -75,7 +75,7 @@ function doc.run(...) | |||
| 75 | if not rockspec then return nil,err end | 75 | if not rockspec then return nil,err end |
| 76 | local descript = rockspec.description or {} | 76 | local descript = rockspec.description or {} |
| 77 | 77 | ||
| 78 | if flags["homepage"] then | 78 | if flags["home"] then |
| 79 | return show_homepage(descript.homepage, name, version) | 79 | return show_homepage(descript.homepage, name, version) |
| 80 | end | 80 | end |
| 81 | 81 | ||
diff --git a/src/luarocks/util.lua b/src/luarocks/util.lua index 24b5faad..2d57f9dc 100644 --- a/src/luarocks/util.lua +++ b/src/luarocks/util.lua | |||
| @@ -80,7 +80,7 @@ local supported_flags = { | |||
| 80 | ["from"] = "<server>", | 80 | ["from"] = "<server>", |
| 81 | ["help"] = true, | 81 | ["help"] = true, |
| 82 | ["home"] = true, | 82 | ["home"] = true, |
| 83 | ["homepage"] = true, | 83 | ["homepage"] = "<url>", |
| 84 | ["keep"] = true, | 84 | ["keep"] = true, |
| 85 | ["lib"] = "<library>", | 85 | ["lib"] = "<library>", |
| 86 | ["license"] = "\"<text>\"", | 86 | ["license"] = "\"<text>\"", |
diff --git a/test/testing.sh b/test/testing.sh index fafa3831..dc72afaa 100755 --- a/test/testing.sh +++ b/test/testing.sh | |||
| @@ -417,6 +417,7 @@ test_search_missing() { $luarocks search missing_rock; } | |||
| 417 | 417 | ||
| 418 | test_show() { $luarocks show luacov; } | 418 | test_show() { $luarocks show luacov; } |
| 419 | test_show_modules() { $luarocks show --modules luacov; } | 419 | test_show_modules() { $luarocks show --modules luacov; } |
| 420 | test_show_home() { $luarocks show --home luacov; } | ||
| 420 | test_show_depends() { need_luasocket; $luarocks install $luasec && $luarocks show luasec; } | 421 | test_show_depends() { need_luasocket; $luarocks install $luasec && $luarocks show luasec; } |
| 421 | test_show_oldversion() { $luarocks install luacov ${version_luacov} && $luarocks show luacov ${version_luacov}; } | 422 | test_show_oldversion() { $luarocks install luacov ${version_luacov} && $luarocks show luacov ${version_luacov}; } |
| 422 | 423 | ||
