todo

Emacs: highlighting TODO *only* in comments

泪湿孤枕 提交于 2019-11-28 06:28:10
This question is related to another one, Emacs :TODO indicator at left side . I recently came across a minor mode I like a lot called FixmeMode . It supports auto highlighting of TODO marks, and navigating between them. However, I think it makes more sense to recognize the "TODO" strings only in comments, rather than polluting the whole file. Is it possible? Trey Jackson Check out the library fic-mode.el , it has been verified in C++ and Emacs-Lisp. It was written specifically to answer this question. The installation is like any standard package: (require 'fic-mode) (add-hook 'c++-mode-hook

Emacs :TODO indicator at left side

我怕爱的太早我们不能终老 提交于 2019-11-27 12:57:58
问题 I want to have sort of indiacator at left side of the line wherever I have in the source code #TODO : some comment //TODO: some comments The indicator could be a just mark and I already enabled line numbers displayed at emacs. 回答1: This command will do something like you want. (defun annotate-todo () "put fringe marker on TODO: lines in the curent buffer" (interactive) (save-excursion (goto-char (point-min)) (while (re-search-forward "TODO:" nil t) (let ((overlay (make-overlay (- (point) 5)

How to disable git push when there are TODOs in code?

我与影子孤独终老i 提交于 2019-11-27 05:56:53
问题 We are having an issue in our team and we have decided to check if there is a way or git command to reject git push where there are TODOs in the code. Any ideas? Thanks in advance. 回答1: Is not possible use pre-receive hooks in github, so we are using instead pre-commit hook in client side: http://git-scm.com/book/en/Customizing-Git-Git-Hooks#Client-Side-Hooks Our pre-commit script (based on http://mark-story.com/posts/view/using-git-commit-hooks-to-prevent-stupid-mistakes) looks like: #!/bin

Emacs: highlighting TODO *only* in comments

南楼画角 提交于 2019-11-27 01:22:22
问题 This question is related to another one, Emacs :TODO indicator at left side. I recently came across a minor mode I like a lot called FixmeMode. It supports auto highlighting of TODO marks, and navigating between them. However, I think it makes more sense to recognize the "TODO" strings only in comments, rather than polluting the whole file. Is it possible? 回答1: Check out the library fic-mode.el, it has been verified in C++ and Emacs-Lisp. It was written specifically to answer this question.