mirror of
https://github.com/neovim/neovim.git
synced 2026-07-22 09:01:45 +00:00
Removed restricted mode - Fix #11972
This commit is contained in:
@@ -973,7 +973,7 @@ name). This is included for backwards compatibility with version 3.0, the
|
||||
|
||||
Note: Where a file name is expected wildcards expansion is done. On Unix the
|
||||
shell is used for this, unless it can be done internally (for speed).
|
||||
Unless in |restricted-mode|, backticks work also, like in >
|
||||
Backticks work also, like in >
|
||||
:n `echo *.c`
|
||||
But expansion is only done if there are any wildcards before expanding the
|
||||
'%', '#', etc.. This avoids expanding wildcards inside a file name. If you
|
||||
|
||||
@@ -20,8 +20,8 @@ additionally sets up for viewing the differences between the arguments. >
|
||||
|
||||
nvim -d file1 file2 [file3 [file4]]
|
||||
|
||||
In addition to the |-d| argument, |-Z| and |-R| may be used for restricted
|
||||
mode and readonly mode respectively.
|
||||
In addition to the |-d| argument, |-R| may be used for readonly mode
|
||||
respectively.
|
||||
|
||||
The second and following arguments may also be a directory name. Vim will
|
||||
then append the file name of the first argument to the directory name to find
|
||||
|
||||
@@ -5698,7 +5698,6 @@ libcall({libname}, {funcname}, {argument})
|
||||
If {argument} is a number, it is passed to the function as an
|
||||
int; if {argument} is a string, it is passed as a
|
||||
null-terminated string.
|
||||
This function will fail in |restricted-mode|.
|
||||
|
||||
libcall() allows you to write your own 'plug-in' extensions to
|
||||
Vim without having to recompile the program. It is NOT a
|
||||
@@ -8804,7 +8803,6 @@ system({cmd} [, {input}]) *system()* *E677*
|
||||
{cmd} is a string: 'shell' 'shellcmdflag' {cmd}
|
||||
|
||||
The resulting error code can be found in |v:shell_error|.
|
||||
This function will fail in |restricted-mode|.
|
||||
|
||||
Note that any wrong value in the options mentioned above may
|
||||
make the function fail. It has also been reported to fail
|
||||
|
||||
@@ -185,18 +185,6 @@ argument.
|
||||
the 'modifiable' and 'write' options can be set to enable
|
||||
changes and writing.
|
||||
|
||||
*-Z* *restricted-mode* *E145* *E981*
|
||||
-Z Restricted mode. All commands that make use of an external
|
||||
shell are disabled. This includes suspending with CTRL-Z,
|
||||
":sh", filtering, the system() function, backtick expansion
|
||||
and libcall().
|
||||
Also disallowed are delete(), rename(), mkdir(), jobstart(),
|
||||
etc.
|
||||
Interfaces, such as Python, Ruby and Lua, are also disabled,
|
||||
since they could be used to execute shell commands.
|
||||
Note that the user may still find a loophole to execute a
|
||||
shell command, it has only been made difficult.
|
||||
|
||||
-e *-e* *-E*
|
||||
-E Start Nvim in Ex mode |gQ|.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user