Skip to main content
31 votes
Accepted

org-mode: how to generate clock report for hours worked each day?

I think you might consider this to be a partial solution to your question. If you include :step day in your clocktable line then you'll get several clock tables emitted -- one per day for the current ...
Stuart Hickinbottom's user avatar
10 votes

org-mode: how to generate clock report for hours worked each day?

The closest thing I can come out of this was writing your own custom dynamic block. You can read more about it at C-h i g (org)Dynamic blocks. This, however, requires you to know more about Org-mode ...
Lei Zhao's user avatar
  • 421
8 votes
Accepted

Function of org-clock-save.el file and Git related question

The file org-save-clock.el is used to store two kinds of information: the active clock if emacs is shut down while a task is active (gets stored in org-clock-stored-resume-clock) the history of the n ...
dfeich's user avatar
  • 1,914
7 votes

How to conveniently insert a clock entry?

I need to do what you describe quite often. My goal is to do everything from the agenda view, i.e. having to go to the org source files as few as possible. In order to insert a colck interval for a ...
dfeich's user avatar
  • 1,914
5 votes
Accepted

Rounding time up to multiple of x in when using org-clock

I had to do something similar at work and I solved it by calling the clocktable with a (calc) formula: #+BEGIN: clocktable :maxlevel 3 :block 2017-10-24 :formula "$2=$3;t::$3=if($2 == 0, string(\"\"),...
Fabian's user avatar
  • 196
5 votes
Accepted

How to conveniently insert a clock entry?

