Login
or
register
LuaRocks
Versioned Components For Lua
Overview
Home Page
Mailing list
Browse rocks
Links
Download
Download
Installing on Unix
Installing on Windows
Release history
License
Documentation
Documentation
File formats
Development
Feedback
unpack
Anonymous users must enter
captcha
below.
Don't put anything here
Don't put anything here
Page Parameters
Page Name (for URL)
Don't put anything here
Don't put anything here
Page Title
Show Advanced Options
Category
Prototype
Page Content
'''unpack''' - Unpack the contents of a rock. == Usage == :'''[[luarocks]] unpack {''rock'' | ''rockspec'' | ''name'' <nowiki>[</nowiki>''version''<nowiki>]</nowiki>}''' Unpacks the contents of a rock in a newly created directory under the current directory. Argument may be a rock file, a rockspec file, or the name of a rock/rockspec in a remote repository. When a rock is given, LuaRocks creates a directory and extracts the contents of a rock inside it. If it is a .src.rock file, it also extracts the sources, and copies the rock's rockspec to the root of the sources directory, so that you can run <tt>luarocks [[make]]</tt>. When a rockspec is given, LuaRocks creates a directory and then fetches and extracts the sources for the module inside it. It also copies the rockspec to the root of the sources directory. When a binary rock is given, it just extracts the contents of the rock in the created directory for further inspection. To fetch the sources, you can run <tt>unpack</tt> again on the rockspec file that will be extracted from the binary rock. When a name (and optionally a version) is given, LuaRocks tries to download a source rock or a rockspec from remote repositories, and then proceeds as if the obtained file was provided locally. == Examples == luarocks unpack luafilesystem 1.4.0 This fetches luafilesystem-1.4.0-1.src.rock from the remote repository and creates in the current directory a directory called "luafilesystem-1.4.0-1" with the contents of the rock, including the LuaFileSystem sources unpacked. You will then be able to go into the luafilesystem-1.4.0-1/luafilesystem-1.4.0 directory and run <tt>luarocks [[make]]</tt>. luarocks unpack copas-1.1.1-1.rockspec Assuming you have copas-1.1.1-1.rockspec in the current directory, this creates in the current directory a directory called "copas-1.1.1-1" with the rockspec and the Copas sources unpacked. You will then be able to go into the copas-1.1.1-1/copas-1.1.1 directory and run <tt>luarocks [[make]]</tt>. While the extracted directory names may look repetitive, note that the first directory is a directory in a LuaRocks "name-version-revision" format, and the second directory is the directory contained inside the sources archives, which may be in any format, and in some cases may not even exist.
Don't put anything here
About this Edit
Minor Edit
Edit Summary
Don't put anything here
Powered by
Sputnik
|
XHTML 1.1