Skip to content

Commit 6074e21

Browse files
authored
Merge pull request #275 from Liriel/master
fixed todo buffer number split #274
2 parents 0777f56 + 7db4a84 commit 6074e21

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ftplugin/orgmode/plugins/Todo.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# -*- coding: utf-8 -*-
22

33
import vim
4+
import re
45
import itertools as it
56

67
from orgmode._vim import echom, ORGMODE, apply_count, repeat, realign_tags
@@ -250,7 +251,7 @@ def set_todo_state(cls, state):
250251
def init_org_todo(cls):
251252
u""" Initialize org todo selection window.
252253
"""
253-
bufnr = int(vim.current.buffer.name.split('/')[-1])
254+
bufnr = int(re.findall('\d+$',vim.current.buffer.name)[0])
254255
all_states = ORGTODOSTATES.get(bufnr, None)
255256

256257
vim_commands = [

0 commit comments

Comments
 (0)