org-clock-csv icon indicating copy to clipboard operation
org-clock-csv copied to clipboard

org-clock-csv--escape should be "public"

Open sshaw opened this issue 6 years ago • 5 comments

Since this can be called in a user-defined format function is should use the "public" convention, e.g. one less "-": org-clock-csv-escape.

If backwards compatibility is a concern you can do something like:

(defun org-clock-csv--escape (str)
  (warn "org-clock-csv--escape is deprecated and will be removed in version X. Use org-clock-csv-escape instead") 
  (org-clock-csv-escape str))

sshaw avatar Jun 01 '19 18:06 sshaw

Actually, I think emacs has some properties that it uses for deprecation... 🤔

sshaw avatar Jun 01 '19 18:06 sshaw

Can you clarify what user-defined functions would need to call it?

atheriel avatar Jun 03 '19 18:06 atheriel

Can you clarify what user-defined functions would need to call it?

Anything one sets org-clock-csv-row-fmt to.

sshaw avatar Jun 03 '19 19:06 sshaw

@atheriel how to customize org-clock-csv-row-fmt without access to org-clock-csv--escape ? Can you please give an example of custom row format ?

ghost avatar Apr 22 '20 17:04 ghost

I ran into this same issue today. I ended up just forking the project and modifying org-clock-csv-default-row-fmt in place just to be able to use org-clock-csv--escape (https://github.com/riceissa/org-clock-csv/commit/638354428524619ae16df106935423150cf42e22), which doesn't seem ideal. What I would like instead is to be able to just define a custom org-clock-csv-row-fmt in my init.el or something.

riceissa avatar Nov 13 '23 08:11 riceissa