Update for 1.7.0

This commit is contained in:
Hisham Muhammad
2017-09-15 18:32:36 -03:00
parent 138bf12304
commit fbf2894a0a
3 changed files with 18 additions and 8 deletions

View File

@@ -81,6 +81,14 @@ page.</p>
<h2><a name="history"></a>History</h2> <h2><a name="history"></a>History</h2>
<dl class="history"> <dl class="history">
<dt><strong>Version 1.7.0</strong> [unreleased]</dt>
<dd><ul>
<li>symlinkattributes function now provides 'target' field, containing name of the file that the symlink points to.</li>
<li>attributes, symlinkattributes, touch, mkdir, and rmdir functions now return system-dependent error code as the third value on error.</li>
<li>Fixed detection of closed files for Lua 5.2+ in setmode, lock, and unlock functions.</li>
<li>Fixed various compiler warnings.</li>
</ul></dd>
<dt><strong>Version 1.6.3</strong> [15/Jan/2015]</dt> <dt><strong>Version 1.6.3</strong> [15/Jan/2015]</dt>
<dd><ul> <dd><ul>
<li>Lua 5.3 support.</li> <li>Lua 5.3 support.</li>

View File

@@ -84,7 +84,7 @@ Ierusalimschy, Andr&eacute; Carregal and Tom&aacute;s Guisasola.
The implementation is not derived from licensed software.</p> The implementation is not derived from licensed software.</p>
<hr/> <hr/>
<p>Copyright &copy; 2003 Kepler Project.</p> <p>Copyright &copy; 2003 - 2017 Kepler Project.</p>
<p>Permission is hereby granted, free of charge, to any person <p>Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation obtaining a copy of this software and associated documentation

View File

@@ -104,7 +104,7 @@ LuaFileSystem offers the following functions:
<dl class="reference"> <dl class="reference">
<dt><a name="attributes"></a><strong><code>lfs.attributes (filepath [, aname | atable])</code></strong></dt> <dt><a name="attributes"></a><strong><code>lfs.attributes (filepath [, aname | atable])</code></strong></dt>
<dd>Returns a table with the file attributes corresponding to <dd>Returns a table with the file attributes corresponding to
<code>filepath</code> (or <code>nil</code> followed by an error message <code>filepath</code> (or <code>nil</code> followed by an error message and a system-dependent error code
in case of error). in case of error).
If the second optional argument is given and is a string, then only the value of the If the second optional argument is given and is a string, then only the value of the
named attribute is returned (this use is equivalent to named attribute is returned (this use is equivalent to
@@ -222,14 +222,14 @@ LuaFileSystem offers the following functions:
<dt><a name="mkdir"></a><strong><code>lfs.mkdir (dirname)</code></strong></dt> <dt><a name="mkdir"></a><strong><code>lfs.mkdir (dirname)</code></strong></dt>
<dd>Creates a new directory. The argument is the name of the new <dd>Creates a new directory. The argument is the name of the new
directory.<br /> directory.<br />
Returns <code>true</code> if the operation was successful; Returns <code>true</code> in case of success or <code>nil</code>, an error message and
in case of error, it returns <code>nil</code> plus an error string. a system-dependent error code in case of error.
</dd> </dd>
<dt><a name="rmdir"></a><strong><code>lfs.rmdir (dirname)</code></strong></dt> <dt><a name="rmdir"></a><strong><code>lfs.rmdir (dirname)</code></strong></dt>
<dd>Removes an existing directory. The argument is the name of the directory.<br /> <dd>Removes an existing directory. The argument is the name of the directory.<br />
Returns <code>true</code> if the operation was successful; Returns <code>true</code> in case of success or <code>nil</code>, an error message and
in case of error, it returns <code>nil</code> plus an error string.</dd> a system-dependent error code in case of error.
<dt><a name="setmode"></a><strong><code>lfs.setmode (file, mode)</code></strong></dt> <dt><a name="setmode"></a><strong><code>lfs.setmode (file, mode)</code></strong></dt>
<dd>Sets the writing mode for a file. The mode string can be either <code>"binary"</code> or <code>"text"</code>. <dd>Sets the writing mode for a file. The mode string can be either <code>"binary"</code> or <code>"text"</code>.
@@ -242,6 +242,8 @@ LuaFileSystem offers the following functions:
<dt><a name="symlinkattributes"></a><strong><code>lfs.symlinkattributes (filepath [, aname])</code></strong></dt> <dt><a name="symlinkattributes"></a><strong><code>lfs.symlinkattributes (filepath [, aname])</code></strong></dt>
<dd>Identical to <a href="#attributes">lfs.attributes</a> except that <dd>Identical to <a href="#attributes">lfs.attributes</a> except that
it obtains information about the link itself (not the file it refers to). it obtains information about the link itself (not the file it refers to).
It also adds a <strong><code>target</code></strong> field, containing
the file name that the symlink points to.
On Windows this function does not yet support links, and is identical to On Windows this function does not yet support links, and is identical to
<code>lfs.attributes</code>. <code>lfs.attributes</code>.
</dd> </dd>
@@ -255,8 +257,8 @@ LuaFileSystem offers the following functions:
Lua standard function <code>os.time</code>). Lua standard function <code>os.time</code>).
If the modification time is omitted, the access time provided is used; If the modification time is omitted, the access time provided is used;
if both times are omitted, the current time is used.<br /> if both times are omitted, the current time is used.<br />
Returns <code>true</code> if the operation was successful; Returns <code>true</code> in case of success or <code>nil</code>, an error message and
in case of error, it returns <code>nil</code> plus an error string. a system-dependent error code in case of error.
</dd> </dd>
<dt><a name="unlock"></a><strong><code>lfs.unlock (filehandle[, start[, length]])</code></strong></dt> <dt><a name="unlock"></a><strong><code>lfs.unlock (filehandle[, start[, length]])</code></strong></dt>