GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - nocksock/do.nvim: A tiny task manager within nvim that helps you stay on track. (づ◡﹏◡)づ

BranchesTags
Open more actions menu

Latest commit

 

History

70 Commits
70 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
assets
assets
 
 
demo
demo
 
 
lua
lua
 
 
tests
tests
 
 
.do_tasks
.do_tasks
 
 
.editorconfig
.editorconfig
 
 
.gitignore
.gitignore
 
 
.luacheckrc
.luacheckrc
 
 
README.md
README.md
 
 

Repository files navigation

Do.nvim

A tiny task manager within nvim that helps you stay on track.

Preview

Introduction

Introduction Gif

Rationale

While coding, we often need to do several things that depend on another. And it's quite easy to loose track of what we initially set out to do in the first place, which is also know as Yak Shaving. Or we just have a list of tasks that we want to work off step by step.

This plugin provides a few simple commands to help you stay on track.

It manages a list of things and always shows you the first item. It provides you with some commands to add things to it, without leaving context. And it uses a simple, intuitive floating buffer to manage that list.

Usage

  • :Do add a line to the end of the list.
  • :Do! add a line to the front of list.
  • :Done! remove the first line from the list.
  • :DoEdit edit the list in a floating window.
  • :DoSave create .do_tasks file in cwd. Will auto-sync afterwards.
  • :DoToggle toggle the display. Use with caution!

Installation

Requires Neovim 0.8.

-- use the package manager of your choice, eg. packer
use("https://github.com/nocksock/do.nvim")

-- setup wherever you do that in you config (eg init.lua)
require("do").setup({
  -- default options
  message_timeout = 2000, -- how long notifications are shown
  kaomoji_mode = 0, -- 0 kaomoji everywhere, 1 skip kaomoji in doing
  winbar = false,
  doing_prefix = "Doing: ",
  store = {
    auto_create_file = false, -- automatically create a .do_tasks when calling :Do
    file_name = ".do_tasks",
  }
})

Winbar

This plugin felt best to me using the winbar - which is a new feature in neovim 0.8. In order to use it, enable it:

require('do').setup({
  winbar = true
})

Lualine

In case you'd rather use it in the statusline or tabbar, you can use the exposed views to do so. For example with lualine:

require('lualine').setup {
  winbar = {
    lualine_a = {
      function()
        return require('do').view('active')
      end,
    },
  },
  inactive_winbar = {
    -- in order to prevent jumping of code in certain cursor positions this will
    -- (at the moment) show an empty line - but only if .view has contents.
    lualine_a = { require("do").view_inactive },
  },
}

Events

This plugin exposes a custom event, for when a task is added or modified. You can use it like so:

vim.api.nvim_create_autocmd({ "User" }, {
   group = require("do.state").state.auGroupID,
   pattern = "TaskModified",
   desc = "This is called when a task is added or deleted",
   callback = function()
      vim.notify("A task has been modified")
   end,
})

Development

Run tests

Running tests requires plenary.nvim to be checked out in the parent directory of this repository. You can then run:

nvim --headless --noplugin -u tests/minimal.vim -c "PlenaryBustedDirectory tests/ {minimal_init = 'tests/minimal.vim'}"

Or if you want to run a single test file:

nvim --headless --noplugin -u tests/minimal.vim -c "PlenaryBustedDirectory tests/path_to_file.lua {minimal_init = 'tests/minimal.vim'}"

About

A tiny task manager within nvim that helps you stay on track. (づ◡﹏◡)づ

Topics

luaneovimneovim-lua-pluginneovim-pluginnvimnvim-plugintodo-list

Resources

Readme
Activity

Stars

60 stars

Watchers

1 watching

Forks

5 forks
Report repository

Used by

Contributors

Languages

Generated from nvim-lua/nvim-lua-plugin-template
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.