Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am apeace on github.
  • I am apeace (https://keybase.io/apeace) on keybase.
  • I have a public key ASDScCOTw_ccl4UhfvALxMDD2xKAipeqCSo1adzBMfx_jQo

To claim this, I am signing this object:

// Intended usage: ./change-password.pxr <username> <oldPass> <newPass>
retcode ERR_SSH_FAILED 1 "Failed to ssh to $host: $output"
retcode ERR_UNKNOWN_PWD_OUTPUT 2 "The `passwd` command returned an unexpected output: $output"
retcode ERR_WRONG_PASSWORD 3 "The given oldPass is wrong"
retcode ERR_PASSWORD_DIDNT_SUCCEED 4 "The `passwd` command accepted the input but didn't succeed: $output"
retcode ERR_CONFIRM_DIDNT_SUCCEED 5 "The `passwd` confirmation accepted the input but didn't succeed: $output"
retcode ERR_UNKNOWN_SUDO_OUTPUT 6 "The `sudo` command returned an unexpected output: $output"
ssh andrew@foo.bar.baz
'use strict';
const PubNub = require('pubnub');
const PUBNUB_PUBLISH = process.env.PUBNUB_PUBLISH;
const PUBNUB_SUBSCRIBE = process.env.PUBNUB_SUBSCRIBE;
const TIMEOUT = 5000;
const msg = String(+new Date);
var client = require('socket.io-client')('http://10.0.2.2:9000/');
client.on('connect', function () {
console.log('connect');
});
client.on('disconnect', function () {
console.log('disconnect');
});
var expect = require('expect.js');
var model = require('./qmodel.js');
describe('qmodel', function () {
var createPersonModel = function () {
function Person (props) {
model.extend(this, Person, props);
}
Person.fields = {
; WARNING: THIS IS A COPYRIGHTED IMAGE
(define jayfeather <picture-here>)
(define jayfeather-upside-down (rotate 180 jayfeather))
(define (make-diamond color) (polygon (list (make-posn 0 0)
(make-posn -10 20)
(make-posn -20 0)
(make-posn -10 -20))
#lang racket
(require 2htdp/image)
(require test-engine/racket-tests)
(struct person (name year-born fav-color))
(define CURRENT-YEAR 2014)
(define andrew (person "Andrew" 1989 (color 20 90 200 255)))
(define derp (person "Derp" 1901 (color 232 121 204 255)))
#lang racket
; TODO: fix this so it actually works for more functions and graph views
(require 2htdp/image)
(require 2htdp/universe)
(require test-engine/racket-tests)
(define WIDTH 200)
(define HEIGHT 200)
#lang racket
(require 2htdp/universe)
(require 2htdp/image)
(require test-engine/racket-tests)
(define WIDTH 500)
(define HEIGHT 500)
(define BACKGROUND (rectangle WIDTH HEIGHT 'solid 'white))