Extract the second level headline

六眼飞鱼酱① 提交于 2019-12-06 08:08:24

All you have to do to get the second element of (org-get-outline-path) is to call nth.

(nth N LIST)

Return the Nth element of LIST. N counts from zero. If LIST is not that long, nil is returned.

The second element is (nth 1 LIST). Replace (org-get-outline-path) with (list (nth 1 (org-get-outline-path))) (we use list because that's what org-format-outline-path expects).

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!