1
0
Fork 0

Add tako workon plugin

This commit is contained in:
Jeremy Kaplan 2017-10-23 16:20:21 -07:00 committed by Jeremy Kaplan
commit e5a3fd3b82
4 changed files with 4 additions and 20 deletions

2
.gitmodules vendored
View file

@ -33,4 +33,4 @@
url = https://github.com/glts/vim-textobj-comment.git
[submodule "tako/plugins"]
path = tako/plugins
url = git@gitlab.com:adqm/tako-plugins.git
url = git@gitlab.com:jdkaplan/tako-plugins.git

View file

@ -16,7 +16,6 @@ source_many($HOME + '/.config/tako/completers', is_tako)
$TAKO_SETTINGS.auto_pushd = True
$WORKON_HOME = $HOME + '/.virtualenvs'
$XDG_CONFIG_HOME = $HOME + '/.config'
$EDITOR = 'emacs'
$VISUAL = $EDITOR
@ -30,22 +29,6 @@ for path in [
$LS_COLORS = $(dircolors @($HOME + '/.config/zsh/dircolors.256dark'))[len("LS_COLORS='"):-len("';\nexport LS_COLORS")]
def _workon(args, stdin=None):
if len(args) < 1:
return 'Need name of virtualenv\n'
source_order = [
'preactivate',
'activate',
'postactivate',
]
for f in filter(os.path.isfile, [
os.path.join($WORKON_HOME, args[0], 'bin', '{}.tako'.format(name))
for name in source_order
]):
source @(f)
def _sympy(args, stdin=None):
source @($HOME + '/.config/tako/sympy.tako')
@ -66,7 +49,6 @@ $TAKO_SETTINGS.aliases.update({
'units': 'units --verbose',
'trr': 'transmission-remote',
'vol': 'pulseaudio-ctl set',
'workon': _workon,
'octave': 'octave-cli',
'bc': 'bc -l',
'sympy': _sympy,

@ -1 +1 @@
Subproject commit a584be73f8c40d7137eb0a1bfd5b59b4370462c2
Subproject commit fce6d9e0072293802bb514acdabc2756013c7e2a

View file

@ -77,3 +77,5 @@ eval $(dircolors $HOME/.config/zsh/dircolors.256dark)
autoload -U select-word-style
select-word-style bash
eval "$(direnv hook zsh)"