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" | |
"net/http" | |
"encoding/json" | |
"strconv" | |
"os" | |
"log" | |
"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
{ | |
"cmd": ["haml"], | |
"working_dir": "${file_path:${folder}}", | |
"selector": "source.haml", | |
"file_regex": "(.*\\.ts?)\\s\\(([0-9]+)\\,([0-9]+)\\)\\:\\s(...*?)$", | |
"windows": | |
{ | |
"cmd": ["haml", "--trace", "$file", "${file_base_name}.html"], | |
"shell": "true" |
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
var NOISE = NOISE || { }; | |
NOISE.Simplex = (function() { | |
var iOctaves = 1, | |
fPersistence = 0.5, | |
fResult, fFreq, fPers, | |
aOctFreq, // frequency per octave | |
aOctPers, // persistance per octave | |
fPersMax; // 1 / max persistence |
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
//for Windows | |
{ | |
"cmd": ["tsc","$file"], | |
"file_regex": "(.*\\.ts?)\\s\\(([0-9]+)\\,([0-9]+)\\)\\:\\s(...*?)$", | |
"selector": "source.ts", | |
"windows": { | |
"cmd": ["tsc.cmd", "$file"] | |
} | |
} |
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" | |
// Generate the input values passing through the go channel pipe | |
func generate(ch chan int) { | |
go func() { | |
for i := 2; ; i++ { | |
ch <- i | |
} |
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" | |
"log" | |
"math/rand" | |
"os" | |
"runtime" | |
"strconv" | |
"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 ( | |
"fmt" | |
"github.com/shiena/ansicolor" | |
"os" | |
"sync" | |
) | |
const ( |
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
<html> | |
<head> | |
<meta charset="utf-8" /> | |
<script src="js/wasm_exec.js"></script> | |
<script type="text/javascript"> | |
function fetchAndInstantiate(url, importObject) { | |
return fetch(url).then(response => | |
response.arrayBuffer() | |
).then(bytes => | |
WebAssembly.instantiate(bytes, importObject) |
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
ifeq ($(OS),Windows_NT) | |
BROWSER = start | |
else | |
UNAME := $(shell uname -s) | |
ifeq ($(UNAME), Linux) | |
BROWSER = xdg-open | |
endif | |
ifeq ($(UNAME), Darwin) | |
BROWSER = open | |
endif |
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
// +build js,wasm | |
package main | |
import ( | |
"fmt" | |
"github.com/esimov/pigo/wasm/canvas" | |
) |