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
test 2 |
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 ( | |
"log" | |
) | |
var outside = "outside" | |
func main() { | |
inside := "inside" |
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
import XMonad | |
import XMonad.Hooks.InitialStartupHook | |
import XMonad.Layout.LayoutScreens | |
import XMonad.Layout.TwoPane | |
import XMonad.Hooks.InsertPosition | |
import XMonad.Hooks.DynamicLog | |
import XMonad.Hooks.ManageDocks | |
import XMonad.Util.Run(spawnPipe) | |
import XMonad.Util.EZConfig(additionalKeysP) | |
import System.IO |
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
import XMonad | |
import XMonad.Hooks.InsertPosition | |
import XMonad.Hooks.DynamicLog | |
import XMonad.Hooks.ManageDocks | |
import XMonad.Hooks.FadeInactive | |
import XMonad.Util.Run | |
import XMonad.Util.EZConfig | |
import System.IO |
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
export PS1="\u\[$(tput setaf 3)\]@\[$(tput setaf 4)\]\H\[$(tput setaf 3)\]:\[$(tput setaf 6)\]\w\[$(tput setaf 3)\]\\$\[$(tput setaf 7)\]\[$(tput sgr0)\] " | |
#For servers: | |
#PROMPT_HOSTNAME=`hostname --long` | |
#export PS1="\u\[$(tput setaf 3)\]@\[$(tput setaf 1)\]\[$(tput smso)\]${PROMPT_HOSTNAME}\[$(tput rmso)\]\[$(tput setaf 3)\]:\[$(tput setaf 6)\]\w\[$(tput setaf 3)\]\\$\[$(tput setaf 7)\]\[$(tput sgr0)\] " | |
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
/home/geertjohan/Applications/go/src/pkg/net/http/server.go:576 (0x80e1e2e) | |
/home/geertjohan/Applications/go/src/pkg/runtime/proc.c:1443 (0x80635f0) | |
/home/geertjohan/Applications/go/src/pkg/runtime/runtime.c:128 (0x8064108) | |
/home/geertjohan/Applications/go/src/pkg/runtime/thread_linux.c:209 (0x8066d3f) | |
/home/geertjohan/Workspaces/WorkspaceGo/gopath/src/github.com/ziutek/mymysql/thrsafe/thrsafe.go:30 (0x808ce4a) | |
/home/geertjohan/Workspaces/WorkspaceGo/gopath/src/github.com/ziutek/mymysql/thrsafe/thrsafe.go:243 (0x808dfa0) | |
/home/geertjohan/Workspaces/WorkspaceGo/gopath/src/github.com/ziutek/mymysql/thrsafe/thrsafe.go:261 (0x808e0ae) | |
/home/geertjohanr/Workspaces/WorkspaceGo/devpath/src/rmapi-bu/s_newPrepaidVoipSubscription.go:22 (0x8052290) | |
_func_005: log.Println(err) | |
/home/geertjohanr/Workspaces/WorkspaceGo/devpath/src/rmapi-bu/service.go:211 (0x804ca7d) |
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
Config { font = "-misc-fixed-*-*-*-*-13-*-*-*-*-*-*-*" | |
, bgColor = "black" | |
, fgColor = "grey" | |
, position = TopW L 85 | |
, commands = [ Run Network "eth1" ["-L","0","-H","32","--normal","green","--high","red"] 10 | |
, Run Cpu ["-L","15","-H","50","--normal","green","--high","red"] 10 | |
, Run Memory ["-t","Mem: <usedratio>%"] 10 | |
, Run Swap [] 10 | |
, Run Date "%A %Y-%m-%d %H:%M:%S" "date" 10 | |
, Run StdinReader |
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
// Some functions to demonstrate the idea of must() | |
func zero() error { | |
return nil | |
} | |
func one() int, error { | |
return 1, nil | |
} | |
func two() string, int, error { |
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" | |
"tc" //terminal color | |
) | |
// First syntax idea | |
// Please skip this and take a look at the second idea. |
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
Regexp: `(?:(?:^\[?\[([a-zA-Z0-9\- ]+)\])|([.\n\r]+))*` | |
Input: "[red] blabla [[ escaped? [bla-fd] ]] escaped?" | |
Output(fmt %#v): []string{"[red]", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""} | |
Expected: []string{"[red]", " blabla [[ escaped? ", "[bla-fd]", " ]] escaped?"} | |
Regexp: \[([^\]]+)\] | |
Input: "[red] blabla [[ escaped? [bla-fd] ]] escaped?" | |
Output(fmt %#v): [][]int{[]int{0, 5}, []int{13, 33}} |
OlderNewer