
Security News
GitHub Actions Pricing Whiplash: Self-Hosted Actions Billing Change Postponed
GitHub postponed a new billing model for self-hosted Actions after developer pushback, but moved forward with hosted runner price cuts on January 1.
github.com/gravitational/configure
Advanced tools
configure is a golang library that populates a struct from environment variables, command line arguments and YAML files.
It works by reading a struct definition with special tags.
The latest can be seen if you run:
godoc github.com/gravitational/configure
But here's a quickstart: Define a sample structure, for example:
type Config struct {
StringVar string `env:"STRING_VAR" cli:"string-var" yaml:"string_var"`
BoolVar bool `env:"BOOL_VAR" cli:"bool_var" yaml:"bool_var"`
IntVar int `env:"INT_VAR" cli:"int_var" yaml:"int_var"`
HexVar hexType `env:"HEX_VAR" cli:"hex_var" yaml:"hex_var"`
MapVar map[string]string `env:"MAP_VAR" cli:"map_var" yaml:"map_var,flow"`
SliceMapVar []map[string]string `env:"SLICE_MAP_VAR" cli:"slice_var" yaml:"slice_var,flow"`
}
Then you can query the environment and populate that structure from environment variables, YAML files or command line arguments.
import (
"os"
"github.com/gravitational/configure"
)
func main() {
var cfg Config
// parse environment variables
err := configure.ParseEnv(&cfg)
// parse YAML
err = configure.ParseYAML(&cfg)
// parse command line arguments
err = configure.ParseCommandLine(&cfg, os.Args[1:])
}
FAQs
Unknown package
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
GitHub postponed a new billing model for self-hosted Actions after developer pushback, but moved forward with hosted runner price cuts on January 1.

Research
Destructive malware is rising across open source registries, using delays and kill switches to wipe code, break builds, and disrupt CI/CD.

Security News
Socket CTO Ahmad Nassri shares practical AI coding techniques, tools, and team workflows, plus what still feels noisy and why shipping remains human-led.