A tweet-sized debugger for visualizing your CSS layouts. Outlines every DOM element on your page a random (valid) CSS hex color.
One-line version to paste in your DevTools
Use $$ if your browser aliases it:
~ 108 byte version
| # aproducer.py | |
| # | |
| # Async Producer-consumer problem. | |
| # Challenge: How to implement the same functionality, but no threads. | |
| import time | |
| from collections import deque | |
| import heapq | |
| class Scheduler: |
| package main | |
| import ( | |
| "log" | |
| "net/http" | |
| "net/http/httputil" | |
| "net/url" | |
| ) | |
| var ( |
| Benchmark code at: https://github.com/nathanmarz/specter/blob/master/scripts/benchmarks.clj | |
| Run against Clojure 1.7.0 and Java 1.7.0 on Mac OSX 10.11.6 | |
| Benchmark: get value in nested map (2500000 iterations) | |
| Avg(ms) vs best Code | |
| 53.528 1.00 (-> data (get :a) (get :b) (get :c)) | |
| 54.708 1.02 (-> data :a :b :c) |
| ~/dev/scala/cljrepl $ cat build.sbt | |
| scalaVersion := "2.11.8" | |
| libraryDependencies ++= Seq( | |
| "org.clojure" % "clojure" % "1.8.0" | |
| ) | |
| ~/dev/scala/cljrepl $ cat src/main/scala/foo.scala | |
| import clojure.java.api.Clojure | |
| import clojure.java.api.Clojure.{`var` => cvar} |
| docker ps | awk {' print $1 '} | tail -n+2 > tmp.txt; for line in $(cat tmp.txt); do docker kill $line; done; rm tmp.txt |
| # /usr/libexec/java_home -X | |
| $ sudo opensnoop -n java_home | |
| UID PID COMM FD PATH | |
| 501 79809 java_home 3 /System/Library/PrivateFrameworks/JavaLaunching.framework/Versions/A/JavaLaunching | |
| 501 79809 java_home 3 /dev/dtracehelper | |
| 501 79809 java_home 4 /System/Library/CoreServices/SystemVersion.bundle//English.lproj | |
| 501 79809 java_home -1 /System/Library/CoreServices/SystemVersion.bundle//Base.lproj | |
| 501 79809 java_home 4 /System/Library/CoreServices/SystemVersion.bundle/English.lproj/SystemVersion.strings | |
| 501 79809 java_home -1 /System/Library/CoreServices/SystemVersion.bundle/English.lproj/SystemVersion.stringsdict | |
| 501 79809 java_home 3 /usr/share/icu/icudt51l.dat |
| // Future versions of Hyper may add additional config options, | |
| // which will not automatically be merged into this file. | |
| // See https://hyper.is#cfg for all currently supported options. | |
| module.exports = { | |
| config: { | |
| // default font size in pixels for all tabs | |
| fontSize: 14, | |
| // font family with optional fallbacks |
| #!/bin/sh | |
| # Credits to: | |
| # - http://vstone.eu/reducing-vagrant-box-size/ | |
| # - https://github.com/mitchellh/vagrant/issues/343 | |
| aptitude -y purge ri | |
| aptitude -y purge installation-report landscape-common wireless-tools wpasupplicant ubuntu-serverguide | |
| aptitude -y purge python-dbus libnl1 python-smartpm python-twisted-core libiw30 | |
| aptitude -y purge python-twisted-bin libdbus-glib-1-2 python-pexpect python-pycurl python-serial python-gobject python-pam python-openssl libffi5 |