This file contains 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
// | |
// EDIT: this code is now old | |
// i have recently (april 2016) updated it to use the new golang.org/x/oauth2 lib | |
// you can get the new analytics dumper at the below url: | |
// https://gist.github.com/rickt/d839564155cac15d59b6027668d8cb64 | |
// | |
package main | |
import ( |
This file contains 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
package main | |
import ( | |
"fmt" | |
"github.com/nlopes/slack" | |
) | |
func main() { | |
// create new slack object & connect | |
api := slack.New("TOKEN_REDACTED") | |
api.SetDebug(true) | |
rtm := api.NewRTM() |
This file contains 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
// http://japan-timebot-simple.appspot.com | |
package japantime | |
import ( | |
"fmt" | |
"net/http" | |
"time" | |
) |
This file contains 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
package main | |
import ( | |
"crypto/cipher" | |
"fmt" | |
"go.crypto/blowfish" | |
) | |
func blowfishChecksizeAndPad(pt []byte) []byte { | |
// calculate modulus of plaintext to blowfish's cipher block size |
This file contains 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
package main | |
import ( | |
"crypto/tls" | |
"fmt" | |
"log" | |
"net" | |
"net/mail" | |
"net/smtp" | |
) |
This file contains 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
package main | |
import ( | |
"flag" | |
"fmt" | |
steam "github.com/kidoman/go-steam" | |
"sort" | |
) | |
var addresses = []string{ |
This file contains 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
package main | |
import ( | |
"fmt" | |
"time" | |
) | |
const ( | |
datelayout string = "2006-01-02 15:04:05" | |
) |
This file contains 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
package main | |
// use this with tcpgobserver.go | |
import ( | |
"encoding/gob" | |
"fmt" | |
"log" | |
"net" | |
) |
This file contains 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
package main | |
// use this with tcpgobclient.go | |
import ( | |
"encoding/gob" | |
"fmt" | |
"net" | |
) |
This file contains 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
package main | |
import ( | |
"fmt" | |
"os" | |
) | |
// func main | |
func main() { | |
var s string = os.Args[1] |