Skip to content

Instantly share code, notes, and snippets.

(defproject profiletest "0.1.0-SNAPSHOT"
:description "FIXME: write description"
:url "http://example.com/FIXME"
:license {:name "Eclipse Public License"
:url "http://www.eclipse.org/legal/epl-v10.html"}
:dependencies [[org.clojure/clojure "1.5.1"]]
:main profiletest.core
:profiles {
:dev {:source-paths ["src" "src.dev"]}
:prod {:source-paths ["src" "src.prod"]}
@miguelbermudez
miguelbermudez / memo.md
Last active August 29, 2015 14:18 — forked from yokolet/memo.md
datomic % uri="datomic:sql://heh?jdbc:postgresql://localhost:5432/heh?user=myPSQLUser&password=myPSQLPassword";
<datomic:sql://heh?jdbc:postgresql://localhost:5432/heh?user=myPSQLUser&password=myPSQLPassword>
datomic % Peer.createDatabase(uri);
<true>
datomic % conn = Peer.connect(uri);
<{:db-id "heh-5193d8ad-0ec4-4fcc-b995-0915581bb2e0", :unsent-updates-queue 0, :pending-txes 0, :next-t 1000, :basis-t 62, :index-rev 0, :index-root {:rev 0, :key "5193d921-b783-47c2-a9cf-7e555747b8cd"}, :log-root {:rev 0, :key "5193d921-17a1-4a03-9717-f10a869812cb"}}>
datomic % datom = Util.list("db/add",
Peer.tempid("db.part/user"),
"db/doc",
"hello world");
@miguelbermudez
miguelbermudez / atom_clojure_setup.md
Created April 4, 2016 03:29 — forked from jasongilman/atom_clojure_setup.md
This describes how I setup Atom for Clojure Development.

Atom Clojure Setup

This describes how I setup Atom for an ideal Clojure development workflow. This fixes indentation on newlines, handles parentheses, etc. The keybinding settings for enter (in keymap.cson) are important to get proper newlines with indentation at the right level. There are other helpers in init.coffee and keymap.cson that are useful for cutting, copying, pasting, deleting, and indenting Lisp expressions.

Install Atom

Download Atom

The Atom documentation is excellent. It's highly worth reading the flight manual.

@miguelbermudez
miguelbermudez / GIF-Screencast-OSX.md
Created June 17, 2016 16:59 — forked from dergachev/GIF-Screencast-OSX.md
OS X Screencast to animated GIF

OS X Screencast to animated GIF

This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

Instructions

To capture the video (filesize: 19MB), using the free "QuickTime Player" application:

@miguelbermudez
miguelbermudez / app.js
Created September 15, 2016 15:42 — forked from acdlite/app.js
Quick and dirty code splitting with React Router v4
// getComponent is a function that returns a promise for a component
// It will not be called until the first mount
function asyncComponent(getComponent) {
return class AsyncComponent extends React.Component {
static Component = null;
state = { Component: AsyncComponent.Component };
componentWillMount() {
if (!this.state.Component) {
getComponent().then(Component => {
@miguelbermudez
miguelbermudez / states.md
Created November 22, 2016 04:04 — forked from alishalisha/states.md
Checking state on product design patterns

Checking the State of Your States

If applicable, make sure your design component accounts for all these states. This is basically copied from the Nine States of Design Medium article. 😛

  • Initial state: What happens before your component does anything? Maybe it’s the first time a user sees it. Maybe it’s not activated yet. Essentially, the component exists but hasn’t started.
  • Loading state: Have you accounted for when a user will be waiting for something to happen? What does that look like?
  • Empty state: Your component has initialized, but it’s empty. No data. No Items. Now may be a good time to get the user to act (“Do this thing!”), or to reward them (“Good job, everything is taken care of”).
  • One state: You have some data. On an input, this may be after the first keystroke. In a list, it might be when you have one item (or one left).
  • Some data state: This is usually what you think
@miguelbermudez
miguelbermudez / Makefile
Created December 16, 2016 22:26 — forked from rauhs/Makefile
Compiling clojurescript + figwheel without boot nor leiningen. Using leiningen to manage dependencies. Print file size stats (raw, gzip, brotli) for production builds
CLJ_NREPL_PORT:=22340
FIGWHEEL_PORT:=22345
CLJS_JAR_VERSION:=1.7.48
CLJS_JAR_URL:=https://github.com/clojure/clojurescript/releases/download/r$(CLJS_JAR_VERSION)/cljs.jar
.PHONY: def_target
def_target : null