Skip to content

Commit 0cf8ba6

Browse files
committed
Add remove file utility
1 parent 4728359 commit 0cf8ba6

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/resources/pandoc/datadir/init.lua

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1733,6 +1733,10 @@ local function file_exists(name)
17331733
return content
17341734
end
17351735

1736+
local function remove_file(path)
1737+
return os.remove(path)
1738+
end
1739+
17361740
-- Quarto internal module - makes functions available
17371741
-- through the filters
17381742
_quarto = {
@@ -1751,7 +1755,8 @@ _quarto = {
17511755
file = {
17521756
read = read_file,
17531757
write = write_file,
1754-
exists = file_exists
1758+
exists = file_exists,
1759+
remove = remove_file
17551760
}
17561761
}
17571762

0 commit comments

Comments
 (0)