This file contains hidden or 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 sqlite | |
| import ( | |
| "database/sql" | |
| "database/sql/driver" | |
| "fmt" | |
| "modernc.org/sqlite" | |
| ) |
This file contains hidden or 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 ( | |
| "encoding/json" | |
| "fmt" | |
| "os" | |
| ) | |
| func bar() (int, error) { return 2, fmt.Errorf("testerr") } |
This file contains hidden or 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
| javascript:document.querySelectorAll("li section").forEach(s => s.innerHTML = s.innerHTML.replace(/(https:\/\/.*)/, "<a href='$1' target='_blank'>$1</a>")) |
This file contains hidden or 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
| // alt. https://github.com/kubernetes/apimachinery/blob/master/pkg/apis/meta/v1/duration.go | |
| package duration | |
| import ( | |
| "encoding/json" | |
| "fmt" | |
| "time" | |
| ) | |
| type Duration struct { |
This file contains hidden or 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
| #!/usr/bin/env bash | |
| set -Eeuo pipefail | |
| trap cleanup SIGINT SIGTERM ERR EXIT | |
| script_dir=$(cd "$(dirname "${BASH_SOURCE[0]}")" &>/dev/null && pwd -P) | |
| usage() { | |
| cat <<EOF | |
| Usage: $(basename "${BASH_SOURCE[0]}") [-h] [-v] [-f] -p param_value arg1 [arg2...] |
This file contains hidden or 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
| #!/usr/bin/env python3 | |
| import argparse | |
| import os | |
| import random | |
| import shutil | |
| import time | |
| import warnings | |
| import torch | |
| import torch.nn as nn |
This file contains hidden or 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
| FROM ubuntu:18.04 | |
| ENV LC_ALL=C.UTF-8 | |
| ENV TERM=xterm | |
| ADD http://devtools.dl.atlab.ai/docker/PRC-tz /etc/localtime | |
| ADD https://github.com/krallin/tini/releases/download/v0.18.0/tini /usr/local/bin/tini | |
| ADD https://github.com/tobert/pcstat/raw/2014-05-02-01/pcstat.x86_64 /usr/local/bin/pcstat | |
| RUN chmod +x /usr/local/bin/tini && chmod +x /usr/local/bin/pcstat |
This file contains hidden or 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
| #!/bin/bash | |
| FQDN=$1 | |
| # make directories to work from | |
| mkdir -p server/ client/ all/ | |
| # Create your very own Root Certificate Authority | |
| openssl genrsa \ | |
| -out all/my-private-root-ca.privkey.pem \ | |
| 2048 |
This file contains hidden or 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" | |
| "regexp" | |
| "strings" | |
| ) | |
| const cueInfo = `FILE "01 遺サレタ場所:丁.wav" WAVE | |
| TRACK 01 AUDIO |
This file contains hidden or 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" | |
| "io" | |
| "io/ioutil" | |
| "net" | |
| "net/http" | |
| "sync" | |
| "time" |
NewerOlder