Skip to content

Instantly share code, notes, and snippets.

View georgedrummond's full-sized avatar
:fishsticks:

George Drummond georgedrummond

:fishsticks:
  • GitHub Staff
  • Philadelphia
View GitHub Profile
@georgedrummond
georgedrummond / sshd.go
Last active February 26, 2020 05:55 — forked from nictuku/sshd.go
Go SSH server complete example
package main
import (
"fmt"
"io"
"io/ioutil"
"log"
"code.google.com/p/go.crypto/ssh"
"code.google.com/p/go.crypto/ssh/terminal"

Introduction

  • C-a == Ctrl-a
  • M-a == Alt-a

General

:q        close
:w        write/saves
:wa[!]    write/save all windows [force]
:wq       write/save and close
{
"header": {
"Name": "MDErgo1",
"Layout": "Default",
"Base": "Blank",
"Version": "0.1",
"Author": "HaaTa (Jacob Alexander) 2015",
"KLL": "0.3c",
"Date": "2015-09-12",
"Generator": "KIICONF 0.2"

Keybase proof

I hereby claim:

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

To claim this, I am signing this object:

@georgedrummond
georgedrummond / gist:cc6b401da1428aa1c701
Created March 9, 2016 04:44 — forked from panuta/gist:1897940
Generate a document thumbnail (doc, xls, ppt and openoffice formats) in Ubuntu Server 10.04
  1. Install OpenOffice headless package

    $ sudo apt-get install openoffice.org-headless openoffice.org-java-common openoffice.org-writer openoffice.org-calc openoffice.org-impress
    
  2. Install UNO python library

$ sudo apt-get install python-uno unoconv

2012-09-25T22:44:14+00:00 app[web.1]: Started POST "/random_acts_of_kindness/2/received_kindnesses" for 81.157.45.246 at 2012-09-25 22:44:14 +0000
2012-09-25T22:44:14+00:00 app[web.1]: {"kindness_id"=>"37", "image"=>#<ActionDispatch::Http::UploadedFile:0x0000000719e6d0 @original_filename="kakow.gif", @content_type="image/gif", @headers="Content-Disposition: form-data; name=\"received_kindness[image]\"; filename=\"kakow.gif\"\r\nContent-Type: image/gif\r\n", @tempfile=#<File:/tmp/RackMultipart20120925-10-pshr7i>>, "how_receiver_feel"=>"", "how_receiver_will_spend"=>""}
2012-09-25T22:44:17+00:00 app[web.1]: #<Kindness id: 37, lat: #<BigDecimal:70595e0,'0.5149635283 260691E2',27(27)>, lng: #<BigDecimal:70594a0,'-0.6302861328 129E-1',18(27)>, location: nil, giver_id: 38, rak_blog_id: 2, receiver_id: 49, image: "", how_receiver_will_spend: "", how_receiver_feel: "", updated_at: "2012-09-25 18:37:38", address: "4 Collett Rd, Bermondsey, London Borough of Southwa...", flagged: false, flagged_comment: nil, giver_comm
127.0.0.1 signup.mydomain.dev test1.mydomain.dev test2.mydomain.dev
Myapp::Application.routes.draw do
# signup.host.com
constraints :subdomain => "signup" do
resources :accounts
match "signup" => "accounts#new"
root :to => "accounts#new"
end
# Catch all subdomains except "signup.host.com"
[remote "all"]
url = git@heroku.com:myapp.git
url = git@github.com:georgedrummond/myapp.git
@georgedrummond
georgedrummond / gist:985357
Created May 22, 2011 10:45
install heroku jammit
heroku plugins:install git@github.com:kylejginavan/heroku_jammit.git