Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

add todo.txt-cli as a plugin #129

Merged
merged 12 commits into from

3 participants

@erichs
Owner

Since it is referenced in the default .bash_profile and in aliases and
themes, why not make it an official plugin?

This creates a 'todo/' directory in /plugins/available, and installs
todo.sh and friends there. Tab completion and the 't' alias should work
out of the box.

Note: it was also necessary to modify .gitignore to ignore the files
todo.sh generates in custom/.

@erichs erichs add todo.txt-cli as a plugin
Since it is referenced in the default .bash_profile and in aliases and
themes, why not make it an official plugin?

This creates a 'todo/' directory in /plugins/available, and installs
todo.sh and friends there.  Tab completion and the 't' alias should work
out of the box.

Note: it was also necessary to modify .gitignore to ignore the files
todo.sh generates in custom/.
f5badb3
plugins/available/todo.plugin.bash
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+export TODO_DIR=$HOME/.bash_it/custom # store todo items in user's custom dir, ignored by git
@tswicegood Owner

Two things:

  1. s/.bash_it/$BASH_IT/ so its relocatable. Since I just merged the other PR about this, it's sticking out. :-)
  2. What about adding a check for environment variables of the same name and not overriding them? That gives the user a chance to set them in ~/.bash_profile to be custom.
@erichs Owner
erichs added a note

Sure. I'll resubmit with the patch by @nwinkler.

Respecting user overrides is smart. Let's do that, too :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
@tswicegood
Owner

This looks good minus the need for $BASH_IT.

Draiken and others added some commits
@Draiken Draiken updating git.completion.bash 868fcd0
@erichs erichs Merge branch 'master' into todo.sh 00cab2f
@erichs erichs respect profile overrides
overrides may now be specified for any of these defaults:
TODO_DIR=$BASH_IT/custom    # change if you want todo.txt and friends
                            # to live somewhere else

TODOTXT_DEFAULT_ACTION=ls   # change if you want a different action,
                            # like 'lsp' or 'lsprj'

TODO_SRC_DIR=
$BASH_IT/plugins/available/todo  # for custom installs with plugins
57283d7
@erichs erichs fix bug in fasd init
since we're sourcing this as a plugin, which loads the function, it's
counterproductive to also define the 'fasd' alias

moving the about-plugin metadata into the case block makes this script
safe for execution even if composure metadata isn't exported and
available

rename fasd.bash to fasd.plugin.bash to bring it inline with the other
plugin scripts
65ea1e9
Greg Nofi Fix load_some() installation to handle file paths instead of names.
The ls command in for loop has a pattern now, so full paths are
returned. The user prompt and symbolic link have been updated to handle
this.

Also, not all plugins have '.plugin.' in the middle of their names and
weren't showing up on user prompt. With this commit, everything after
the first period in the file name is stripped.
7632649
@tswicegood tswicegood Merge pull request #135 from nofeet/master
Fix for install.sh for partial installations
5ce8971
@tswicegood tswicegood Merge pull request #132 from Draiken/master
Updating git.completion.bash
776b17c
@tswicegood tswicegood Merge remote-tracking branch 'erichs/fasd_fix' 42a07e9
@tswicegood tswicegood Merge pull request #134 from erichs/plugin_metadata
Plugin management system (big thanks to @erichs)
3bde23a
@tswicegood
Owner

What needs to happen to make this merge cleanly?

@erichs
Owner
erichs added some commits
@erichs erichs conditionally define t()
if user has installed the todo plugin, forego defining the 'one thing'
todo function t().
dd9fb10
@erichs erichs conditionally define t()
if user has enabled the todo plugin, skip defining the 'one thing'
todo function t().
339cfe9
@erichs
Owner

This should apply.

@erichs erichs merged commit e1da40a into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on May 9, 2012
  1. @erichs

    add todo.txt-cli as a plugin

    erichs authored
    Since it is referenced in the default .bash_profile and in aliases and
    themes, why not make it an official plugin?
    
    This creates a 'todo/' directory in /plugins/available, and installs
    todo.sh and friends there.  Tab completion and the 't' alias should work
    out of the box.
    
    Note: it was also necessary to modify .gitignore to ignore the files
    todo.sh generates in custom/.
Commits on May 10, 2012
  1. @Draiken

    updating git.completion.bash

    Draiken authored
Commits on May 11, 2012
  1. @erichs
  2. @erichs

    respect profile overrides

    erichs authored
    overrides may now be specified for any of these defaults:
    TODO_DIR=$BASH_IT/custom    # change if you want todo.txt and friends
                                # to live somewhere else
    
    TODOTXT_DEFAULT_ACTION=ls   # change if you want a different action,
                                # like 'lsp' or 'lsprj'
    
    TODO_SRC_DIR=
    $BASH_IT/plugins/available/todo  # for custom installs with plugins
Commits on May 14, 2012
  1. @erichs

    fix bug in fasd init

    erichs authored
    since we're sourcing this as a plugin, which loads the function, it's
    counterproductive to also define the 'fasd' alias
    
    moving the about-plugin metadata into the case block makes this script
    safe for execution even if composure metadata isn't exported and
    available
    
    rename fasd.bash to fasd.plugin.bash to bring it inline with the other
    plugin scripts
Commits on May 15, 2012
  1. Fix load_some() installation to handle file paths instead of names.

    Greg Nofi authored
    The ls command in for loop has a pattern now, so full paths are
    returned. The user prompt and symbolic link have been updated to handle
    this.
    
    Also, not all plugins have '.plugin.' in the middle of their names and
    weren't showing up on user prompt. With this commit, everything after
    the first period in the file name is stripped.
Commits on May 17, 2012
  1. @tswicegood

    Merge pull request #135 from nofeet/master

    tswicegood authored
    Fix for install.sh for partial installations
  2. @tswicegood

    Merge pull request #132 from Draiken/master

    tswicegood authored
    Updating git.completion.bash
  3. @tswicegood
  4. @tswicegood

    Merge pull request #134 from erichs/plugin_metadata

    tswicegood authored
    Plugin management system (big thanks to @erichs)
Commits on May 18, 2012
  1. @erichs

    conditionally define t()

    erichs authored
    if user has installed the todo plugin, forego defining the 'one thing'
    todo function t().
  2. @erichs

    conditionally define t()

    erichs authored
    if user has enabled the todo plugin, skip defining the 'one thing'
    todo function t().
Something went wrong with that request. Please try again.