aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2018-11-27 11:20:31 -0500
committermitchell <70453897+667e-11@users.noreply.github.com>2018-11-27 11:20:31 -0500
commitc1f6b2b75b3853d2eb6b07b83dd6be8bc4c87bbf (patch)
tree3f48668444a40f4ab19f54447d902aa4e166e670 /modules
parent24de6b2672d6f653e7d0691482e96bfc43b179ef (diff)
downloadtextadept-c1f6b2b75b3853d2eb6b07b83dd6be8bc4c87bbf.tar.gz
textadept-c1f6b2b75b3853d2eb6b07b83dd6be8bc4c87bbf.zip
Added command line switch to jump to a buffer line.
This is more convenient than '-e "goto_line(n - 1)"'.
Diffstat (limited to 'modules')
-rw-r--r--modules/textadept/editing.lua1
1 files changed, 1 insertions, 0 deletions
diff --git a/modules/textadept/editing.lua b/modules/textadept/editing.lua
index 2d6ded80..c88781e0 100644
--- a/modules/textadept/editing.lua
+++ b/modules/textadept/editing.lua
@@ -287,6 +287,7 @@ function M.goto_line(line)
buffer:ensure_visible_enforce_policy(line)
buffer:goto_line(line)
end
+args.register('-l', '--line', 1, function(line) M.goto_line(line - 1) end)
---
-- Transposes characters intelligently.