project-tasks
project-tasks copied to clipboard
Efficient task management for your project.
** project-tasks.el - Efficient task management for your projects [[https://melpa.org/#/project-tasks][file:https://melpa.org/packages//project-tasks-badge.svg]] [[http://www.gnu.org/licenses/gpl-3.0.html][http://img.shields.io/:license-gpl3-blue.svg]] ** Concept
Formed during work on projects, I need to:
- run docker-compose up
- access the database shell of the db service in docker-compose
- run mitmproxy
- run a new shell
Using org-babel of org-mode is a great solution (~Literate Devops with Org-Mode~).
Therefore, this package provides a convenient interface for accessing those tasks instead of accessing org-mode files and executing org-babel code blocks.
*** Features
- M-x ~project-tasks~
#+begin_src markdown
Find-file all files in
project-tasks-files
-> get all src-blocks by(org-babel-src-block-names)
-> display src-blocks to user -> user select and run(org-babel-execute-src-block)
#+end_src
** Usage
#+begin_src elisp (use-package project-tasks :ensure t :defer t
:commands (project-tasks)
:init ;; Show project-tasks when switching projects (add-to-list 'project-switch-commands '(project-tasks "tasks") t) ;; Add action to embark-file map (with-eval-after-load 'embark (define-key embark-file-map (kbd "P") #'project-tasks-in-dir))
:custom ;; Set the list of tasks files (project-tasks-files '("tasks.org"))
;; Set the ignore files ;; (project-tasks-ignore-files '("README.org"))
;; Set the function to get current project dir ;; (project-tasks-root-func #'project-tasks-project-root)
;; Set the separator between file name and task name ;; (project-tasks-separator " -> ") :config (add-to-list 'marginalia-prompt-categories '("select task" . project-task)) (defvar-keymap embark-project-task-actions :doc "Keymap for actions for project-task (when mentioned by name)." :parent embark-general-map "j" #'project-tasks-goto-task) (add-to-list 'embark-keymap-alist '(project-task . embark-project-task-actions)) ;; Bind project-tasks to project keymap :bind (:map project-prefix-map ("P" . project-tasks)) )
#+end_src
*** Notice You need to ensure that your code blocks work as intended. This package serves as an interface for interacting with Org files but does not affect your Org configuration.
** Examples Declare some tasks in ~tasks.org~ as below: #+begin_src org
- Tasks ,#+name: makemigrations ,#+begin_src compile :name makemigrations django-admin makemigrations ,#+end_src
,#+name: browser ,#+begin_src compile :name browser chromium --temp-profile http://localhost:8080 ,#+end_src #+end_src
When you call ~M-x project-tasks~, it will display tasks that you want to choose to run
[[https://txgvnn.github.io/images/project-tasks.png]]
You can check more examples in ~tasks.org~ file in this repository.