I wanted to do this again recently and I just hacked together a simple function which asks for the beginning and the end of the desired clock entry (defun jx/insert-custom-clock-entry () (...
xji's user avatar
  • 2,665
5 votes
Accepted

Time tracking and reporting with cross-cutting concerns in org-mode

This is straightforward by using the :tags option in clocktable lines, and I use this to do something similar to you. I have a separate org file (clock.org in my case), which just contains clock ...
Stuart Hickinbottom's user avatar
4 votes
Accepted

How to get an audible feedback when the current task is overrun?

As Tyler's answer suggests, org-clock-sound will help org to make an audible feedback for this scenario. However, it is highly probable that lost in the init file there is this line of code ...
asiegf's user avatar
  • 175
4 votes

Save an org-mode buffer when I clock in/out of a task

org-clock-in and org-clock-out have "hooks" associated with them --- lists of extra functions that run whenever you clock in/out. You can add your own functions (which will be called with no arugment)...
erikstokes's user avatar
3 votes
Accepted

Save an org-mode buffer when I clock in/out of a task

Emacs has cool feature - defadvice. You can surround any function with your own operation. In this case, something along the lines of (add-hook 'org-mode-hook (lambda () (...
Konstantin Levinski's user avatar
3 votes
Accepted

Reminds to clock out or just clock out when there has a clock running

I use the following in my init file to solve exactly this problem. I probably cribbed this from somewhere myself but it's been so long I can't remember the source. (defun my/org-clock-query-out () "...
Stuart Hickinbottom's user avatar
3 votes
Accepted

How to write a complex function for binding on a global hotkey?

You should probably look at the documentation of orgmode agenda views before coding your own todo list. There is already a global TODO list available. See also the variable org-agenda-files. ...
Tobias's user avatar
  • 33.5k
3 votes
Accepted

How to create table of time distribution by tags in Org Mode?

Based on this Gist: https://gist.github.com/tsu-nera/d9ffa6a51a6e7bdb957b Add it to init.el: (require 'org-table) (require 'org-clock) (defun clocktable-by-tag/shift-cell (n) (let ((str "")) (...
Valeriy's user avatar
  • 387
3 votes

How to get an audible feedback when the current task is overrun?

The function org-clock-notify-once-if-expired appears to play a sound, if you have a sound configured in the variable org-clock-sound. That would give you a single audible notification after you first ...
Tyler's user avatar
  • 22.5k
3 votes

persistent org-mode clock-in history

Org-Mode also includes this feature by default. You can set org-clock-persist to 'history to save the clock entry history when closing emacs. Or set it to t to also save the running clock when Emacs ...
fpiper's user avatar
  • 491
3 votes

Org-clock-report sort by time

#+BEGIN: clocktable :scope subtree :maxlevel 2 :sort (3 . ?n) #+END: you can set the sort column and sort by number.
carlos's user avatar
  • 161
3 votes

How can i prevent current clocked task from showing in modeline?

You can set the variable org-clock-clocked-in-display. The docstring reads: Documentation: When clocked in for a task, Org can display the current task and accumulated time in the mode line and/or ...
skrytebane's user avatar
3 votes
Accepted

Automatically clock in when I switch task mode to "in progress"

Figured it out. Much simpler than the linked solution. (add-hook 'org-after-todo-state-change-hook 'org-clock-todo-change) (defun org-clock-todo-change () (if (string= ...
ChasingUG's user avatar
3 votes
Accepted

Is there a way to show the sum of org-clock sprints in a marked region?

Try the following: #+begin_src elisp (defun ndk/org-clock-sum-current-region (beg end) (interactive "r") (let ((s (buffer-substring-no-properties beg end))) (with-temp-...
NickD's user avatar
  • 32.3k
3 votes
Accepted

How Do I Calculate the File Time for a Given Week Number?

I did it! Close enough at least. First, install this function: (defun my/org-clock-sum-week (iso-week) (let* ((r (org-clock-special-range iso-week)) (start (car r)) (end (cadr r))) ...
Wildebeest's user avatar
2 votes
Accepted

Org-clock-report sort by time

You can define your own :formatter for clocktables. Such a formatter can sort the table data to your likings and delegate further formatting to the formatter determined by org-clock-clocktable-...
Tobias's user avatar
  • 33.5k
2 votes
Accepted

How to clock-out current org-task before exit from Emacs?

Solution: (setq org-main-file "~/orgmode/main.org") (defun valeriy/exit () (with-current-buffer (find-file-noselect org-main-file) (save-excursion (org-clock-out nil t) ...
Valeriy's user avatar
  • 387
2 votes

org-mode Modeline total for 'today' 'incorrect'?

Update: This seems to have been a bug which was fixed in a newer git commit. https://code.orgmode.org/bzg/org-mode/commit/0790855c93533ce988f5b28839fdf0eca7521ad3 After some investigation, it appears ...
jorobins's user avatar
2 votes
Accepted

Count down timer whenever file is opened

Have you tried adding the function to org-mode-hook? If you haven't tried it yet, what I would recommend is to create a function my-org-mode-hook-function which evaluates (org-timer-set-timer 10). ...
user1404316's user avatar
2 votes

Org: including clock-out timestamp in clock table report

I am not quite sure what exactly you want: (a) the date the task was completed or (b) the last clock-out date. These are not necessarily the same. I have no solution for (b), but can provide one for (...
Fabian's user avatar
  • 196
2 votes
Accepted

Before first headline at position XX in buffer - Unable to update org-clock-table

You can only use the subtree scope if you're in a headline. Out of a headline you could use :scope file or file-with-archives.
dakra's user avatar
  • 406
2 votes

How to change to evil-insert mode when there is no hook?

Alternate answer, since you also asked a more general question. In general you can add a function call after another function by using advice, specifically :after advice. But it's worth noting what ...
purple_arrows's user avatar
2 votes
Accepted

How do I automatically clock-in for SCHEDULED items with org-capture?

If you just want to have these meetings reflected in your clock data afterwards for reporting purposes, I don't think you need to actually clock in and out? You can just add the clock data directly: ...
glucas's user avatar
  • 20.8k
2 votes
Accepted

How to show remaining task effort in org-mode's column view

You would have to use the following specifier %(expression) from the documentation of org-agenda-prefix-format. the expression would calculate the difference between the clocksum and the effort ...
heiwiper's user avatar
2 votes
Accepted

Find clocking errors in org-mode entries: list/edit all clock entries with duration until next day(s)

Use elgrep which is available on Melpa. After a successful install, call M-x elgrep-menu or you click on the menu entry Tools → Elgrep. There are two features that make elgrep especially suited for ...
Tobias's user avatar
  • 33.5k

Only top scored, non community-wiki answers of a minimum length are eligible