package main
import (
rwboards "@gno.land/demo/boards"
rboards "gno.land/demo/boards"
ravl "gno.land/demo/avl"
)
🧙♂️
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
// just reorganizing the current `std` into "categories", not yet improving the API. | |
// chain | |
type AddressList []Address | |
func NewAddressList() *AddressList | |
type RawAddress [RawAddressSize]byte | |
const RawAddressSize = 20 | |
type Address string | |
func DerivePkgAddr(pkgPath string) Address | |
func EncodeBech32(prefix string, bz [20]byte) Address |
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 config // r/sys/config | |
type Key string | |
// keep in sync with tm2/pkg/params | |
// (can be checked with CI) | |
const ( | |
Validators Key = "validators" | |
AllowedTokens Key = "allowed_tokens" | |
) |
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:build ignore | |
package main | |
import ( | |
"fmt" | |
"go/doc" | |
"go/parser" | |
"go/token" | |
"io/fs" |
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 test -v -run 'Testdata/1588' . | |
=== RUN TestTestdata | |
=== RUN TestTestdata/issue-1588 | |
testscript.go:534: WORK=$WORK | |
PATH=/usr/lib/go/bin:/home/howl/bin:/home/howl/go/bin:/home/howl/.yarn/bin:/home/howl/.npm-packages/bin:/home/howl/go/bin:/home/howl/.yarn/bin:/home/howl/.npm-packages/bin:/home/howl/.asdf/shims:/home/howl/.local/share/asdf/bin:/home/howl/bin:/home/howl/go/bin:/home/howl/.yarn/bin:/home/howl/.npm-packages/bin:/home/howl/.cargo/bin:/home/howl/.nvm/versions/node/v16.18.0/bin:/home/howl/go/bin:/home/howl/.yarn/bin:/home/howl/.npm-packages/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/bin:/home/howl/py/bin:/home/howl/py/bin | |
GOTRACEBACK=system | |
HOME=/no-home | |
TMPDIR=$WORK/.tmp | |
devnull=/dev/null | |
/=/ |
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
/* Sample output: | |
prog.go:11 main.main | |
proc.go:250 runtime.main | |
asm_amd64.s:1598 runtime.goexit | |
*/ | |
package main | |
import ( | |
"fmt" |
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
Array.from(document.querySelectorAll(".user-list-inner-wrap")).filter(x => x.querySelector(".user-follow") === null).forEach(x => x.querySelector('.follower-btn-following').click()) |
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
#!/usr/bin/env bash | |
# Small script to create a certificate authority to be used for SMART Health Cards. | |
# The script accepts an argument, which is the name of your organisation (ie. "ACME Ltd") | |
# The script will generate a data subdirectory in $PWD, the relevant files for | |
# the implementation of SMART Health Cards are issuer.key8 and chain. | |
# SUBJECT_ALT_NAME should be adjusted accordingly. | |
set -e | |
set -u | |
set -o pipefail |
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
#!/bin/bash | |
# provides documentation for the sub-commands. | |
DOCUMENTATION=( | |
'help [COMMAND]' | |
"returns help for the specified command, or for all commands if none is specified. | |
$ ./tool help | |
$ ./tool help up" | |
'dev [COMMAND]' |
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
#!/usr/bin/bash | |
# Looking at the source, I see. | |
# Bear with me. I can barely understand bash, let alone writing it. | |
# See that something can be done in a much better way? Just Pull Request It (tm) | |
if [ -z ${1+x} ]; then nproj=${PWD##*/}; else nproj=$1; fi | |
echo project name $nproj | |
for GOOS in darwin linux windows; do | |
for GOARCH in 386 amd64; do | |
echo "Building $GOOS-$GOARCH" | |
if [ $GOOS == "windows" ]; then extension=".exe"; else extension=""; fi |
NewerOlder