Skip to content

Instantly share code, notes, and snippets.

Ian Eure ieure

Block or report user

Report or block ieure

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@ieure
ieure / tiling
Created Mar 17, 2009
Code to handle centering and tiling of Emacs frames
View tiling
;; Functions to work with frames
(provide 'ime-frame)
(defun screen-usable-height (&optional display)
"Return the usable height of the display.
Some window-systems have portions of the screen which Emacs
cannot address. This function should return the height of the
screen, minus anything which is not usable."
@ieure
ieure / error_debug.py
Created Sep 25, 2009
Context manager to enter the Python debugger when an exception is raised
View error_debug.py
# -*- coding: utf-8 -*-
#
# Author: Ian Eure <http://github.com/ieure>, <http://atomized.org>
#
"""Enter the debugger on exceptions.
example:
from __future__ import with_statement
View wtd.el
(defun window-toggle-dedicated (&optional window)
"Toggle the dedicated flag on a window."
(interactive)
(let* ((window (or window (selected-window)))
(dedicated (not (window-dedicated-p window))))
(when (called-interactively-p)
(message (format "%s %sdedicated"
(buffer-name (window-buffer window))
(if dedicated "" "un"))))
(set-window-dedicated-p window dedicated)
View gist:25b521078bd1f34974489ff02498c93c
beep for Debian
---------------
The code is quite short so it should be clear that it's not exploitable.
I therefore think that "suid root with only group audio executeable" is an
acceptable default - you are of course able to change it anytime with
dpkg-reconfigure beep
@ieure
ieure / python-pep8.el
Created Feb 12, 2010
Run pep8.py on Python source in Emacs.
View python-pep8.el
;;; python-pep8.el --- minor mode for running `pep8'
;; Copyright (c) 2009, 2010 Ian Eure <ian.eure@gmail.com>
;; Author: Ian Eure <ian.eure@gmail.com>
;; Keywords: languages python
;; Last edit: 2010-02-12
;; Version: 1.01
@ieure
ieure / python-pylint.el
Created Feb 12, 2010
Run pylint on Python source in Emacs.
View python-pylint.el
;;; python-pylint.el --- minor mode for running `pylint'
;; Copyright (c) 2009, 2010 Ian Eure <ian.eure@gmail.com>
;; Author: Ian Eure <ian.eure@gmail.com>
;; Keywords: languages python
;; Last edit: 2010-02-12
;; Version: 1.01
View gist:35ae502cdbe385b230c61d5e94a0d389
Show: Clojure Java REPL Tooling Duplicates All (0 frames hidden)
1. Unhandled java.lang.ClassNotFoundException
cemerick.piggieback
URLClassLoader.java: 381 java.net.URLClassLoader/findClass
DynamicClassLoader.java: 69 clojure.lang.DynamicClassLoader/findClass
ClassLoader.java: 424 java.lang.ClassLoader/loadClass
DynamicClassLoader.java: 77 clojure.lang.DynamicClassLoader/loadClass
View home-rue
proton!ieure:~$ brew update
/usr/local/Library/Homebrew/cmd/update.sh: line 13: /usr/local/Library/ENV/scm/git: No such file or directory
/usr/local/Library/Homebrew/cmd/update.sh: line 13: /usr/local/Library/ENV/scm/git: No such file or directory
/usr/local/Library/Homebrew/cmd/update.sh: line 13: /usr/local/Library/ENV/scm/git: No such file or directory
/usr/local/Library/Homebrew/cmd/update.sh: line 13: /usr/local/Library/ENV/scm/git: No such file or directory
/usr/local/Library/Homebrew/cmd/update.sh: line 13: /usr/local/Library/ENV/scm/git: No such file or directory
/usr/local/Library/Homebrew/cmd/update.sh: line 13: /usr/local/Library/ENV/scm/git: No such file or directory
/usr/local/Library/Homebrew/cmd/update.sh: line 13: /usr/local/Library/ENV/scm/git: No such file or directory
/usr/local/Library/Homebrew/cmd/update.sh: line 13: /usr/local/Library/ENV/scm/git: No such file or directory
/usr/local/Library/Homebrew/cmd/update.sh: line 13: /usr/local/Library/ENV/scm/git: No such file or directory
View gist:6cea2741c172cb4fd395
View gist:7777474
fermion!ieure:~$ brew update
error: The following untracked working tree files would be overwritten by merge:
Library/Formula/ant.rb
Library/Formula/apple-gcc42.rb
Please move or remove them before you can merge.
Aborting
Error: Failure while executing: git pull -q origin refs/heads/master:refs/remotes/origin/master
fermion!ieure:~$ cd /usr/local/
fermion!ieure:/usr/local$ git status
# On branch master
You can’t perform that action at this time.