This file contains hidden or 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
#!/bin/sh | |
/Applications/Emacs.app/Contents/MacOS/Emacs "$@" & |
This file contains hidden or 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
#!/bin/bash | |
# upgrade all packages | |
export DEBIAN_FRONTEND=noninteractive | |
apt-get update | |
apt-get -y upgrade | |
# Install brightbox ruby repository | |
apt-get install -y python-software-properties | |
apt-add-repository -y ppa:brightbox/ruby-ng |
This file contains hidden or 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
➜ ~ echo "foo" | od | |
0000000 067546 005157 | |
0000004 | |
➜ ~ echo "foo" | xxd | |
0000000: 666f 6f0a foo. |
This file contains hidden or 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
omarqureshi=# select regexp_replace('lorem ipsum dolor sit amet', '\w(\w+)', 'x', 'g'); | |
regexp_replace | |
---------------- | |
x x x x x |
This file contains hidden or 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
require './gilded_rose.rb' | |
require "rspec" | |
describe GildedRose do | |
before do | |
@gilded_rose = GildedRose.new | |
end | |
describe "Sulfuras, Hand of Ragnaros" do |
This file contains hidden or 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
<div class="reminder-at"> | |
<div class="sms-options-group"> | |
<strong>Schedule SMS Reminder</strong> | |
<label> | |
<!--[if lte IE 7]> | |
<input class="sms-options" type="radio" name="goal[reminder_type]" value="recurring" ng-click="setGoalReminderType(goal, 'recurring')" ng-checked="goal.reminder_type == 'recurring'"> | |
<![endif]--> | |
<!--[if gt IE 7]><!--> | |
<input class="sms-options" type="radio" name="goal[reminder_type]" value="recurring" ng-model="goal.reminder_type"> | |
<!--<![endif]--> |
This file contains hidden or 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
The medical records of every NHS hospital patient in the country have been sold for insurance purposes, The Telegraph can reveal. | |
The disclosure comes days after controversial plans to extract patient data from GP files were put on hold, amid concerns over the scheme. | |
Those in charge of the programme have repeatedly insisted that it will be illegal for information extracted from GP files to be sold to insurers, who might seek to target customers or put up their prices. | |
However, a report by a major UK insurance society discloses that it was able to obtain 13 years of hospital data – covering 47 million patients – in order to help companies “refine” their premiums. | |
As a result they recommended an increase in the costs of policies for thousands of customers last year. The report by the Staple Inn Actuarial Society – a major organisation for UK insurers – details how it was able to use NHS data covering all hospital in-patient stays between 1997 and 2010 to track the medical histories of patients, identified by d |
This file contains hidden or 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
#!/bin/sh | |
### BEGIN INIT INFO | |
# Provides: unicorn | |
# Required-Start: $remote_fs $syslog | |
# Required-Stop: $remote_fs $syslog | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Manage unicorn server | |
# Description: Start, stop, restart unicorn server for a specific application. | |
### END INIT INFO |
This file contains hidden or 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
p1.9.3p448 :001 > if a = true | |
1.9.3p448 :002?> puts "A" | |
1.9.3p448 :003?> elsif b = false | |
1.9.3p448 :004?> puts "B" | |
1.9.3p448 :005?> end | |
(irb):3: warning: found = in conditional, should be == | |
(irb):1: warning: found = in conditional, should be == | |
A | |
=> nil |
This file contains hidden or 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
f = function() { } | |
function () { } | |
f.length | |
0 | |
f = function(a, b) { } | |
function (a, b) { } | |
f.length | |
2 |