aboutsummaryrefslogtreecommitdiffhomepage
path: root/core/ext
diff options
context:
space:
mode:
authorGravatar mitchell <70453897+667e-11@users.noreply.github.com>2010-03-23 06:12:30 -0400
committerGravatar mitchell <70453897+667e-11@users.noreply.github.com>2010-03-23 06:12:30 -0400
commit2e042c305207e52831c1d5eb0706e2ebbf94ab1b (patch)
treeea0aadbac77f25bfb3eb6847992336785380d745 /core/ext
parent16a3aaf2125c05234355f8f322e22680a0b79f0b (diff)
Added textadept.user_dofile to load user files like key commands and snippets.
Diffstat (limited to 'core/ext')
-rw-r--r--core/ext/key_commands.lua7
1 files changed, 1 insertions, 6 deletions
diff --git a/core/ext/key_commands.lua b/core/ext/key_commands.lua
index f318c08d..70357a5a 100644
--- a/core/ext/key_commands.lua
+++ b/core/ext/key_commands.lua
@@ -462,12 +462,7 @@ else
keys.cad = { 'del_word_right', b }
end
--- Load user key commands.
-local lfs = require 'lfs'
-if lfs.attributes(_USERHOME..'/key_commands.lua') then
- local ret, errmsg = pcall(dofile, _USERHOME..'/key_commands.lua')
- if not ret then textadept.print(errmsg) end
-end
+textadept.user_dofile('key_commands.lua') -- load user key commands
---
-- This module has no functions.