Skip to content

Instantly share code, notes, and snippets.

@fspeech
fspeech / hs-cycle.el
Created July 16, 2013 01:06
With a single command (hs-cycle) we can cycle through different levels of code folding in Emacs hs-minor-mode. hs-minor-mode of Emacs deserves more recognition as it is great for navigating large code files or code blocks, though it suffers from an awkward keymap (using C-c @ as prefix) in the version that comes bundled with Emacs. Inspired by o…
;; I bind my command to C-<tab>
;; (define-key hs-minor-mode-map (kbd "C-<tab>") 'hs-cycle)
(defun hs-cycle (&optional arg)
"Visibility cycling for hs-minor-mode, inspired by outline-cycle from
outline-magic.el (https://github.com/tj64/outline-magic).
When repeatedly called we cycle through three states:
1. HIDE: Show only headlines in the current context.
2. OVERVIEW: Expand one level below HIDE to show more details.
3. SHOW: Show everything in the current context."
select repository_name, count(repository_name) as pushes, repository_description, repository_url
from [githubarchive:github.timeline]
where type="PushEvent"
and repository_language="Emacs Lisp"
and parse_utc_usec(created_at) >= parse_utc_usec('2014-01-01 00:00:00')
group by repository_name, repository_description, repository_url
order by pushes desc
limit 100