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
(require 'package) | |
(add-to-list 'package-archives | |
'("marmalade" . "http://marmalade-repo.org/packages/") t) | |
(package-initialize) | |
;; use Mac command key for meta | |
(setq mac-command-modifier 'meta) | |
;; recursively add emacs dir to load-path | |
(let ((default-directory "~/.emacs.d/")) | |
(normal-top-level-add-subdirs-to-load-path)) |
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
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Ant sim ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | |
; Copyright (c) Rich Hickey. All rights reserved. | |
; The use and distribution terms for this software are covered by the | |
; Common Public License 1.0 (http://opensource.org/licenses/cpl.php) | |
; which can be found in the file CPL.TXT at the root of this distribution. | |
; By using this software in any fashion, you are agreeing to be bound by | |
; the terms of this license. | |
; You must not remove this notice, or any other, from this software. | |
;dimensions of square world |
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
;; SLIME | |
(add-to-list 'load-path "~/.emacs.d/slime") | |
(load "slime.el") | |
(eval-after-load "slime" | |
'(progn (slime-setup '(slime-repl)))) | |
(eval-after-load 'slime '(setq slime-protocol-version 'ignore)) | |
(require 'slime) | |
(slime-setup '(slime-scratch slime-editing-commands)) | |
(setq inferior-lisp-program "sbcl") ; replace with your Common Lisp implementation |
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
(ns three.demo) | |
(def camera (THREE.Camera. 75 (/ window/innerWidth | |
window/innerHeight) 1 10000)) | |
(set! (.z (.position camera)) 1000) | |
(def scene (THREE.Scene.)) | |
(def geometry (THREE.CubeGeometry. 200 200 200)) | |
(def obj (js/Object.)) | |
(set! (.color obj) 0xff0000) | |
(set! (.wireframe obj) true) | |
(def material (THREE.MeshBasicMaterial. obj)) |
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
<html> | |
<head></head> | |
<body> | |
<script type="text/javascript" src="Three.js"></script> | |
<script type="text/javascript" src="RequestAnimationFrame.js"></script> | |
<script type="text/javascript" src="output.js"></script> | |
</body> | |
</html> |
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
public class Foo { | |
final int bar = 6; | |
final int[] flarp = new int[] {6}; | |
public class Baz { | |
int bla() { | |
return bar; | |
} | |
int bloo() { |
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
require 'RMagick' | |
import Magick | |
if(ARGV.length < 2) | |
puts "call with image filename and gcode filename" | |
exit(1) | |
end | |
XSTEP = 5 | |
YSTEP = 5 |
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
;; set two global variables | |
(setq x 'global-x) | |
(setq y 'global-y) | |
;; define a function that returns a nested function | |
(defun return-a-nested-fn (x) | |
;; the nested function takes no arguments and returns a list of two values | |
(lambda () (list x y))) | |
;; call that function, and call the function returned |
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
<?xml version="1.0"?> | |
<threadpolicy version="1.0"> | |
<class name="android.app.Activity"> | |
<policy type="ThreadConfined" threadname="ThreadName.MAIN"> | |
<method pattern="on.*" /> | |
</policy> | |
</class> | |
<class pattern="android.*View"> | |
<policy type="ThreadConfined" threadname="ThreadName.MAIN"> | |
<method pattern=".*" /> |
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
package com.flurry.example.hnreader; | |
import java.io.IOException; | |
import java.util.List; | |
import android.app.Activity; | |
import android.os.Bundle; | |
import android.widget.LinearLayout; | |
import android.widget.TextView; |
OlderNewer