This file contains hidden or 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
clojure.lang.PersistentArrayMap cannot be cast to java.lang.String | |
[Thrown class java.lang.ClassCastException] | |
Restarts: | |
0: [QUIT] Quit to the SLIME top level | |
Backtrace: | |
0: com.ashafa.clutch.utils$url.invoke(utils.clj:105) | |
1: com.ashafa.clutch$with_db_STAR_$fn__2316.doInvoke(clutch.clj:57) | |
2: clojure.lang.RestFn.invoke(RestFn.java:436) |
This file contains hidden or 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
import sys | |
def log(s, file_name): | |
with open(file_name, "a") as log_file: | |
log_file.write(s) | |
def LogWriter: | |
def write(self, s): | |
log(s, "path/to/logfile") | |
sys.stdout = sys.stderr = LogWriter() |
This file contains hidden or 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
java.io.IOException: Error writing to server | |
at sun.net.www.protocol.http.HttpURLConnection.writeRequests(HttpURLConnection.java:578) | |
at sun.net.www.protocol.http.HttpURLConnection.writeRequests(HttpURLConnection.java:590) | |
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1193) | |
at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:379) | |
at com.ashafa.clutch.http_client$get_response.invoke(http_client.clj:58) | |
at com.ashafa.clutch.http_client$connect.invoke(http_client.clj:92) | |
at com.ashafa.clutch.http_client$couchdb_request.doInvoke(http_client.clj:116) | |
at clojure.lang.RestFn.invoke(RestFn.java:521) | |
at com.ashafa.clutch$update_attachment.doInvoke(clutch.clj:404) |
This file contains hidden or 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
(ns ssh-tunnel.core | |
(require [clj-ssh.ssh :as ssh])) | |
(defn ssh-tunnel | |
"Run a ssh tunnel in a deamon thread." | |
[session local-port remote-port] | |
(ssh/with-local-port-forward [session local-port remote-port] | |
(.setDaemonThread session true) | |
(ssh/with-connection session | |
(.setServerAliveInterval session 1000) |
This file contains hidden or 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
Hi, | |
Greeting or the day, | |
It’s a Human tendency that we start with a website and leave it like that, If you are not happy with the amount of business that you are getting from your website, we assure you that it won’t be happening any more as soon you start with our SEO Service. | |
There are some special Keywords that are placed in the website which help the website to increase the ranking and increase the traffic on it. | |
Check the desired keyword related to your business on the Google, You won't find your website appearing on the first page of the Search Engine and this is the Point where you lose your business. | |
This file contains hidden or 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
error in process filter: sldb-frame.string: Wrong number of arguments: nil, 0 | |
error in process filter: Wrong number of arguments: nil, 0 | |
Debugger entered--Lisp error: (end-of-file) | |
byte-code("\302\300\"\210\303 \304\"\210\300\305\"\207" [error process debug slime-net-close t "net-read error: %S"] 3) | |
slime-net-read-or-lose(#<process SLIME Lisp>) | |
slime-process-available-input(#<process SLIME Lisp>) | |
slime-net-filter(#<process SLIME Lisp> "ecto, :rel alternate}, :content nil} {:tag :summary, :attrs {:type html}, :content [When making the last lisp program I found it hard to visualise the working days between two dates. I ended up drawing these little sketches on a bit of paper to figure out if my program was doing the ...]} {:tag :category, :attrs {:term lisp}, :content nil} {:tag :category, :attrs {:term project}, :content nil} {:tag :published, :attrs nil, :content [2008-08-25T01:00:00+01:00]}]} {:tag :entry, :attrs nil, :content [{:tag :id, :attrs nil, :content [http://kzar.co.uk/blog/view/generatin |
This file contains hidden or 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
ruby-1.9.2-p0 :001 > a = nil | |
=> nil | |
ruby-1.9.2-p0 :002 > a = (a and nil) | |
=> nil | |
ruby-1.9.2-p0 :003 > a = nil | |
=> nil | |
ruby-1.9.2-p0 :004 > a = (a and 1) | |
=> nil | |
ruby-1.9.2-p0 :005 > a = 1 | |
=> 1 |
This file contains hidden or 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
; Mr Site Password protection | |
; http://www.mrsite.com/videos/Tips_and_tricks_%E2%80%93_putting_a_password_on_your_web_pages/19525203 | |
; | |
; The problem | |
; ----------- | |
; For some reason Mr Site "secures" pages with Javascript client side password protection, | |
; instead of using HTTP basic authentication or with server side code. Anyone can click | |
; "view source" and view the secrets. Worse, the password hash is available so anyone could | |
; figure out the password used. | |
; |
This file contains hidden or 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
:dependencies [[org.clojure/clojure "1.3.0"] | |
[noir "1.2.2"] | |
[com.ashafa/clutch "0.3.0"] | |
[clj-yaml "0.3.1"] | |
[xml-picker-seq "0.0.2"] | |
[xom/xom "1.2.5"] | |
[org.clojure/data.json "0.1.1"] | |
[clj-time "0.3.1"] | |
[clj-http "0.2.3"] | |
[net.cgrand/moustache "1.0.0"] |
This file contains hidden or 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
function test() { | |
return typeof(the_variable) !== 'undefined' && the_variable; | |
} | |
(function () { | |
var the_variable = "doesn't work"; | |
console.log(test()); | |
}()); | |
var the_variable = "does work"; |