File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ local config = {
1414}
1515
1616local function random_char ()
17- local characters = " abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789`~!@#$%^&*)(-=][ \' ; \" /.,_+}{|:?>< "
17+ local characters = " abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
1818 local random_index = math.random (1 , string.len (characters ))
1919 local picked_character = string.sub (characters , random_index , random_index )
2020 return picked_character
@@ -32,7 +32,8 @@ function M.run()
3232 vim .cmd (config .split_cmd )
3333 vim .cmd (" enew" )
3434 local buf = vim .api .nvim_get_current_buf ()
35- vim .api .nvim_buf_set_name (buf , " crunner: " .. name .. " ." .. ext .. " _" .. random_char () .. random_char ())
35+ local random_chars = random_char () .. random_char () .. random_char ()
36+ vim .api .nvim_buf_set_name (buf , " crunner: " .. name .. " ." .. ext .. " _" .. random_chars )
3637 vim .api .nvim_buf_set_option (buf , " buftype" , " nofile" )
3738 vim .api .nvim_buf_set_option (buf , " bufhidden" , " hide" ) -- hide on close
3839 vim .api .nvim_buf_set_option (buf , " buflisted" , false ) -- not in tabline
You can’t perform that action at this time.
0 commit comments