File tree Expand file tree Collapse file tree 9 files changed +14
-91
lines changed
Expand file tree Collapse file tree 9 files changed +14
-91
lines changed Original file line number Diff line number Diff line change 7878 additional_dependencies :
7979 - markdown-it-texmath
8080 - repo : https://github.com/scop/pre-commit-shfmt
81- rev : v3.11 .0-1
81+ rev : v3.12 .0-2
8282 hooks :
8383 - id : shfmt
8484 exclude : bin/neomuttp
Original file line number Diff line number Diff line change @@ -89,31 +89,11 @@ if vim.g.script_name == "nvimp" then
8989end
9090```
9191
92- #### luajittex
93-
94- Refer [ luatex] ( #luatex ) .
95-
9692### Lua 5.3
9793
98- #### luatex
99-
100- ![ texluap] ( https://github.com/wakatime/prompt-style.lua/assets/32936898/96d9f4c1-55fc-4ae3-87b8-7afd29f4ba0e )
101-
102- If you want to use lua REPL in ` \directlua{} ` , you can insert:
103-
104- ``` tex
105- \directlua{require'prompt.tex'}
106- ```
107-
108- As [ example] ( examples/ ) :
109-
110- ``` sh
111- luajittex --shell-escape main.tex
112- ```
113-
114- Then you will get:
94+ #### [ luatex] ( https://www.luatex.org/ )
11595
116- ![ directlua ] ( https://github.com/user-attachments/assets/6a9943c9-a273-4ca9-b603-8cee17a2218f )
96+ See [ tlua ] ( https://luarocks.org/modules/freed-wu/tlua ) .
11797
11898#### [ neomutt] ( https://neomutt.org )
11999
Load Diff This file was deleted.
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11--- prompt style.
22local os = require " os"
33local table = require " table"
4- local lfs = require " lfs"
4+ -- texlua has a builtin lfs, use it
5+ if lfs then
6+ lfs_ = lfs
7+ else
8+ _ , lfs_ = pcall (require , " lfs" )
9+ end
10+ local lfs = lfs_
511local ansicolors = require " ansicolors"
612local prompt = require " prompt"
713--- @diagnostic disable : deprecated
@@ -122,7 +128,7 @@ local function get_os()
122128 if os.getenv (" PREFIX" ) == " /data/data/com.termux/files/usr" then
123129 return " android"
124130 end
125- local binary_format = package.cpath :match (' ([^.]+)$' )
131+ local binary_format = package.cpath :match (' ([^.]+)$' ): gsub ( " ;$ " , " " )
126132 if binary_format == " so" then
127133 return get_distribution ()
128134 elseif binary_format == " dll" then
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1616 ]
1717 ) ;
1818in
19- mkShell rec {
19+ mkShell {
2020 name = "prompt-style.lua" ;
2121 buildInputs = [
22- ( lua5_3 . withPackages packages )
2322 ( luajit . withPackages packages )
2423 neovim
24+
25+ ( lua5_4 . withPackages packages )
2526 pandoc
26- ( builtins . elemAt texlive . luatex . pkgs 2 )
27- ( builtins . elemAt texlive . luahbtex . pkgs 2 )
28- ( builtins . elemAt texlive . luajittex . pkgs 2 )
2927 ] ;
30- shellHook = ''
31- export LUAINPUTS_luatex="${ ./. } /lua;${ builtins . elemAt buildInputs 0 } /share/lua/5.3"
32- export CLUAINPUTS_luatex="${ builtins . elemAt buildInputs 0 } /lib/lua/5.3"
33- export LUAINPUTS_luajittex="${ ./. } /lua;${ builtins . elemAt buildInputs 1 } /share/lua/5.1"
34- export CLUAINPUTS_luajittex="${ builtins . elemAt buildInputs 1 } /lib/lua/5.1"
35-
36- export LUAINPUTS_luahbtex="$LUAINPUTS_luatex"
37- export CLUAINPUTS_luahbtex="$CLUAINPUTS_luatex"
38- export LUAINPUTS_luajithbtex="$LUAINPUTS_luajittex"
39- export CLUAINPUTS_luajithbtex="$CLUAINPUTS_luajittex"
40- '' ;
4128}
Original file line number Diff line number Diff line change @@ -43,7 +43,6 @@ build = {
4343 -- cannot use _VERSION
4444 bin = {
4545 " bin/nvimp" ,
46- " bin/texluap" ,
4746 " bin/pandocp" ,
4847 " bin/neomuttp"
4948 },
You can’t perform that action at this time.
0 commit comments