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
bundle show --paths | while IFS= read -r gem_path; do | |
extconf_files=$(find "$gem_path" -name 'extconf.rb') | |
if [[ -n "$extconf_files" ]]; then | |
echo "Checking dependencies for gem at: $gem_path" | |
grep 'have_library' $extconf_files | sed -E 's/.*have_library\("([^"]+)"\).*/\1/' | sort -u | |
echo "------------------------------------" | |
fi | |
done |
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> | |
<style> | |
:root { | |
--base-color: #f06721; | |
--highlight-color: #e8976f; | |
} | |
#luz-logo{ | |
fill: var(--base-color); | |
} |
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
### Keybase proof | |
I hereby claim: | |
* I am featheredtoast on github. | |
* I am featheredtoast (https://keybase.io/featheredtoast) on keybase. | |
* I have a public key ASDiV6MKV5qwcZfez_0NAyKJaK4_VpNBvw7o66kqG96oUwo | |
To claim this, I am signing this object: |
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 logic-foo.core | |
(:use [clojure.core.logic] | |
[clojure.core.logic.pldb] | |
[clojure.tools.macro])) | |
(defmacro mastermind | |
[spaces possibles unknown-pos known-pos] | |
(let [q (gensym) | |
arg (gensym) | |
syms (mapv (fn [_] (gensym)) (range spaces))] |
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> | |
<script> | |
var args = { | |
headers: new Headers({ | |
'Content-Type': 'text/plain' | |
})}; | |
async function useAwaits() { | |
try { | |
let resp = await fetch("https://en.wikipedia.org/w/api.php?action=opensearch&format=json&origin=*&search=stack&limit=10", args); |
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
body { | |
margin: 0; | |
height: 100vh; | |
background-color: white; | |
display: grid; | |
grid-template-columns: 1fr 1fr 120; | |
grid-template-rows: 50px auto 20px; | |
grid-template-areas: | |
"header header header" | |
"secondary main sidebar" |
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
(if (reduce (fn [a v] (if (< 2 v) (reduced v) v)) [1 2 3 4 5]) | |
"reduced" | |
"no") ;; reduced | |
(let [res (reduce (fn [a v] (if (< 2 v) (reduced v) v)) [1 2 3 4 5])] | |
(if (reduced? res) | |
"reduced" | |
"no")) ;; no |
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 find-adjacent-coordinate [[x y] direction] | |
(condp = direction | |
:right [(inc x) y] | |
:up [x (inc y)] | |
:left [(dec x) y] | |
:down [x (dec y)])) | |
(defn find-turn [direction] | |
(direction {:right :up | |
:up :left |
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 parse-input [str] | |
(->> (clojure.string/split-lines str) | |
(mapv #(clojure.string/split % #"\s")))) | |
(defn convert-to-nums [row] | |
(mapv #(Integer/parseInt %) row)) | |
(defn find-row-diff [row] | |
(println "finding max of " row) | |
(- (apply max row) (apply min row))) |
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 double-up [coll] | |
(->> (repeat coll) | |
(take 2) | |
(apply concat))) | |
(defn split-out-by-parts [length coll] | |
(->> (partition (inc (/ (count coll) 4)) 1 coll ) | |
(take length) | |
(map (juxt first last)))) |
NewerOlder