aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/os
Commit message (Collapse)AuthorAge
...
| * | Add guards for SIGPIPE and SIGQUITRui Abreu Ferreira2015-12-08
| | | | | | | | | | | | In some systems the signals SIGPIPE and SIGQUIT are not available.
* | | Windows: Define HOME environment variableRui Abreu Ferreira2015-12-08
|/ / | | | | | | | | | | - Bring back Vim code for settings $HOME in Windows from $HOMEDRIVE$HOMEPATH - vim-patch:0
* | Windows: Add path definitions for Windows.Seth Jackson2015-11-29
| |
* | Windows: Only redefine ssize_t for MSVCRui Abreu Ferreira2015-11-26
| | | | | | | | MinGW already has a redefine for ssize_t.
* | Return libuv error code from os_getperm()Rui Abreu Ferreira2015-11-25
| | | | | | | | | | | | | | | | | | | | | | Previously os_getperms() returned -1 for any error condition, it now returns the libuv error code (as returned by os_stat()). This allows checking for error conditions without relying on errno (which not available in Windows). The only case where the errno value from os_getperms() was being used was in readfile() to set the new-file flag - replaced the errno check with UV_ENOENT.
* | Return libuv return code from os_stat()Rui Abreu Ferreira2015-11-25
| | | | | | | | | | | | Instead of returning bool from os_stat return the actual libuv return code. This function is static and used internally in nvim/os/fs.c it should not impact the rest of the API. This is a first step to change other fs functions.
* | Fix comments for os_* functions return valueRui Abreu Ferreira2015-11-25
|/ | | | | | In windows libuv does not return -errno, instead it uses negative error codes e.g. UV_ENOENT. This commit changes the comments in os_* functions to reflect this.
* os/fs.c: Convert stray getenv() to os_getenv()Michael Reed2015-10-31
| | | | | | | This is the last direct getenv() call in the tree (besides the one in os_getenv()); most of the work was already done in [1]. [1]: 412d246be71bd99cb4edde4e6f984b0b0d91bcd9
* Merge pull request #3553 from ZyX-I/fix-xdg-2Justin M. Keyes2015-10-30
|\ | | | | Some more fixes to XDG code
| * stdpaths: Document that stdpaths_*_subpath is not returning NULLZyX2015-10-29
| |
| * stdpaths: Use NULL in place of empty stringsZyX2015-10-29
| |
* | os/input.c: Fix assertion in `create_cursorhold_event`Thiago de Arruda2015-10-29
|/ | | | The assertion now considers the case where events are disabled.
* main: Refactor normal_enter to call `os_inchar` directlyThiago de Arruda2015-10-26
| | | | | | | | | This makes it impossible for K_EVENT to interfere with mappings, but it also disables processing of events while in the middle of a mapping (Though this will be fixed later as this refactoring progresses). `may_sync_undo` is now called when K_EVENT is received. This is necessary to correctly update undo entry lists before executing some action.
* input: Remove CURSORHOLD keyThiago de Arruda2015-10-26
| | | | | | | | | | | Refactor input.c, normal.c and edit.c to use the K_EVENT special key to trigger the CURSORHOLD event. In normal and edit mode, K_EVENT is treated as K_CURSORHOLD, which enables better handling of arbitrary actions in those states(eg: In normal mode the previous operator counts will be restored). Also fix a test in vim_spec.lua. The test had a wrong assumption: cmdheight is only used to determine when the press enter screen will be shown, not to limit how many lines or control pagination.
* os/unix_defs: Rename default system vimrc file to sysinit.vimZyX2015-10-24
| | | | This way all standard Vim file paths have .vim extension. VIMRC_FILE constant used for &exrc option was not touched.
* os/fs: Allow os_mkdir_recurse directory name to end with ///ZyX2015-10-23
|
* stdpaths: Remove outdated commentZyX2015-10-23
|
* stdpaths: Add Windows-specific directoriesZyX2015-10-23
|
* stdpaths: Add missing includeZyX2015-10-23
|
* stdpaths: Remove Apple defaults, use \*nix ones insteadZyX2015-10-23
|
* main,version: Remove USR_EXRC_FILE*ZyX2015-10-23
|
* option: Add `//` to the end of default `&directory`ZyX2015-10-23
|
* stdpaths: Add documentationZyX2015-10-23
|
* main,os/env: Fix lint errorsZyX2015-10-23
|
* stdpaths: Do NOT create data directoriesZyX2015-10-23
| | | | | | This is none of option.c business to create *possibly unneeded* **default** directories **before** user specified where he actually wants to place the files.
* stdpaths: Give proper error message in case directory creation failedZyX2015-10-23
|
* shada: Move shada file to a new locationZyX2015-10-23
|
* stdpaths,main: Remove all remaining memory leaksZyX2015-10-23
|
* stdpaths: Export get_xdg function (renamed) and use it for runtimepathZyX2015-10-23
|
* stdpaths: Rename export functions so that they have common prefixZyX2015-10-23
|
* stdpaths: Remove useless functions get_user_*_dirZyX2015-10-23
|
* stdpaths: Fix some issues, specificallyZyX2015-10-23
| | | | | | | - Remove/add includes - Do not pretend that returns are const - Add function attributes - Allocate memory always in get_xdg
* option: Use different default value for &runtimepathZyX2015-10-23
|
* os/env: Add functions that can iterate over colon-separated variablesZyX2015-10-23
|
* option,main: Partial support of XDG base directory specificationKeerthan Jaic2015-10-23
| | | | | | | | | | | | - Add functions that are able to query XDG. - Replace defaults for - &runtimepath. Does not follow #78. - &viewdir. - &undodir. - &directory. - &backupdir. Does not follow #78. - vimrc location. - Remove user vimrc file line from :version message.
* os/time: Make Timestamp be 64-bit unsigned integerZyX2015-10-08
|
* viminfo: First version of ShaDa file dumpingZyX2015-10-08
| | | | | | | | | | | | | | | | | | | | What works: 1. ShaDa file dumping: header, registers, jump list, history, search patterns, substitute strings, variables. 2. ShaDa file reading: registers, global marks, variables. Most was not tested. TODO: 1. Merging. 2. Reading history, local marks, jump and buffer lists. 3. Documentation update. 4. Converting some data from &encoding. 5. Safer variant of dumping viminfo (dump to temporary file then rename). 6. Removing old viminfo code (currently masked with `#if 0` in a ShaDa file for reference).
* os/fs: Define os_strerror as an alias to uv_strerrorZyX2015-10-08
| | | | It is not needed to know that os/* uses libuv.
* os/input: Don't advance past incomplete sequences in input_enqueueThiago de Arruda2015-10-01
| | | | | This allows callers to incrementally process buffers that are filled by incomplete chunks more easily.
* remove HAVE_DUP #1072Justin M. Keyes2015-09-12
| | | | | Vim defines this for Windows, so there's no Neovim-supported system for which this would not be defined.
* do_path_expand: Avoid non-readable directories. #3273Felipe Morales2015-09-04
| | | | | | | | | | Closes https://github.com/neovim/neovim/issues/3164 Closes https://github.com/neovim/neovim/issues/3194 Closes https://github.com/neovim/neovim/issues/3221 Helped-by: @splinterofchaos Helped-by: @oni-link Helped-by: @justinmk
* Windows: Define USE_CRNL on Windows. #3249Seth Jackson2015-08-28
|
* Windows: avoid "uv_" naming conflicts. #3225Seth Jackson2015-08-27
|
* os/os_defs.h cleanup: Remaining signal stuffMichael Reed2015-08-27
| | | | | | | | | | | | RETSIGTYPE, SIGRETURN, and SIGDEFARG are always defined the same, so inline them for simplicity; SIGDUMMYARG, however, is unused, so remove it. Even if these things don't work on windows, the signal handler in if_cscope.c is already wrapped with '#idef UNIX', as is its only call site. Reviewed-by: Justin M. Keyes <justinkz@gmail.com>
* os/os_defs.h cleanup: SIGHASARGMichael Reed2015-08-27
| | | | It's always defined, so the #else is redundant.
* os/os_defs.h cleanup: SIGHAS3ARGSMichael Reed2015-08-27
| | | | | | | | | | | SIGHAS3ARGS appears in Vim's source code like this: /* List 3 arg systems here. I guess __sgi, please test and correct me. jw. */ if defined(__sgi) && defined(HAVE_SIGCONTEXT) define SIGHAS3ARGS endif Given we don't support SGI, remove it.
* os/os-defs.h cleanup: Don't include <time.h>Michael Reed2015-08-27
| | | | | Any files which need definitions from <time.h> should include it, not "os/os_defs.h".
* MSVC: Define `inline` and `restrict`. #3237Seth Jackson2015-08-25
| | | | | | | | MSVC 2015 defines __func__ (C++11). https://msdn.microsoft.com/en-us/library/dn919276.aspx MSVC only allows inline in C++ and requires __inline in C instead. https://msdn.microsoft.com/en-us/library/bw1hbe6y.aspx
* Windows: Define ssize_t and SSIZE_MAX. #3228Seth Jackson2015-08-25
| | | | | Remove R_OK, W_OK defines because os/os.h includes <uv.h> which includes uv-win.h which defines R_OK and W_OK.
* remove references to <sys/time.h>Justin M. Keyes2015-08-24
| | | | | Since gettimeofday() was replaced by os_time in fb5a786bdb5b7b52b9c36b3eb8b6d2cc002aa8f3 we do not need sys/time.h.