This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun snapshot (in) | |
(interactive "DChoose directory to snapshot: ") | |
;; (let (( default-directory))) | |
(let* ((in (directory-file-name in)) | |
(base (file-name-directory in)) | |
(default-directory base) | |
(timestamp (format-time-string "%y%m%d-%H%M" (current-time))) | |
(out (expand-file-name | |
(format ".snapshot/%s-%s" | |
timestamp (file-name-nondirectory in)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#+TITLE: Emacs.org | |
#+INCLUDE: emacs_journal.org :minlevel 1 | |
# --------------------------------------------------------------- | |
#+TITLE: Emacs Journal.org | |
#+ARCHIVE: emacs.org:: | |
# 이제 emacs_journal.org에서 org-archive를 실행하면, emacs.org_archive |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;;;; erc4klisper.el starts here | |
;;; Usage: | |
;;; 1. append this code to ~/.emacs | |
;;; 2. locate this file to your custom `load-path', | |
;;; and adding to ~/.emacs | |
;;; | |
;;; (require 'erc4klisper) | |
;;; | |
;;; or | |
;;; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
This software is Copyright (c) 2010 | |
Michael Wild. All rights reserved. | |
Redistribution and use in source and binary forms, with or without | |
modification, are permitted provided that the following conditions | |
are met: | |
- Redistributions of source code must retain the above copyright | |
notice, this list of conditions and the following disclaimer. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(let* ((config-dir user-emacs-directory) | |
(config-file (expand-file-name ".config" config-dir))) | |
(defmacro with-el-config (&rest body) | |
`(let* ((__parsed-data__ ',(cdr (with-temp-buffer | |
(insert-file-contents-literally config-file) | |
(search-forward "load-with-config" nil t) | |
(end-of-defun) | |
(preceding-sexp)))) | |
(__load-file-name__ load-file-name) | |
(__id__ ',(intern (file-relative-name |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun winnum-select (&optional num) | |
"Selects the nth window." | |
(interactive (list (let (_) | |
(while (or (not (characterp _)) | |
(<= _ 48) ; 0 not included | |
(and (> _ 57) (< _ 97)) | |
(> _ 122)) | |
(setq _ (read-event | |
#("Switch to Winnum: " 0 18 | |
(face minibuffer-prompt))))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;;;; usage -*- lexical-binding: t; -*- | |
;;; download this gist file, `winnum.el' and place it on one of your `load-path'. | |
;;; now, M-x byte-compile-file winnum.el RET and then M-x load-library winnum RET. | |
;;; f8 or super-o keybinding do all the fun! | |
;;; winnum id is on a mode-line. | |
;;; | |
;;; | |
;;; -UUU:**-1-F1 *scratch* All (1,0) (Fundamental yas) --------------- | |
;;; ^ | |
;;; +---this! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(setq xcycle '#1=(("p1" . "t1") ("p2" . "t2") . #1#)) | |
(cadr (member (assoc-string "p2" xcycle) xcycle)) | |
(setq xcycle '#1=("p1" "t1" "p2" "t2" . #1#)) | |
(cddr (member "p2" xcycle)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun rcirc-format-response-string (process sender response target text) | |
"Return a nicely-formatted response string, incorporating TEXT | |
\(and perhaps other arguments). The specific formatting used | |
is found by looking up RESPONSE in `rcirc-response-formats'." | |
(with-temp-buffer | |
(insert (or (cdr (assoc response rcirc-response-formats)) | |
(cdr (assq t rcirc-response-formats)))) | |
(goto-char (point-min)) | |
(let ((start (point-min)) | |
(sender (if (or (not sender) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defvar frame-bar-pixel-num (cc-eval-when-compile | |
(case window-system ((ns) 23)))) | |
(defvar desktop-taskbar-pixel-num (cc-eval-when-compile | |
(case window-system ((ns) 22)))) | |
(defun mkfparams (direction rframe &optional move) | |
(let ((horizontalp (memq direction '(left right))) | |
(fp/left (frame-parameter rframe 'left)) | |
(fp/top (frame-parameter rframe 'top)) |
OlderNewer