An open API service providing repository metadata for many open source software ecosystems.

Package Usage: go: github.com/spf13/pflag

Package pflag is a drop-in replacement for Go's flag package, implementing POSIX/GNU-style --flags. pflag is compatible with the GNU extensions to the POSIX recommendations for command-line options. See http://www.gnu.org/software/libc/manual/html_node/Argument-Syntax.html Usage: pflag is a drop-in replacement of Go's native flag package. If you import pflag under the name "flag" then all code should continue to function with no changes. There is one exception to this: if you directly instantiate the Flag struct there is one more field "Shorthand" that you will need to set. Most code never instantiates this struct directly, and instead uses functions such as String(), BoolVar(), and Var(), and is therefore unaffected. Define flags using flag.String(), Bool(), Int(), etc. This declares an integer flag, -flagname, stored in the pointer ip, with type *int. If you like, you can bind the flag to a variable using the Var() functions. Or you can create custom flags that satisfy the Value interface (with pointer receivers) and couple them to flag parsing by For such flags, the default value is just the initial value of the variable. After all flags are defined, call to parse the command line into the defined flags. Flags may then be used directly. If you're using the flags themselves, they are all pointers; if you bind to variables, they're values. After parsing, the arguments after the flag are available as the slice flag.Args() or individually as flag.Arg(i). The arguments are indexed from 0 through flag.NArg()-1. The pflag package also defines some new functions that are not in flag, that give one-letter shorthands for flags. You can use these by appending 'P' to the name of any function that defines a flag. Shorthand letters can be used with single dashes on the command line. Boolean shorthand flags can be combined with other shorthand flags. Command line flag syntax: Unlike the flag package, a single dash before an option means something different than a double dash. Single dashes signify a series of shorthand letters for flags. All but the last shorthand letter must be boolean flags. Flag parsing stops after the terminator "--". Unlike the flag package, flags can be interspersed with arguments anywhere on the command line before this terminator. Integer flags accept 1234, 0664, 0x1234 and may be negative. Boolean flags (in their long form) accept 1, 0, t, f, true, false, TRUE, FALSE, True, False. Duration flags accept any input valid for time.ParseDuration. The default set of command-line flags is controlled by top-level functions. The FlagSet type allows one to define independent sets of flags, such as to implement subcommands in a command-line interface. The methods of FlagSet are analogous to the top-level functions for the command-line flag set.
7 versions
Latest release: over 5 years ago
57,644 dependent packages

View more package details: https://packages.ecosystem.code.gouv.fr/registries/proxy.golang.org/packages/github.com/spf13/pflag

Dependent Repos 49

healthdatahub/outils-pour-la-plateforme-technologique/ingestion-transfo-tools

Last synced: about 5 hours ago - Pushed: 12 months ago

rferrand/go-config-files-utils
Go library providing various helpers to work with configuration files

Last synced: about 1 year ago - Pushed: 12 months ago

1024pix/steampipe-plugin-learningcontent
Steampipe plugin to query LCMS content

Size: 101 KB - Last synced: 7 days ago - Pushed: over 1 year ago

1024pix/steampipe-plugin-metabase
Use SQL to query databases, tables, permissions and more from Metabase

Size: 1.22 MB - Last synced: 7 days ago - Pushed: 29 days ago

E218662B/web-api-rest-en-go-lang

Last synced: about 1 year ago - Pushed: 12 months ago

E21A429P/tp_web_rest

Last synced: about 1 year ago - Pushed: 12 months ago

swh/infra/ci-cd/3rdparty/alertmanager-irc-relay

Last synced: 8 months ago - Pushed: 12 months ago

swh/infra/ci-cd/3rdparty/cert-manager-webhook-gandi

Last synced: 8 months ago - Pushed: 12 months ago

guillaume.perreal/coord

Last synced: 12 months ago - Pushed: 12 months ago

radiofrance/dib
An opinionated DAG image builder

Size: 3.64 MB - Last synced: 3 days ago - Pushed: 3 days ago

radiofrance/image-registry-metrics-exporter
Image Registry Metrics Exporter provides metrics about creation and uploading time of images on OCI registry.

Size: 306 KB - Last synced: 3 days ago - Pushed: 7 days ago

betagouv/sealed-secrets Fork of bitnami-labs/sealed-secrets
A Kubernetes controller and tool for one-way encrypted Secrets

Size: 19.2 MB - Last synced: 3 days ago - Pushed: almost 3 years ago

betagouv/vouch-proxy Fork of vouch/vouch-proxy
an SSO and OAuth / OIDC login solution for Nginx using the auth_request module

Size: 5.68 MB - Last synced: 3 days ago - Pushed: over 1 year ago

cea-hpc/fabricmon Fork of dswarbrick/fabricmon
InfiniBand fabric monitoring daemon written in Go

Size: 404 KB - Last synced: 4 days ago - Pushed: 7 months ago

cea-hpc/fleet Fork of coreos/fleet
fleet ties together systemd and etcd into a distributed init system

Size: 13.5 MB - Last synced: 4 days ago - Pushed: over 4 years ago

1024pix/steampipe-plugin-github Fork of turbot/steampipe-plugin-github
Use SQL to instantly query repositories, users, gists and more from GitHub. Open source CLI. No DB required.

Size: 206 KB - Last synced: 7 days ago - Pushed: about 1 year ago

signaux-faibles/opensignauxfaibles Fork of entrepreneur-interet-general/opensignauxfaibles
Plateforme de détection des entreprises fragiles

Size: 36.6 MB - Last synced: 4 days ago - Pushed: 4 months ago

radiofrance/ipahealthcheck_exporter Fork of camptocamp/ipahealthcheck_exporter
Prometheus exporter for exposing ipa-healthcheck tool checks as metrics

Size: 60.5 KB - Last synced: 3 days ago - Pushed: almost 4 years ago

signaux-faibles/wekan-alerter
wekan-alerter

Size: 44.9 KB - Last synced: 4 days ago - Pushed: over 2 years ago

signaux-faibles/IamUpdater
keycloakUpdater pour Signaux-Faibles

Size: 615 KB - Last synced: 4 days ago - Pushed: 12 months ago

signaux-faibles/libwekan

Size: 218 KB - Last synced: 4 days ago - Pushed: 12 months ago

signaux-faibles/goup
Serveur minimaliste pour téléverser des fichiers avec une gestion de droits

Size: 63.1 MB - Last synced: 4 days ago - Pushed: over 2 years ago

signaux-faibles/datapi
datAPI - API des applications web signaux-faibles

Size: 43.1 MB - Last synced: 4 days ago - Pushed: 7 days ago

signaux-faibles/prepare-import
📥 Scripts de préparation à l'importation de données dans le processus d'intégration

Size: 276 KB - Last synced: 4 days ago - Pushed: 5 months ago

pass-culture/pc-monitoring 📦

Size: 176 MB - Last synced: 8 months ago - Pushed: over 3 years ago

capsule/drv

Last synced: 8 months ago - Pushed: 12 months ago

radiofrance/helm-chart-sonarqube Fork of SonarSource/helm-chart-sonarqube

Size: 2.99 MB - Last synced: 8 months ago - Pushed: 10 months ago

web-et-numerique/factory/llle_project/cozy-stack
Fork of cozy-stack https://github.com/cozy/cozy-stack

Last synced: 8 months ago

pocs/dpetit/api-cartographie

Last synced: 8 months ago

csan/csan
CSAN : A marketplace for science

Last synced: 8 months ago

impl-mentation-s105/gestion-de-particule

Last synced: 8 months ago - Pushed: 12 months ago

fantastic-fanfare/adorable_alien

Last synced: 8 months ago