Skip to content

Commit

Permalink
Increase filename length further
Browse files Browse the repository at this point in the history
  • Loading branch information
rikhuijzer committed Jun 27, 2021
1 parent ccc3d23 commit 7b9da6a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/generate.jl
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,8 @@ Escape an expression to the corresponding path.
The logic in this method should match the logic in the Lua filter.
"""
function escape_expr(expr::String)
escaped = 100 < length(expr) ? expr[1:100] : expr
n = 120
escaped = n < length(expr) ? expr[1:n] : expr
escaped = replace(escaped, r"([^a-zA-Z0-9]+)" => "_")
joinpath(GENERATED_DIR, "$escaped.md")
end
Expand Down
3 changes: 2 additions & 1 deletion src/include-codeblocks.lua
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@ end
---
local md_path
function md_path(s)
escaped = string.sub(s, 1, 100)
n = 120
escaped = string.sub(s, 1, n)
escaped = escaped:gsub("([^a-zA-Z0-9]+)", "_")
-- Platform independent path separator.
path_sep = package.config:sub(1, 1)
Expand Down

0 comments on commit 7b9da6a

Please sign in to comment.