rename /apps/lua/ to /apps/twnlua/

This commit is contained in:
2024-10-07 15:52:32 +03:00
parent 36fbc5b43f
commit 8463ed4440
77 changed files with 1 additions and 1 deletions

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:0f6cc3aaa68597034efda8bb6bfa214fc2fde99bd1e67d0bb32d7fe75a5dc777
size 12127

View File

@ -0,0 +1,21 @@
ul {
list-style-type: none ;
}
ul.contents {
padding: 0 ;
}
table {
border: none ;
border-spacing: 0 ;
border-collapse: collapse ;
}
td {
vertical-align: top ;
padding: 0 ;
text-align: left ;
line-height: 1.25 ;
width: 15% ;
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.7 KiB

155
apps/twnlua/lua/doc/lua.1 Normal file
View File

@ -0,0 +1,155 @@
.\" $Id: lua.man,v 1.14 2024/05/08 18:48:27 lhf Exp $
.TH LUA 1 "$Date: 2024/05/08 18:48:27 $"
.SH NAME
lua \- Lua interpreter
.SH SYNOPSIS
.B lua
[
.I options
]
[
.I script
[
.I args
]
]
.SH DESCRIPTION
.B lua
is the standalone Lua interpreter.
It loads and executes Lua programs,
either in textual source form or
in precompiled binary form.
(Precompiled binaries are output by
.BR luac ,
the Lua compiler.)
.B lua
can be used as a batch interpreter and also interactively.
.LP
After handling the
.IR options ,
the Lua program in file
.I script
is loaded and executed.
The
.I args
are available to
.I script
as strings in a global table named
.B arg
and also as arguments to its main function.
When called without arguments,
.B lua
behaves as
.B "lua \-v \-i"
if the standard input is a terminal,
and as
.B "lua \-"
otherwise.
.LP
In interactive mode,
.B lua
prompts the user,
reads lines from the standard input,
and executes them as they are read.
If the line contains an expression,
then the line is evaluated and the result is printed.
If a line does not contain a complete statement,
then a secondary prompt is displayed and
lines are read until a complete statement is formed or
a syntax error is found.
.LP
Before handling command line options and scripts,
.B lua
checks the contents of the environment variables
.B LUA_INIT_5_4
and
.BR LUA_INIT ,
in that order.
If the contents are of the form
.RI '@ filename ',
then
.I filename
is executed.
Otherwise, the contents are assumed to be a Lua statement and is executed.
When
.B LUA_INIT_5_4
is defined,
.B LUA_INIT
is ignored.
.SH OPTIONS
.TP
.BI \-e " stat"
execute statement
.IR stat .
.TP
.B \-i
enter interactive mode after executing
.IR script .
.TP
.BI \-l " mod"
require library
.I mod
into global
.IR mod .
.TP
.BI \-l " g=mod"
require library
.I mod
into global
.IR g .
.TP
.B \-v
show version information.
.TP
.B \-E
ignore environment variables.
.TP
.B \-W
turn warnings on.
.TP
.B \-\-
stop handling options.
.TP
.B \-
stop handling options and execute the standard input as a file.
.SH ENVIRONMENT VARIABLES
The following environment variables affect the execution of
.BR lua .
When defined,
the version-specific variants take priority
and the version-neutral variants are ignored.
.TP
.B LUA_INIT, LUA_INIT_5_4
Code to be executed before command line options and scripts.
.TP
.B LUA_PATH, LUA_PATH_5_4
Initial value of package.path,
the path used by require to search for Lua loaders.
.TP
.B LUA_CPATH, LUA_CPATH_5_4
Initial value of package.cpath,
the path used by require to search for C loaders.
.SH EXIT STATUS
If a script calls os.exit,
then
.B lua
exits with the given exit status.
Otherwise,
.B lua
exits
with EXIT_SUCCESS (0 on POSIX systems) if there were no errors
and
with EXIT_FAILURE (1 on POSIX systems) if there were errors.
Errors raised in interactive mode do not cause exits.
.SH DIAGNOSTICS
Error messages should be self explanatory.
.SH "SEE ALSO"
.BR luac (1)
.br
The documentation at lua.org,
especially section 7 of the reference manual.
.SH AUTHORS
R. Ierusalimschy,
L. H. de Figueiredo,
W. Celes
.\" EOF

162
apps/twnlua/lua/doc/lua.css Normal file
View File

@ -0,0 +1,162 @@
html {
background-color: #F8F8F8 ;
}
body {
background-color: #FFFFFF ;
color: #000000 ;
font-family: Helvetica, Arial, sans-serif ;
text-align: justify ;
line-height: 1.25 ;
margin: 16px auto ;
padding: 32px ;
border: solid #ccc 1px ;
border-radius: 20px ;
max-width: 70em ;
width: 90% ;
}
h1, h2, h3, h4 {
color: #000080 ;
font-family: Verdana, Geneva, sans-serif ;
font-weight: normal ;
font-style: normal ;
text-align: left ;
}
h1 {
font-size: 28pt ;
}
h1 img {
vertical-align: text-bottom ;
}
h2:before {
content: "\2756" ;
padding-right: 0.5em ;
}
a {
text-decoration: none ;
}
a:link {
color: #000080 ;
}
a:link:hover, a:visited:hover {
background-color: #D0D0FF ;
color: #000080 ;
border-radius: 4px ;
}
a:link:active, a:visited:active {
color: #FF0000 ;
}
div.menubar {
padding-bottom: 0.5em ;
}
p.menubar {
margin-left: 2.5em ;
}
.menubar a:hover {
margin: -3px -3px -3px -3px ;
padding: 3px 3px 3px 3px ;
border-radius: 4px ;
}
:target {
background-color: #F0F0F0 ;
margin: -8px ;
padding: 8px ;
border-radius: 8px ;
outline: none ;
}
hr {
display: none ;
}
table hr {
background-color: #a0a0a0 ;
color: #a0a0a0 ;
border: 0 ;
height: 1px ;
display: block ;
}
.footer {
color: gray ;
font-size: x-small ;
text-transform: lowercase ;
}
input[type=text] {
border: solid #a0a0a0 2px ;
border-radius: 2em ;
background-image: url('images/search.png') ;
background-repeat: no-repeat ;
background-position: 4px center ;
padding-left: 20px ;
height: 2em ;
}
pre.session {
background-color: #F8F8F8 ;
padding: 1em ;
border-radius: 8px ;
}
table {
border: none ;
border-spacing: 0 ;
border-collapse: collapse ;
}
td {
padding: 0 ;
margin: 0 ;
}
td.gutter {
width: 4% ;
}
table.columns td {
vertical-align: top ;
padding-bottom: 1em ;
text-align: justify ;
line-height: 1.25 ;
}
table.book td {
vertical-align: top ;
}
table.book td.cover {
padding-right: 1em ;
}
table.book img {
border: solid #000080 1px ;
border-radius: 2px ;
}
table.book span {
font-size: small ;
text-align: left ;
display: block ;
margin-top: 0.25em ;
}
p.logos a:link:hover, p.logos a:visited:hover {
background-color: inherit ;
}
img {
background-color: white ;
}

118
apps/twnlua/lua/doc/luac.1 Normal file
View File

@ -0,0 +1,118 @@
.\" $Id: luac.man,v 1.29 2011/11/16 13:53:40 lhf Exp $
.TH LUAC 1 "$Date: 2011/11/16 13:53:40 $"
.SH NAME
luac \- Lua compiler
.SH SYNOPSIS
.B luac
[
.I options
] [
.I filenames
]
.SH DESCRIPTION
.B luac
is the Lua compiler.
It translates programs written in the Lua programming language
into binary files containing precompiled chunks
that can be later loaded and executed.
.LP
The main advantages of precompiling chunks are:
faster loading,
protecting source code from accidental user changes,
and
off-line syntax checking.
Precompiling does not imply faster execution
because in Lua chunks are always compiled into bytecodes before being executed.
.B luac
simply allows those bytecodes to be saved in a file for later execution.
Precompiled chunks are not necessarily smaller than the corresponding source.
The main goal in precompiling is faster loading.
.LP
In the command line,
you can mix
text files containing Lua source and
binary files containing precompiled chunks.
.B luac
produces a single output file containing the combined bytecodes
for all files given.
Executing the combined file is equivalent to executing the given files.
By default,
the output file is named
.BR luac.out ,
but you can change this with the
.B \-o
option.
.LP
Precompiled chunks are
.I not
portable across different architectures.
Moreover,
the internal format of precompiled chunks
is likely to change when a new version of Lua is released.
Make sure you save the source files of all Lua programs that you precompile.
.LP
.SH OPTIONS
.TP
.B \-l
produce a listing of the compiled bytecode for Lua's virtual machine.
Listing bytecodes is useful to learn about Lua's virtual machine.
If no files are given, then
.B luac
loads
.B luac.out
and lists its contents.
Use
.B \-l \-l
for a full listing.
.TP
.BI \-o " file"
output to
.IR file ,
instead of the default
.BR luac.out .
(You can use
.B "'\-'"
for standard output,
but not on platforms that open standard output in text mode.)
The output file may be one of the given files because
all files are loaded before the output file is written.
Be careful not to overwrite precious files.
.TP
.B \-p
load files but do not generate any output file.
Used mainly for syntax checking and for testing precompiled chunks:
corrupted files will probably generate errors when loaded.
If no files are given, then
.B luac
loads
.B luac.out
and tests its contents.
No messages are displayed if the file loads without errors.
.TP
.B \-s
strip debug information before writing the output file.
This saves some space in very large chunks,
but if errors occur when running a stripped chunk,
then the error messages may not contain the full information they usually do.
In particular,
line numbers and names of local variables are lost.
.TP
.B \-v
show version information.
.TP
.B \-\-
stop handling options.
.TP
.B \-
stop handling options and process standard input.
.SH "SEE ALSO"
.BR lua (1)
.br
The documentation at lua.org.
.SH DIAGNOSTICS
Error messages should be self explanatory.
.SH AUTHORS
R. Ierusalimschy,
L. H. de Figueiredo,
W. Celes
.\" EOF

View File

@ -0,0 +1,21 @@
h3 code {
font-family: inherit ;
font-size: inherit ;
}
pre, code {
font-size: 12pt ;
}
span.apii {
color: gray ;
float: right ;
font-family: inherit ;
font-style: normal ;
font-size: small ;
}
h2:before {
content: "" ;
padding-right: 0em ;
}