Skip to content

Instantly share code, notes, and snippets.

View jackdesert's full-sized avatar

Jack Desert jackdesert

View GitHub Profile
@jackdesert
jackdesert / gist:4756dafda8cbca0da9ae
Created July 18, 2015 17:41
taskd build warnings
/home/dev/tmp/taskd-1.1.0/src/Server.cpp: In member function ‘void Server::daemonize()’:
/home/dev/tmp/taskd-1.1.0/src/Server.cpp:359:36: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen ("/dev/null", "r", stdin);
^
/home/dev/tmp/taskd-1.1.0/src/Server.cpp:360:37: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen ("/dev/null", "w", stdout);
^
/home/dev/tmp/taskd-1.1.0/src/Server.cpp:361:37: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen ("/dev/null", "w", stderr);
^
@jackdesert
jackdesert / write_from_stdin_to_file.go
Created May 6, 2015 20:30
write From STDIN to File
package main
import (
"io"
"io/ioutil"
"log"
"os"
)
func main() {
package main
import (
"bufio"
"io/ioutil"
"log"
"os"
)
func main() {
@jackdesert
jackdesert / riak_1.4_stack_track
Created March 24, 2015 20:44
riak 1.4 stack trace
[" dictionary: [{reqstate,{wm_reqstate,{ssl,{sslsocket,new_ssl,<0.9876.5034>}},[{'content-encoding','identity'},{'content-type','application/json'},{mediaparams,[]},{resource_module,riak_kv_wm_object}],undefined,undefined,'54.158.216.244',{wm_reqdata,'POST',https,{1,1},'54.158.216.244','54.158.216.244',undefined,'4JHotrGIRVv3bi1fdaOHcVbwPD','/buckets/samples_instances_responses/keys','/buckets\n /samples_instances_responses/keys?returnbody=true',[{bucket,'samples_instances_responses'}],[],'../../..',{500,undefined},1073741824,67108864,[],[{'returnbody','true'}],{10,{'user-agent',{'User-Agent','Ruby'},{'content-length',{'Content-Length','258732'},{'connection',{'Connection','keep-alive'},{'accept',{'Accept','multipart/mixed, application/json;q=0.7, */\n *;q=0.5'},nil,nil},nil},{'host',{'Host','reporting-provider.p.cloudability.org:8080'},{'content-type',{'Content-Type','application/json'},nil,nil},nil}},{'x-forwarded-proto',{'X-Forwarded-Proto','https'},{'x-forwarded-port',{'X-Forwarded-Port','8080'},
@jackdesert
jackdesert / diagnostics.txt
Created January 24, 2015 20:06
task diagnostics with 2.4.0
vagrant@precise64:~$ task diagnostics
task 2.4.0
Platform: Linux
Compiler
Version: 4.6.3
Caps: +stdc +stdc_hosted +200809 +LP64 +c8 +i32 +l64 +vp64 +time_t64
Compliance: 1
@jackdesert
jackdesert / run_taskd_indefinitely.sh
Last active August 29, 2015 14:04
Wrapper Script for taskd
#! /bin/bash
# this script is just a wrapper around taskd so that taskd
# will start up again immediately if it ever dies
#
# The proper way to invoke this script is to call
# `nohup script/run_taskd_indefinitely.sh &`
# Note that this script requires that $TASKDDATA is set
@jackdesert
jackdesert / task_diagnostics.txt
Created June 24, 2014 20:32
task diagnostics 15"
vagrant@precise64:~/.task$ task diagnostics
task 2.3.0
Platform: Linux
Compiler
Version: 4.6.3
Caps: +stdc +stdc_hosted +200809 +LP64 +c1 +i4 +l8 +vp8
Build Features
# Server Output
dev@taskd3:~/tmp/taskd-1.0.0/demo/server$ taskd server
s: INFO Server listening.
s: INFO connection from 76.115.175.209 port 52344
s: 2 ASSERT: gnutls_constate.c:695
s: 2 ASSERT: gnutls_db.c:238
s: 2 EXT[0xde9360]: Parsing extension 'SAFE RENEGOTIATION/65281' (1 bytes)
s: 2 EXT[0xde9360]: Parsing extension 'SIGNATURE ALGORITHMS/13' (10 bytes)
s: 2 EXT[SIGA]: rcvd signature algo (4.2) DSA-SHA256
@jackdesert
jackdesert / successful_taskwarrior_output.txt
Last active August 29, 2015 14:02
Successful output from from taskd server demo (client side)
dev@taskd3:~/tmp/taskd-1.0.0/demo/client$ ./run
--- case1 ---------------------------------------------------------------
--- list 1 --------------------------------------------------------------
Using alternate .taskrc file /home/dev/tmp/taskd-1.0.0/demo/client/tw1/rc
No matches.
--- sync 1 --------------------------------------------------------------
Using alternate .taskrc file /home/dev/tmp/taskd-1.0.0/demo/client/tw1/rc
Syncing with localhost:53589
Sync successful. No changes.
WORTH FIXING
------------
This code is our pride and joy.
We write code EVERY DAY that depends on this
Our forward progress is impeded by this on a weekly basis
If this ever breaks, our reputation is at stake
We are regularly confused by this
We are not sure why it keeps breaking
We are not sure exactly what it does