Skip to content

Instantly share code, notes, and snippets.

(defun php-lint ()
"Performs a PHP lint-check on the current file."
(interactive)
(require 'compile)
(let* ((compilation-error-regexp-alist '(php))
(compilation-error-regexp-alist-alist ())
(tramp (tramp-tramp-file-p (buffer-file-name)))
(file (or (and tramp
(aref (tramp-dissect-file-name (buffer-file-name)) 3))
(buffer-file-name))))
neutron!ieure:~/Projects/clojure/foo/src$ ./foo.clj
"Hello"
Exception in thread "main" java.io.FileNotFoundException: --./foo.clj (No such file or directory)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.<init>(FileInputStream.java:106)
at java.io.FileInputStream.<init>(FileInputStream.java:66)
at clojure.lang.Compiler.loadFile(Compiler.java:4821)
at clojure.main$load_script__5833.invoke(main.clj:206)
at clojure.main$init_opt__5836.invoke(main.clj:211)
at clojure.main$initialize__5846.invoke(main.clj:239)
#! /usr/bin/env clj
(ns foo)
(prn "Hello")
.EEEEEEEEFEEEFEEEEEE.EEEEEEEEEEE
======================================================================
ERROR: system.test_server.TestMutations.test_batch_insert
----------------------------------------------------------------------
Traceback (most recent call last):
File "/opt/local/lib/python2.5/site-packages/nose/case.py", line 182, in runTest
self.test(*self.arg)
File "/Users/ieure/Projects/cassandra-trunk/test/system/test_server.py", line 126, in test_batch_insert
_verify_batch()
File "/Users/ieure/Projects/cassandra-trunk/test/system/test_server.py", line 45, in _verify_batch
ieure!neutron:~/Projects/Cassandra$ sh -x bin/cassandra -p cassandra.pid
+ '[' x = x ']'
++ dirname bin/cassandra
+ for include in /usr/share/cassandra/cassandra.in.sh /usr/local/share/cassandra/cassandra.in.sh /opt/cassandra/cassandra.in.sh '`dirname $0`/cassandra.in.sh'
+ '[' -r /usr/share/cassandra/cassandra.in.sh ']'
+ for include in /usr/share/cassandra/cassandra.in.sh /usr/local/share/cassandra/cassandra.in.sh /opt/cassandra/cassandra.in.sh '`dirname $0`/cassandra.in.sh'
+ '[' -r /usr/local/share/cassandra/cassandra.in.sh ']'
+ for include in /usr/share/cassandra/cassandra.in.sh /usr/local/share/cassandra/cassandra.in.sh /opt/cassandra/cassandra.in.sh '`dirname $0`/cassandra.in.sh'
+ '[' -r /opt/cassandra/cassandra.in.sh ']'
+ for include in /usr/share/cassandra/cassandra.in.sh /usr/local/share/cassandra/cassandra.in.sh /opt/cassandra/cassandra.in.sh '`dirname $0`/cassandra.in.sh'
ieure!neutron:~/Projects/Cassandra$ nosetests
EEEEEEEEFEFEFEFEFEFEFEFEEFEFEFEFEFEFE
======================================================================
ERROR: system.test_server.TestMutations.test_bad_calls
----------------------------------------------------------------------
Traceback (most recent call last):
File "/opt/local/lib/python2.5/site-packages/nose/case.py", line 366, in tearDown
try_run(self.inst, ('teardown', 'tearDown'))
File "/opt/local/lib/python2.5/site-packages/nose/util.py", line 453, in try_run
return func()
@ieure
ieure / tiling
Created March 17, 2009 16:52
Code to handle centering and tiling of Emacs frames
;; 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."