You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+17-2Lines changed: 17 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -135,6 +135,13 @@ The vim-session plug-in uses lock files to prevent double loading of sessions. T
135
135
2. If the directory `/var/lock` exists and is writable that is used as a sane default.
136
136
3. As a sane fall back for platforms where `/var/lock` is not available the directory that stores the session scripts themselves is used.
137
137
138
+
### The `g:session_lock_enabled` option
139
+
140
+
Depending on your workflow locking of editing sessions can get annoying at times, so if you don't care about opening a session more than once and potentially "losing a version of your session" then you can use this option to completely disable session locking as follows:
141
+
142
+
" Disable all session locking - I know what I'm doing :-).
143
+
let g:session_lock_enabled = 0
144
+
138
145
### The `g:session_default_name` option
139
146
140
147
The name of the default session without directory or filename extension (you'll never guess what the default is).
@@ -263,8 +270,8 @@ Recently this plug-in switched from reimplementing [:mksession][mksession] to ac
263
270
264
271
<!-- Start of generated documentation -->
265
272
266
-
The documentation of the 37 functions below was extracted from
267
-
2 Vim scripts on February 13, 2015 at 13:25.
273
+
The documentation of the 38 functions below was extracted from
274
+
2 Vim scripts on February 18, 2015 at 22:56.
268
275
269
276
### Public API for the vim-session plug-in
270
277
@@ -471,6 +478,14 @@ scoped session. Saves a copy of the original value to be restored later.
471
478
472
479
Restore the original value of Vim's [sessionoptions][] option.
473
480
481
+
#### The `xolox#session#locking_enabled()` function
482
+
483
+
Check whether session locking is enabled. Returns true (1) when locking is
484
+
enabled, false (0) otherwise.
485
+
486
+
By default session locking is enabled but users can opt-out by setting
487
+
`g:session_lock_enabled` to false (0).
488
+
474
489
### Example function for session name suggestions
475
490
476
491
#### The `xolox#session#suggestions#vcs_feature_branch()` function
0 commit comments