Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vim: add extra session file Sessionx.vim #3058

Merged
merged 1 commit into from May 16, 2019
Merged

Conversation

@wilhelmtell
Copy link
Contributor

@wilhelmtell wilhelmtell commented May 15, 2019

from vim's documentation on :mksession (:help :mksession):

...

  1. If a file exists with the same name as the Session file, but ending
    in "x.vim" (for eXtra), executes that as well. You can use *x.vim
    files to specify additional settings and actions associated with a
    given Session, such as creating menu items in the GUI version.

we already have Session.vim ignored. the Sessionx.vim file, like
Session.vim, is a user file. a user would generally want that file kept
private or for themselves, and the public or a team fetching from or
sharing the repository generally have no interest in a file relevant
only to a particular user. so it's a good idea to get git to help us
avoid mistakenly sharing the file.

from vim's documentation on `:mksession` (:help :mksession):

 ...

 10. If a file exists with the same name as the Session file, but ending
     in "x.vim" (for eXtra), executes that as well.  You can use *x.vim
     files to specify additional settings and actions associated with a
     given Session, such as creating menu items in the GUI version.

we already have Session.vim ignored.  the Sessionx.vim file, like
Session.vim, is a user file.  a user would generally want that file kept
private or for themselves, and the public or a team fetching from or
sharing the repository generally have no interest in a file relevant
only to a particular user.  so it's a good idea to get git to help us
avoid mistakenly sharing the file.
@wilhelmtell
Copy link
Contributor Author

@wilhelmtell wilhelmtell commented May 15, 2019

It's unfortunate that Vim's session filenames are indistinguishable from any other Vim script. A user may create a session with :mksession yesterday.vim, and there is no reasonable way for a gitignore to capture that, because, as far as telling by name, that file could be a shared vimscript as well as a user's session file. Session files can take any of a gazillion names, and so so do their accompanying *x.vim file...

@shiftkey
Copy link
Member

@shiftkey shiftkey commented May 16, 2019

@wilhelmtell thanks!

@shiftkey shiftkey merged commit cdab24d into github:master May 16, 2019
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@wilhelmtell wilhelmtell deleted the wilhelmtell:topic/vim/sessionx.vim branch May 16, 2019
Ortega-Dan added a commit to Ortega-Dan/gitignore that referenced this pull request Jun 26, 2019
from vim's documentation on `:mksession` (:help :mksession):

 ...

 10. If a file exists with the same name as the Session file, but ending
     in "x.vim" (for eXtra), executes that as well.  You can use *x.vim
     files to specify additional settings and actions associated with a
     given Session, such as creating menu items in the GUI version.

we already have Session.vim ignored.  the Sessionx.vim file, like
Session.vim, is a user file.  a user would generally want that file kept
private or for themselves, and the public or a team fetching from or
sharing the repository generally have no interest in a file relevant
only to a particular user.  so it's a good idea to get git to help us
avoid mistakenly sharing the file.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants