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
/* paste into http://script.google.com | |
run periodically (e.g. every 5 minutes) with a timer by selecting 'Resources' > 'current project's triggers...' | |
*/ | |
function filterLongEmails() { | |
var num_messages = 1; // will be applied to the last n messages. Google allows up to 500 | |
var word_limit = 50; | |
var subj = "Shorter emails will get read."; | |
var body = "Dear friends, I value my time and yours but I appreciate it if you can keep your emails under " + word_limit + " words. Please edit and resend."; | |
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
13:37:04,259 WARN [com.arjuna.ats.jta] (Periodic Recovery) ARJUNA016037: Could not find new XAResource to use for recovering non-serializable XAResource XAResourceRecord < resource:null, txid:< formatId=131077, gtrid_length=29, bqual_length=36, tx_uid=0:ffffa9fe14ca:-313a12eb:5123cf12:16e, node_name=1, branch_uid=0:ffffa9fe14ca:-313a12eb:5123cf12:16f, subordinatenodename=null, eis_name=unknown eis name >, heuristic: TwoPhaseOutcome.FINISH_OK com.arjuna.ats.internal.jta.resources.arjunacore.XAResourceRecord@1a75463 > | |
13:37:04,260 WARN [com.arjuna.ats.jta] (Periodic Recovery) ARJUNA016038: No XAResource to recover < formatId=131077, gtrid_length=29, bqual_length=36, tx_uid=0:ffffa9fe14ca:-313a12eb:5123cf12:16e, node_name=1, branch_uid=0:ffffa9fe14ca:-313a12eb:5123cf12:16f, subordinatenodename=null, eis_name=unknown eis 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
16:00:11,697 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-6) MSC00001: Failed to start service jboss.deployment.unit."drano.clj".INSTALL: org.jboss.msc.service.StartException in service jboss.deployment.unit."drano.clj".INSTALL: JBAS018733: Failed to process phase INSTALL of deployment "drano.clj" | |
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:123) [jboss-as-server-7.1.x.incremental.129.jar:7.1.x.incremental.129] | |
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA] | |
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA] | |
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [classes.jar:1.6.0_37] | |
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [classes.jar:1.6.0_37] | |
at java.lang.Thread.run(Thread.java:680) [classes.jar:1 |
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
clobal=> (defprotocol IFoo (foo [this])) | |
IFoo | |
clobal=> (defrecord MyClass [state] (foo [this] (swap! state assoc :foo :called))) | |
ClassCastException clojure.lang.PersistentList cannot be cast to clojure.lang.Symbol clojure.core/ns-resolve (core.clj:3944) | |
clobal=> (defrecord MyClass [state] IFoo (foo [this] (swap! state assoc :foo :called))) | |
clobal.MyClass | |
clobal=> (def ob (MyClass. (atom {}))) | |
#'clobal/ob | |
clobal=> @(.state ob) |
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
#!/usr/bin/env python | |
import socket; | |
s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM); | |
s.setsockopt(socket.SOL_SOCKET, socket.SO_BROADCAST, 1); | |
s.sendto('\xff'*6+'\x00\x13\xd4\x37\x02\xdb'*16, ('10.0.0.255', 80)); |
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
; simple darkroom with fullscreen, | |
; fringe, mode-line, menu-bar and scroll-bar hiding. | |
(defvar darkroom-enabled nil) | |
(defun toggle-darkroom () | |
(interactive) | |
(if (not darkroom-enabled) | |
(setq darkroom-enabled t) | |
(setq darkroom-enabled nil)) | |
; (hide-mode-line) |
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 is the default .slate file. | |
# If no ~/.slate file exists this is the file that will be used. | |
config defaultToCurrentScreen true | |
config nudgePercentOf screenSize | |
config resizePercentOf screenSize | |
# Resize Bindings | |
# bind right:alt resize +10% +0 | |
# bind left:alt resize -10% +0 |
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
18:24:47,492 WARNING [org.hornetq.core.protocol.core.impl.RemotingConnectionImpl] (Thread-2 (group:HornetQ-client-global-threads-1123639765)) Connection failure has been detected: The connection was disconnected because of server shutdown [code=4] |
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
(def queue-name (immutant.messaging/as-queue "SomeQueue")) | |
(defn init [] | |
(messaging/listen queue-name msg-dispatch :host "remote-broker" :port 12345 :decode? false)) |
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
➜ myapp git:(master) ✗ lein immutant run | |
Starting Immutant: /Users/robertb/.lein/immutant/current/jboss/bin/standalone.sh | |
========================================================================= | |
JBoss Bootstrap Environment | |
JBOSS_HOME: /Users/robertb/.lein/immutant/current/jboss | |
JAVA: java |