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" | |
"strings" | |
) | |
func write(msg string) { | |
fmt.Println(msg) | |
} |
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
// Go Playground: https://play.golang.org/p/6C9Wj8uqmc | |
package main | |
import "fmt" | |
func increment(x int) int { | |
return x + 1 | |
} | |
func decrement(x int) int { |
If you're a JavaScript developer in 2016, you're likely at least aware of Lodash, a self-described
modern JavaScript utility library delivering modularity, performance, & extras.
Personally, it's a favorite of mine. From _.compact
all the way to _.toPath
, there's nothing like benefiting from the solution to a problem others have already solved; plus, I find its API to be enjoyable and intuitive.
Ran into the excon/openssl error certificate verify failed (OpenSSL::SSL::SSLError) Unable to verify certificate.
After reading through a few posts, trying different solutions, here are the steps that resolved the issue with regards to my particular needs. Final main source at the bottom.
brew doctor
brew update openssl
rvm get stable
rvm install ruby-2.1.9 --with-openssl-dir=`brew --prefix openssl`
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
/* | |
* Initially, test runs were handled via a single executable | |
* causing many large objects and references from within setup | |
* code, and perhaps vows, to hang around despite garbage collection. | |
*/ | |
(function runFile(i) { | |
if (i > filenames.length) { | |
return exit(); | |
} | |
const filename = filenames[i]; |
puppet-master.js
function exit() {
// check for and do something with instances of Error
// passed as arguments i/e if arguments.length > 1 ...
// Array.from(arguments).map...
if (process.env.CHILD_PID) {
childProcess.execFile(`kill -9 ${process.env.CHILD_PID}`);
}
printResults();
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 request from 'superagent'; | |
export const VALIDATING_TOKEN = 'VALIDATING_TOKEN'; | |
function requestTokenValidation() { | |
return { type: VALIDATING_TOKEN }; | |
} | |
export const TOKEN_VALIDATION_RECEIVED = 'TOKEN_VALIDATION_RECEIVED'; | |
function receiveTokenValidation(response) { | |
return { type: TOKEN_VALIDATION_RECEIVED, response }; |