summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander M Pickering <alex@cogarr.net>2024-12-21 23:17:52 -0600
committerAlexander M Pickering <alex@cogarr.net>2024-12-21 23:17:52 -0600
commit6411bc31d00efda1fb22a2b3ec23eaed5b7f22e4 (patch)
treeb79eaca4ceec88f569ad0827323d0ca19354a698
parentd6233646bdfc0119ce528c206dbacc69ef28942e (diff)
downloadwebsite-6411bc31d00efda1fb22a2b3ec23eaed5b7f22e4.tar.gz
website-6411bc31d00efda1fb22a2b3ec23eaed5b7f22e4.tar.bz2
website-6411bc31d00efda1fb22a2b3ec23eaed5b7f22e4.zip
Make site look better on mobile
-rw-r--r--html/index.html59
1 files changed, 29 insertions, 30 deletions
diff --git a/html/index.html b/html/index.html
index 48c86bf..494ce50 100644
--- a/html/index.html
+++ b/html/index.html
@@ -1,15 +1,22 @@
1<html lang=en> 1<!DOCTYPE html>
2<html lang="en">
2 <head> 3 <head>
4 <meta charset="utf-8">
5 <meta name="robots" content="index,follow">
6 <meta name="author" content="Alexander Pickering">
7 <meta name="description" content="Lua4Win - A distribution of the Lua programming language">
8 <title>Lua4Win</title>
9 <meta name="viewport" content="width=device-width, initial-scale=1.0, minimal-ui">
3 <link rel="stylesheet" href="/milligram.min.css"/> 10 <link rel="stylesheet" href="/milligram.min.css"/>
4 <link rel="stylesheet" href="/tokyo-night-light.css"/> 11 <link rel="stylesheet" href="/tokyo-night-light.css"/>
5 <script src="/highlight.min.js"></script> 12 <script src="/highlight.min.js"></script>
6 <script>hljs.highlightAll();</script> 13 <script>hljs.highlightAll();</script>
7 </head> 14 </head>
8 <body><main class="wrapper"> 15 <body><main class="wrapper">
9 <header class="header"><section class="container"> 16 <nav class="navigation">
17 <section class="container">
10 <h1 class="title">Lua4Win</h1> 18 <h1 class="title">Lua4Win</h1>
11 <p>Lua4Win is a distribution the Lua programming language for Windows.</p> 19 <p>Lua4Win is a distribution the Lua programming language for Windows.</p>
12 <nav class="navigation">
13 <ul> 20 <ul>
14 <li><a href="#install">Install</a></li> 21 <li><a href="#install">Install</a></li>
15 <li><a href="#rational">Rational</a></li> 22 <li><a href="#rational">Rational</a></li>
@@ -18,8 +25,8 @@
18 <li><a href="#languages">Sister Languages</a></li> 25 <li><a href="#languages">Sister Languages</a></li>
19 <li><a href="#advanced">Advanced Usage</a></li> 26 <li><a href="#advanced">Advanced Usage</a></li>
20 </ul> 27 </ul>
28 </section>
21 </nav> 29 </nav>
22 </section></header>
23 <section class="container" id="install"> 30 <section class="container" id="install">
24 <h3 class="title">Install</h3> 31 <h3 class="title">Install</h3>
25 <p>You can install it by using the .msi file here.</p> 32 <p>You can install it by using the .msi file here.</p>
@@ -39,51 +46,48 @@ JIT: ON CMOV SSE2 SSE3 SSE4.1 AMD fold cse dce fwd dse narrow loop abc sink fuse
39Hello, world! 46Hello, world!
40></code></pre> 47></code></pre>
41 <p>You can use <code>CTRL+C</code> to escape the read-evaluate-print-loop. You can also write Lua programs with your favorite text editor and run them with <code>$ lua filename.lua</code> 48 <p>You can use <code>CTRL+C</code> to escape the read-evaluate-print-loop. You can also write Lua programs with your favorite text editor and run them with <code>$ lua filename.lua</code>
49 <div class="container">
42 <div class="row"> 50 <div class="row">
43 <div class="column"> 51 <div class="column">
44 note.lua 52 note.lua
45 </div>
46 </div>
47 <div class="row">
48 <div class="column">
49 <pre><code class="language-lua">-- Create a note file with today's date in %APPDATA% 53 <pre><code class="language-lua">-- Create a note file with today's date in %APPDATA%
50local args = {...} -- extra arguments passed to the program 54local args = {...} -- extra arguments passed to the program
51-- Generate a filename 55-- Generate a filename
52local notes_folder = os.getenv("APPDATA") 56local note_f = os.getenv("APPDATA")
53local today = os.date("%Y-%m-%d") 57local today = os.date("%Y-%m-%d")
54local note_name = table.concat(args,"-"):gsub("[%W]","-") 58local note_name = table.concat(args,"-"):gsub("[%W]","-")
55local note_filename = string.format("%s\note-%s-%s.txt",notes_folder,today,note_name) 59local filename = ("%s\note-%s-%s.txt"):format(note_f,today,note_name)
56-- Create the file 60-- Create the file
57local fd = assert(io.open(note_filename,"w")) 61local fd = assert(io.open(filename,"w"))
58assert(fd:close()) 62assert(fd:close())
59-- Open it in notepad 63-- Open it in notepad
60os.execute("notepad.exe " .. note_filename)</code></pre> 64os.execute("notepad.exe " .. filename)</code></pre>
61 </div> 65 </div>
62 <div class="column"> 66 <div class="column">
67 &nbsp;
63 <pre><code class="language-bash">$ lua note.lua my first note</code></pre> 68 <pre><code class="language-bash">$ lua note.lua my first note</code></pre>
64 </div> 69 </div>
65 </div> 70 </div>
71 </div>
66 <p>Run <code>lua --help</code> for more options for the command line tool, and see the <a href="https://www.lua.org/manual/5.1/manual.html">Lua Manual</a> for extensive documentation of the Lua programming language and standard libraries. Also note <a href="https://luajit.org/extensions.html">LuaJIT's extensions</a></p> 72 <p>Run <code>lua --help</code> for more options for the command line tool, and see the <a href="https://www.lua.org/manual/5.1/manual.html">Lua Manual</a> for extensive documentation of the Lua programming language and standard libraries. Also note <a href="https://luajit.org/extensions.html">LuaJIT's extensions</a></p>
67 </section> 73 </section>
68 <section class="container" id="luarocks"> 74 <section class="container" id="luarocks">
69 <h3 class="title">Installing Superpowers</h3> 75 <h3 class="title">Installing Superpowers</h3>
70 <p>You can use modules that implement more than the standard lua libraries by running the <code>$ luarocks install &gt;module name&lt; </code> command to download and install modules.</p> 76 <p>You can use modules that implement more than the standard lua libraries by running the <code>$ luarocks install &gt;module name&lt; </code> command to download and install modules.</p>
71 <div class="row"> 77 <div class="row">
72 <div class="column column-offset-33">
73 color.lua
74 </div>
75 </div>
76 <div class="row">
77 <div class="column"> 78 <div class="column">
79 &nbsp;
78 <pre><code class="language-bash">$ luarocks install easni</code></pre> 80 <pre><code class="language-bash">$ luarocks install easni</code></pre>
79 </div> 81 </div>
80 <div class="column"> 82 <div class="column">
83 color.lua
81 <pre><code class="language-lua">local ansi = require("eansi") 84 <pre><code class="language-lua">local ansi = require("eansi")
82ansi.enable = true 85ansi.enable = true
83local green = ansi.toansi("green") 86local green = ansi.toansi("green")
84print(green .. "> implying you need modules")</code></pre> 87print(green .. "> implying you need modules")</code></pre>
85 </div> 88 </div>
86 <div class="column"> 89 <div class="column">
90 &nbsp;
87 <pre><code class="language-bash">$ lua color.lua</code></pre> 91 <pre><code class="language-bash">$ lua color.lua</code></pre>
88 </div> 92 </div>
89 </div> 93 </div>
@@ -94,15 +98,12 @@ print(green .. "> implying you need modules")</code></pre>
94 <p>Lua4Win makes it easy to download other programming languages that are distributed through the <code>luarocks</code> package manager. Simply <code>luarocks install</code> them like you would any other package.</p> 98 <p>Lua4Win makes it easy to download other programming languages that are distributed through the <code>luarocks</code> package manager. Simply <code>luarocks install</code> them like you would any other package.</p>
95 <h4 class="title">Moonscript</h4> 99 <h4 class="title">Moonscript</h4>
96 <div class="row"> 100 <div class="row">
97 <div class="column column-offset-33">
98 example.moon
99 </div>
100 </div>
101 <div class="row">
102 <div class="column"> 101 <div class="column">
102 &nbsp;
103<pre><code class="language-bash">$ luarocks install moonscript</code></pre> 103<pre><code class="language-bash">$ luarocks install moonscript</code></pre>
104 </div> 104 </div>
105 <div class="column"> 105 <div class="column">
106 example.moon
106<pre><code class="language-moonscript">class Person 107<pre><code class="language-moonscript">class Person
107 name: "Alex" 108 name: "Alex"
108 greet: => print("Hello, " .. @name) 109 greet: => print("Hello, " .. @name)
@@ -115,6 +116,7 @@ with World!
115</code></pre> 116</code></pre>
116 </div> 117 </div>
117 <div class="column"> 118 <div class="column">
119 &nbsp;
118<pre><code class="language-bash">$ moon example.moon 120<pre><code class="language-bash">$ moon example.moon
119Hello, World!</code></pre> 121Hello, World!</code></pre>
120 </div> 122 </div>
@@ -122,15 +124,12 @@ Hello, World!</code></pre>
122 <br/> 124 <br/>
123 <h4 class="title">Teal</h4> 125 <h4 class="title">Teal</h4>
124 <div class="row"> 126 <div class="row">
125 <div class="column column-offset-33">
126 keys.tl
127 </div>
128 </div>
129 <div class="row">
130 <div class="column"> 127 <div class="column">
128 &nbsp;
131 <pre><code class="language-bash">$ luarocks install tl</code></pre> 129 <pre><code class="language-bash">$ luarocks install tl</code></pre>
132 </div> 130 </div>
133 <div class="column"> 131 <div class="column">
132 keys.tl
134 <pre><code class="language-teal">local function keys&lt;K,V&gt;(xs: {K:V}):{K} 133 <pre><code class="language-teal">local function keys&lt;K,V&gt;(xs: {K:V}):{K}
135 local ks = {} 134 local ks = {}
136 for k, _ in pairs(xs) do 135 for k, _ in pairs(xs) do
@@ -144,6 +143,7 @@ print(table.concat(s))
144</code></pre> 143</code></pre>
145 </div> 144 </div>
146 <div class="column"> 145 <div class="column">
146 &nbsp;
147 <pre><code class="language-bash">$ tl run keys.tl 147 <pre><code class="language-bash">$ tl run keys.tl
148ab</code></pre> 148ab</code></pre>
149 </div> 149 </div>
@@ -155,7 +155,6 @@ ab</code></pre>
155 <p>Lua4Win's luarocks configuration lives at <code class="language-none">[INSTALLDIR]/config/config-5.1.lua</code>, and is a regular Lua file you can modify.</p> 155 <p>Lua4Win's luarocks configuration lives at <code class="language-none">[INSTALLDIR]/config/config-5.1.lua</code>, and is a regular Lua file you can modify.</p>
156 <p>All of Lua4Win's binary packages are built using mingw64. If you intend to build your own modules they must be built with mingw64 if you want them to interoperate with Lua4Win-distributed Lua.</p> 156 <p>All of Lua4Win's binary packages are built using mingw64. If you intend to build your own modules they must be built with mingw64 if you want them to interoperate with Lua4Win-distributed Lua.</p>
157 <p>Some of Lua4Win's packages needed patching or modification, source code is generally mirrored at <a href="https://git.lua4.win">git.lua4.win</a>, and packaging code is kept separate- usually in a <code>*-packaging</code> repo.</p> 157 <p>Some of Lua4Win's packages needed patching or modification, source code is generally mirrored at <a href="https://git.lua4.win">git.lua4.win</a>, and packaging code is kept separate- usually in a <code>*-packaging</code> repo.</p>
158 158 </section>
159 </body> 159 </main></body>
160</html> 160</html>
161