diff options
| author | gsabin <sabinghimire071@gmail.com> | 2025-02-27 11:14:21 +0100 |
|---|---|---|
| committer | gsabin <sabinghimire071@gmail.com> | 2025-02-27 11:14:21 +0100 |
| commit | 0c18ad85755f06002ce2088125daf217402f011f (patch) | |
| tree | b226538e00460a57cda4805eb47ff60b41b1b81b /_extensions | |
| parent | 2532a17eda917996481441260839ecfa6700961b (diff) | |
start of the prototype detecting and removing curly braces
Diffstat (limited to '_extensions')
| -rw-r--r-- | _extensions/protoExtension/_extension.yml | 7 | ||||
| -rw-r--r-- | _extensions/protoExtension/proto.lua | 14 |
2 files changed, 21 insertions, 0 deletions
diff --git a/_extensions/protoExtension/_extension.yml b/_extensions/protoExtension/_extension.yml new file mode 100644 index 0000000..f00b3c5 --- /dev/null +++ b/_extensions/protoExtension/_extension.yml @@ -0,0 +1,7 @@ +name: protoExtension +title: Prototype for html +version: 1.0.0 +quarto-required: ">=1.3.0" +contributes: + filters: + - proto.lua diff --git a/_extensions/protoExtension/proto.lua b/_extensions/protoExtension/proto.lua new file mode 100644 index 0000000..cb29c31 --- /dev/null +++ b/_extensions/protoExtension/proto.lua @@ -0,0 +1,14 @@ +-- Function to replace variations of Leandre with Léandre. +function Str(el) + i , j = string.find(el.text,"{") + if i ~= nil then a = string.find(el.text,"}") + print(i) + print(string.sub(el.text,i,a)) + b = string.sub(el.text,0,i-1) + c = string.sub(el.text,a+1,-1) + el.text = b .. c + + end + + return el +end |
