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 util.natural-sorting | |
(:refer-clojure :exclude [sort sort-by]) | |
(:require [clojure.string])) | |
(defn parse-int [s] | |
#?(:clj (Long/parseLong s) | |
:cljs (js/parseInt s))) | |
(defn vector-compare [[value1 & rest1] [value2 & rest2]] | |
(let [result (compare value1 value2)] |
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
defmodule ChromeBookmarks do | |
defrecord Bookmark, name: nil, url: nil | |
def main do | |
query = System.get_env("QUERY") | |
bookmarks_from_file("/Users/wilkerlucio/Library/Application Support/Google/Chrome/Default/Bookmarks") | |
|> search_bookmarks(query) | |
|> output | |
end |
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
-- Example list of processes to ignore: {"xGestures"} or {"xGestures", "OtherApp", ...} | |
property processesToIgnore : {} | |
-- Get the size of the Display(s), only useful if there is one display | |
-- otherwise it will grab the total size of both displays | |
tell application "Finder" | |
set _b to bounds of window of desktop | |
set screen_width to item 3 of _b | |
set screen_height to item 4 of _b | |
end tell |
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
(defn pathom-remote [parser] | |
{:transmit! (fn transmit! [_ {::txn/keys [ast result-handler]}] | |
(let [edn (eql/ast->query ast) | |
ok-handler (fn [result] | |
(try | |
(result-handler (assoc result :status-code 200)) | |
(catch :default e | |
(js/console.error e "Result handler for remote failed with an exception.")))) | |
error-handler (fn [error-result] | |
(try |
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
A for Andromeda | |
Aaagh! It's the Mr. Hell Show! | |
Aaahh!!! Real Monsters | |
Aaron Stone | |
Aaron's Way | |
The Abbott and Costello Show | |
Abby | |
The ABC Afterschool Special | |
About a Girl | |
Above the Law |
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
(defn cache-resolver [resolver] | |
(update resolver ::pc/resolve | |
(fn [resolve] | |
(fn [{::keys [persistent-cache*] :as env} input] | |
(let [cache-key [(::pc/sym resolver) input (p/params env)]] | |
(if-let [[_ v] (find @persistent-cache* cache-key)] | |
v | |
(let [response (resolve env input)] | |
(swap! persistent-cache* assoc cache-key response) | |
response))))))) |
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
$my-icons-spacing: 10px; // give some space to avoid little pixel size issues on resize | |
@import "my-icons/*.png"; | |
$my-icons-sprite-dimensions: true; | |
@include all-my-icons-sprites; | |
// the fun part |
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 your-ns | |
(:require [clojure.test.check.properties :as prop] | |
[com.wsscode.pathom.gen :as sgen] | |
[cljs.test :refer [is]] | |
[clojure.test.check.generators :as gen :include-macros true] | |
[fulcro.client.primitives :as fp] | |
[clojure.test.check :as tc] | |
[fulcro.client.mutations :as fm] | |
[clojure.data :as data])) |
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
/*! tether 1.4.4 */ | |
(function(root, factory) { | |
if (typeof define === 'function' && define.amd) { | |
define([], factory); | |
} else if (typeof exports === 'object') { | |
module.exports = factory(); | |
} else { | |
root.Tether = factory(); | |
} |
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
[{:com.wsscode.pathom.trace/event | |
:com.wsscode.pathom.parser/parse-loop, | |
:com.wsscode.pathom.trace/timestamp-leave 1535741953047, | |
:com.wsscode.pathom.trace/timestamp 1535741952740, | |
:com.wsscode.pathom.core/path [], | |
:com.wsscode.pathom.trace/relative-timestamp 0, | |
:com.wsscode.pathom.trace/duration 307} | |
{:key :fulcro.inspect.workspaces.ui.pathom-trace-cards/color, | |
:com.wsscode.pathom.trace/event | |
:com.wsscode.pathom.parser/process-key, |
NewerOlder