Skip to content

Instantly share code, notes, and snippets.

@bowmanmike
bowmanmike / tasks.json
Created Jun 6, 2020
VSCode Elixir tasks.json
View tasks.json
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"label": "mix test -- all",
"type": "shell",
"group": "test",
"command": "mix test",
@bowmanmike
bowmanmike / daily_progress_template.md
Created Jul 6, 2017
Daily progress tracker template
View daily_progress_template.md
View bd3d4befe38185704bf0fc875e9deed6|configuration.json
{"contents":{"python":{"pythonPath":"/usr/local/bin/python"},"launch":{"version":"0.2.0","configurations":[{"name":"Listen for rdebug-ide","type":"Ruby","request":"attach","cwd":"${workspaceRoot}","remoteHost":"127.0.0.1","remotePort":"1234","remoteWorkspaceRoot":"${workspaceRoot}"},{"name":"Rails server","type":"Ruby","request":"launch","cwd":"${workspaceRoot}/thescore-api","program":"${cwd}/bin/rails","args":["server"]},{"name":"RSpec - active spec file only","type":"Ruby","request":"launch","cwd":"${workspaceRoot}","program":"/Users/mbowman/thescore/sports/thescore-pulse/pulse/bin/rspec","args":["--require","spec_helper","${file}"]}]},"tasks":{"version":"2.0.0","tasks":[{"label":"rake db:migrate","type":"shell","command":"bundle exec rake db:migrate","options":{"cwd":"/Users/mbowman/thescore/sports/thescore-api"},"problemMatcher":[]},{"label":"rake db:test:prepare","type":"shell","command":"bundle exec rake db:test:prepare","options":{"cwd":"/Users/mbowman/thescore/sports/thescore-api"},"problemMatcher":[]
@bowmanmike
bowmanmike / dynamic_function_calls.go
Created Feb 22, 2017
Golang Dynamic Function Calling
View dynamic_function_calls.go
package main
import (
"fmt"
)
// Use map[string]interface{} to pair functions to name
// Could maybe use anonymous functions instead. Might be clean
// in certain cases
var funcMap = map[string]interface{}{
@bowmanmike
bowmanmike / coverage
Last active Nov 28, 2016
Go Test Coverage Aggregator
View coverage
#!/bin/sh
# Generate test coverage statistics for Go packages.
# Adapted from https://github.com/mlafeldt/chef-runner/blob/v0.7.0/script/coverage
#
# Works around the fact that `go test -coverprofile` currently does not work
# with multiple packages, see https://code.google.com/p/go/issues/detail?id=6909
#
# Usage: script/coverage [--html|--coveralls]
#
# --html Additionally create HTML report and open it in browser
You can’t perform that action at this time.