From dec06d28379085c1b74a5017489f6d5693bc72f9 Mon Sep 17 00:00:00 2001 From: Dan Buch Date: Sat, 18 Jun 2016 16:20:29 -0400 Subject: [PATCH] Dynamically find path of markdown-toc executable --- runtests | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/runtests b/runtests index 85656c7..40c7809 100755 --- a/runtests +++ b/runtests @@ -94,7 +94,8 @@ def _migrations(): @_target def _toc(): - _run(['node_modules/.bin/markdown-toc', '-i', 'README.md']) + npm_bindir = check_output(['npm', 'bin']).strip() + _run(['node', os.path.join(npm_bindir, 'markdown-toc'), '-i', 'README.md']) _run(['git', 'diff', '--quiet'])