All Projects → Shatur → neovim-session-manager

Shatur / neovim-session-manager

Licence: GPL-3.0 license
A simple wrapper around :mksession

Programming Languages

lua
6591 projects

Projects that are alternatives of or similar to neovim-session-manager

TART
Transient Array Radio Telescope
Stars: ✭ 20 (-86.49%)
Mutual labels:  telescope
myProjects
This repository contains exercise,projects and that I practiced to improve my coding skills.
Stars: ✭ 18 (-87.84%)
Mutual labels:  projects
BuyXMWear2Plugin
最近在小米官网上抢小米手环2一直抢不到,深痛小米恶心的饥饿营销,但是喜欢的宝贝还是要买滴[嘻嘻嘻],咋办呢?。刚好昨天阿里内部抢月饼的事件闹到头条,何不像他们学习写个插件抢手环2呢,何乐而不为!
Stars: ✭ 16 (-89.19%)
Mutual labels:  projects
UDACITY-Deep-Learning-Nanodegree-PROJECTS
These are the projects I did on my Udacity Deep Learning Nanodegree 🌟 💻 💻. 💥 🌈
Stars: ✭ 18 (-87.84%)
Mutual labels:  projects
Hacktoberfest
Hacktoberfest 2021 you can add anything like simple programs or projects
Stars: ✭ 15 (-89.86%)
Mutual labels:  projects
CODE-CAMP-2020
A Virtual Hackathon Camp for Developers, Build real products and win Swags in comfort of your home.
Stars: ✭ 30 (-79.73%)
Mutual labels:  projects
links-uteis
📎 A curated list of awesome project development links
Stars: ✭ 2,547 (+1620.95%)
Mutual labels:  projects
ML-ProjectKart
🙌Kart of 210+ projects based on machine learning, deep learning, computer vision, natural language processing and all. Show your support by ✨ this repository.
Stars: ✭ 162 (+9.46%)
Mutual labels:  projects
made-in-cameroon
A curated list of awesome tools and projects built by Cameroonian developers
Stars: ✭ 14 (-90.54%)
Mutual labels:  projects
Hacktober-Fest-2021
📜This repository is created to welcome all the open source enthusiasts to get introduced to beginner friendly projects they could work with in the festive season of HacktoberFest 2021🎇🙌.
Stars: ✭ 23 (-84.46%)
Mutual labels:  projects
AstroPhoto-Plus
A lightweight, web based astrophotography sequence generator and INDI client written in Python and React.
Stars: ✭ 54 (-63.51%)
Mutual labels:  telescope
github-notifications.nvim
Statusline + Telescope integration for viewing and interacting with GitHub notifications
Stars: ✭ 70 (-52.7%)
Mutual labels:  telescope
awesome-maldives
A curated list of amazingly awesome libraries, resources and shiny things made by maldivian developers.
Stars: ✭ 16 (-89.19%)
Mutual labels:  projects
WatchCon
WatchCon is a tool which enables creating easy connectivity between iOS and WatchOS.
Stars: ✭ 32 (-78.38%)
Mutual labels:  sessions
pacco
A bundler for modular and extensible web projects.
Stars: ✭ 16 (-89.19%)
Mutual labels:  projects
telescope-repo.nvim
🦘 Jump into the repositories (git, mercurial…) of your filesystem with telescope.nvim, without any setup
Stars: ✭ 99 (-33.11%)
Mutual labels:  telescope
assign-one-project-github-action
Automatically add an issue or pull request to specific GitHub Project(s) when you create and/or label them.
Stars: ✭ 140 (-5.41%)
Mutual labels:  projects
awesome-hackathon-projects
This is a curated list of amazing hackathon projects
Stars: ✭ 193 (+30.41%)
Mutual labels:  projects
telescope-github.nvim
Integration with github cli
Stars: ✭ 129 (-12.84%)
Mutual labels:  telescope
BEW-1.3-Server-Side-Architectures-and-Frameworks
🔐 Build on knowledge of Resourceful and RESTful patterns and dive deep into the Node and Express ecosystem.
Stars: ✭ 19 (-87.16%)
Mutual labels:  sessions

Neovim Session Manager

A Neovim 0.7+ plugin that use built-in :mksession to manage sessions like folders in VSCode. It allows you to save the current folder as a session to open it later. The plugin can also automatically load the last session on startup, save the current one on exit and switch between session folders.

The plugin saves the sessions in the specified folder (see configuration). The session corresponds to the working directory. If a session already exists for the current folder, it will be overwritten.

Dependencies

Commands

Use the command :SessionManager[!] with one of the following arguments:

Argument Description
load_session Select and load session.
load_last_session Will remove all buffers and :source the last saved session.
load_current_dir_session Will remove all buffers and :source the last saved session file of the current dirtectory.
save_current_session Works like :mksession, but saves/creates current directory as a session in sessions_dir.
delete_session Select and delete session.

When ! is specified, the modified buffers will not be saved.

Commands load_session and delete_session use vim.ui.select(). To use your favorite picker like Telescope, consider installing dressing.nvim or telescope-ui-select.nvim.

Configuration

To configure the plugin, you can call require('session_manager').setup(values), where values is a dictionary with the parameters you want to override. Here are the defaults:

local Path = require('plenary.path')
require('session_manager').setup({
  sessions_dir = Path:new(vim.fn.stdpath('data'), 'sessions'), -- The directory where the session files will be saved.
  path_replacer = '__', -- The character to which the path separator will be replaced for session files.
  colon_replacer = '++', -- The character to which the colon symbol will be replaced for session files.
  autoload_mode = require('session_manager.config').AutoloadMode.LastSession, -- Define what to do when Neovim is started without arguments. Possible values: Disabled, CurrentDir, LastSession
  autosave_last_session = true, -- Automatically save last session on exit and on session switch.
  autosave_ignore_not_normal = true, -- Plugin will not save a session when no buffers are opened, or all of them aren't writable or listed.
  autosave_ignore_filetypes = { -- All buffers of these file types will be closed before the session is saved.
    'gitcommit',
  }, 
  autosave_only_in_session = false, -- Always autosaves session. If true, only autosaves after a session is active.
  max_path_length = 80,  -- Shorten the display path if length exceeds this threshold. Use 0 if don't want to shorten the path at all.
})

Autocommands

You can specify commands to be executed automatically after saving or loading a session using the following events:

Event Description
SessionSavePost Executed after a session is saved
SessionLoadPost Executed after a session is loaded

For example, if you would like to have NvimTree or any other file tree automatically opened after a session load, have this somewhere in your config file:

local config_group = vim.api.nvim_create_augroup('MyConfigGroup', {}) -- A global group for all your config autocommands

vim.api.nvim_create_autocmd({ 'SessionLoadPost' }, {
  group = config_group,
  callback = function()
    require('nvim-tree').toggle(false, true)
  end,
})

For more information about autocmd and its event, see also:

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].