comparison src/ex_cmds.h @ 15085:1783c0b6bc2e v8.1.0553

patch 8.1.0553: it is not easy to edit a script that was sourced commit https://github.com/vim/vim/commit/07dc18ffa4e7ed202f219fe2fd3d6f58246f71f9 Author: Bram Moolenaar <Bram@vim.org> Date: Fri Nov 30 22:48:32 2018 +0100 patch 8.1.0553: it is not easy to edit a script that was sourced Problem: It is not easy to edit a script that was sourced. Solution: Add a count to ":scriptnames", so that ":script 40" edits the script with script ID 40.
author Bram Moolenaar <Bram@vim.org>
date Fri, 30 Nov 2018 23:00:06 +0100
parents 405309f9dd13
children 1ef429366fd4
comparison
equal deleted inserted replaced
15084:e25cb9813f25 15085:1783c0b6bc2e
60 #define FILES (XFILE | EXTRA) /* multiple extra files allowed */ 60 #define FILES (XFILE | EXTRA) /* multiple extra files allowed */
61 #define WORD1 (EXTRA | NOSPC) /* one extra word allowed */ 61 #define WORD1 (EXTRA | NOSPC) /* one extra word allowed */
62 #define FILE1 (FILES | NOSPC) /* 1 file allowed, defaults to current file */ 62 #define FILE1 (FILES | NOSPC) /* 1 file allowed, defaults to current file */
63 63
64 /* values for cmd_addr_type */ 64 /* values for cmd_addr_type */
65 #define ADDR_LINES 0 65 #define ADDR_LINES 0 // buffer line numbers
66 #define ADDR_WINDOWS 1 66 #define ADDR_WINDOWS 1 // window number
67 #define ADDR_ARGUMENTS 2 67 #define ADDR_ARGUMENTS 2 // argument number
68 #define ADDR_LOADED_BUFFERS 3 68 #define ADDR_LOADED_BUFFERS 3 // buffer number of loaded buffer
69 #define ADDR_BUFFERS 4 69 #define ADDR_BUFFERS 4 // buffer number
70 #define ADDR_TABS 5 70 #define ADDR_TABS 5 // tab page number
71 #define ADDR_TABS_RELATIVE 6 /* Tab page that only relative */ 71 #define ADDR_TABS_RELATIVE 6 // Tab page that only relative
72 #define ADDR_QUICKFIX 7 72 #define ADDR_QUICKFIX 7 // quickfix list entry number
73 #define ADDR_OTHER 99 73 #define ADDR_OTHER 99 // something else
74 74
75 #ifndef DO_DECLARE_EXCMD 75 #ifndef DO_DECLARE_EXCMD
76 typedef struct exarg exarg_T; 76 typedef struct exarg exarg_T;
77 #endif 77 #endif
78 78
1258 ADDR_LINES), 1258 ADDR_LINES),
1259 EX(CMD_sbrewind, "sbrewind", ex_brewind, 1259 EX(CMD_sbrewind, "sbrewind", ex_brewind,
1260 EDITCMD|TRLBAR, 1260 EDITCMD|TRLBAR,
1261 ADDR_LINES), 1261 ADDR_LINES),
1262 EX(CMD_scriptnames, "scriptnames", ex_scriptnames, 1262 EX(CMD_scriptnames, "scriptnames", ex_scriptnames,
1263 TRLBAR|CMDWIN, 1263 BANG|RANGE|NOTADR|COUNT|TRLBAR|CMDWIN,
1264 ADDR_LINES), 1264 ADDR_OTHER),
1265 EX(CMD_scriptencoding, "scriptencoding", ex_scriptencoding, 1265 EX(CMD_scriptencoding, "scriptencoding", ex_scriptencoding,
1266 WORD1|TRLBAR|CMDWIN, 1266 WORD1|TRLBAR|CMDWIN,
1267 ADDR_LINES), 1267 ADDR_LINES),
1268 EX(CMD_scscope, "scscope", ex_scscope, 1268 EX(CMD_scscope, "scscope", ex_scscope,
1269 EXTRA|NOTRLCOM, 1269 EXTRA|NOTRLCOM,