Skip to content

Instantly share code, notes, and snippets.

View arr-ee's full-sized avatar

Max Barnash arr-ee

  • London, UK
  • 04:56 (UTC +01:00)
View GitHub Profile
<!doctype html>
<html>
<body>
<script type="text/javascript">
window.location.href = "http://ya.ru"
</script>
<img src="http://images.sodahead.com/profiles/0/0/1/0/0/4/6/8/3/obama-told-ya-92318595922.jpeg"></img>
</body>
</html>
@arr-ee
arr-ee / dabblet.css
Created April 11, 2013 16:28
Untitled
.v {
height: 500px;
background-color: #f8f8f8;
background-image: repeating-linear-gradient(45deg, #efefef, #efefef 1px, transparent 1px, transparent 5px),
repeating-linear-gradient(135deg, #efefef, #efefef 1px, transparent 1px, transparent 5px);
background-size: 7px 7px, 7px 7px;
}
@arr-ee
arr-ee / curl
Created January 11, 2013 06:37
Ratchet.io network problems
$ curl -v ratchet.io -L
* About to connect() to ratchet.io port 80 (#0)
* Trying 50.97.241.205...
* Operation timed out
* couldn't connect to host
* Closing connection #0
curl: (7) couldn't connect to host
@arr-ee
arr-ee / gist:4100449
Created November 17, 2012 21:27
getcloak.com log-in process
$ curl https://www.getcloak.com/accounts/log-in/ -Lv > /dev/null
* About to connect() to www.getcloak.com port 443 (#0)
* Trying 50.57.128.105...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0* connected
* Connected to www.getcloak.com (50.57.128.105) port 443 (#0)
* SSLv3, TLS handshake, Client hello (1):
} [data not shown]
* SSLv3, TLS handshake, Server hello (2):
maxbarnash@pinky:~/work/project@development$ ack 'include Mongoid::Document' app/ -ch
33
maxbarnash@pinky:~/work/project@development$ ack '< ActiveRecord::Base' app/ -ch
36
@arr-ee
arr-ee / gist:3357278
Created August 15, 2012 07:04
Unmaintainable
1.9.3p125 :001 > User
=> User(id: integer, name: string, created_at: datetime, updated_at: datetime)
1.9.3p125 :002 > User.create name: 'test'
=> #<User id: 1, name: "test", created_at: "2012-08-15 06:58:45", updated_at: "2012-08-15 06:58:45">
1.9.3p125 :003 > u = User.first
=> #<User id: 1, name: "test", created_at: "2012-08-15 06:58:45", updated_at: "2012-08-15 06:58:45">
1.9.3p125 :004 > u.last_name
NoMethodError: undefined method `last_name' for #<User:0x007fa9a59a9d08>
1.9.3p125 :005 > u.last_name = 'failed'
NoMethodError: undefined method `last_name=' for #<User:0x007fa9a59a9d08>
@arr-ee
arr-ee / dabblet.css
Created July 29, 2012 23:56
Untitled
.container {
font: 16px/24px Helvetica;
width: 400px;
text-align: center;
position: relative;
}
.separator {
border: none;
border-bottom: 1px solid grey;
@arr-ee
arr-ee / dabblet.css
Created May 15, 2012 13:35 — forked from LeaVerou/dabblet.css
Vertical centering with Flexbox + margin fallback
/**
* Vertical centering with Flexbox + margin fallback
* Lea Verou & David Storey
*/
html, body { height: 100%; }
body {
width: 100%; /* needed for FF */
margin: 0;
avg-cpu: %user %nice %system %iowait %steal %idle
0.31 0.00 0.10 6.00 0.04 93.54
Device: tps Blk_read/s Blk_wrtn/s Blk_read Blk_wrtn
sda1 1.58 10.04 35.74 503162 1791880
sda2 0.00 0.01 0.00 576 0
sda3 310.48 1752.07 15284.97 87844994 766356400
avg-cpu: %user %nice %system %iowait %steal %idle
0.16 0.00 0.10 6.44 0.03 93.27