Giter VIP home page Giter VIP logo

todo-wrangler's Introduction

TODO Wrangler for Obsidian

An Obsidian plugin that wrangles all lines starting with "TODO" in your notes and consolidates them under a unified "TODOs" section.

Features

  • Scan the current note for any lines starting with "TODO" or "- [] TODO" or "- TODO"
  • Automatically consolidate found "TODO" lines into a "TODOs" section at the end of the note.
  • One-click operation using the ribbon icon.

Installation

From GitHub

  1. Navigate to the releases section of the GitHub repository.
  2. Download the latest released main.js, manifest.json, styles.css from Releases.
  3. Create the todo-wrangler in your vault's plugins folder: <vault>/.obsidian/plugins/
    • Note: If you don't have a plugins folder, create one inside the .obsidian directory.
  4. Reload Obsidian
  5. If everything was successful, you should see 'TODO Wrangler' in the list of installed plugins.

From Within Obsidian

The plugin is available in the Obsidian plugin library (TODO Wrangler). You can install the plugin directly from within Obsidian by going to be Settings > Community plugins and searching for "TODO Wrangler".

Usage

  1. Open any note in Obsidian.
  2. Open the command palette (CMD + p on Mac OS X)
  3. Search and run "Wrangle Todos"
  4. All lines in your note starting with "TODO" will be extracted and placed under a "TODOs" section at the end of the note.
    1. If you've changed the keyword in "Settings" then it will extract those.
    2. There are multiple variations of "TODO" (or keyword) it can handle; for instance, lists "- TODO".

Contributing

If you have ideas or feedback for this plugin, please open an issue on GitHub. Pull requests are also welcome!

Acknowledgements

Lots of gratitude to the Obsidian team for creating a phenomenal app and for making it easy for developers to build plugins. Thank you!!

License

This project is licensed under the MIT License. Please see LICENSE.md for the complete license.

todo-wrangler's People

Contributors

jeel-shah avatar toneffectory avatar drumstixnl avatar

Stargazers

 avatar  avatar a13ph avatar

Watchers

 avatar

todo-wrangler's Issues

Add basic testing

Core

We need to have test cases so that the plugin continues to stay robust as we add more features.

Cases

Test Case 1: Default Keyword Recognition

Objective: Verify that the plugin recognizes tasks marked with the default keyword "TODO".
Preconditions: The plugin is installed and activated with default settings.
Input:

TODO Hello

Expected Output:

### TODOs
TODO Hello

Input:

- [x] TODO Bye

Expected Output:

### TODOs
- [x] TODO Bye

Input:

- [ ] TODO Bye

Expected Output:

### TODOs
- [ ] TODO Bye

Test Case 2: Custom Keyword Recognition

Objective: Verify that the plugin recognizes tasks marked with a custom keyword set in the plugin settings.
Preconditions: The plugin is installed, activated, and the user has set a custom keyword in the settings (e.g., "DONE").

The above inputs/outputs should also work with the custom keyword.

Include ":" in keywords

Core

Presently, the Wrangler will only move pre-defined keywords which fit into the following cases:

  • - [] keyword
  • keyword
  • [] keyword

Generally, the Regex is '^-?\\s*(\\[x?\\])?\\s*' + keyword.

However, we also need to include : so it's quite common to have a colon right after the keyword.

Acceptance Criteria

  • Users can include : in their keyword
  • Users cannot include : in the settings

Extract nested todos (keywords) from a file

What happened?

  1. I had a bulleted list with multiple levels and it only extracted the TODOs from the top level

What should have happened?

  1. All TODOs should have been extracted independent of their level in the bulleted list

Steps to reproduce

  1. Create a list of items with nested items (see sample below)
  2. Label some of items with TODO (or your keyword)
  3. Run "TODO Wrangler"
  4. Result: only top level keywords will have been extracted

Sample

- TODO Hello World
    - TODO Hi there
- TODO Hello

Checkbox markdown code not consolidated

Currently, lines starting with "TODO" or "- [] TODO" or "- TODO" will get consolidated.
However proper markdown code for a checkbox includes a whitespace between the brackets. But this is not consolidated.
Obsidian only renders a checkbox when done this way - [ ]. It will not render - [] into a checkbox because of the missing whitespace.

So my question would be: would it be possible to add - [ ] TODO to the list of "to be consolidated TODO lines"?

Plugin cannot be installed

Hi @Jeel-Shah

We have noticed that the latest release of your plugin cannot be installed currently.

This is due to the following reasons:

  • no manifest.json in latest release
  • no `main,js´ in latest release

We will remove this plugin from the community plugins if this issue is not fixed within 30 days.

  • The Obsidian Team

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.