aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2020-07-12 22:36:08 -0400
committermitchell <70453897+667e-11@users.noreply.github.com>2020-07-12 22:36:08 -0400
commitebd67cde9828e74339c913a62150eb93ba97fe14 (patch)
treeb2ddd1f3f88dd44030c84f1b98d1d3ca362893d7
parent3c6ad9a4cbc4f17caf0c54c81070e5d9d9a9b783 (diff)
downloadtextadept-ebd67cde9828e74339c913a62150eb93ba97fe14.tar.gz
textadept-ebd67cde9828e74339c913a62150eb93ba97fe14.zip
Fixed --line command line switch.
Line number strings need to be converted to numbers.
-rw-r--r--modules/textadept/editing.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/modules/textadept/editing.lua b/modules/textadept/editing.lua
index b5906aad..5aafe964 100644
--- a/modules/textadept/editing.lua
+++ b/modules/textadept/editing.lua
@@ -366,7 +366,8 @@ function M.goto_line(line)
buffer:goto_line(line)
end
args.register(
- '-l', '--line', 1, function(line) M.goto_line(line) end, 'Go to line')
+ '-l', '--line', 1, function(line) M.goto_line(tonumber(line) or line) end,
+ 'Go to line')
---
-- Transposes characters intelligently.