Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for BoolFlag (0.04 sec)

  1. internal/config/bool-flag_test.go

    	testCases := []struct {
    		flagStr        string
    		expectedResult BoolFlag
    		expectedErr    bool
    	}{
    		{"", BoolFlag(false), true},
    		{"junk", BoolFlag(false), true},
    		{"true", BoolFlag(true), false},
    		{"false", BoolFlag(false), false},
    		{"ON", BoolFlag(true), false},
    		{"OFF", BoolFlag(false), false},
    		{"on", BoolFlag(true), false},
    		{"off", BoolFlag(false), false},
    	}
    
    	for _, testCase := range testCases {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue Jun 01 21:59:40 UTC 2021
    - 3.5K bytes
    - Viewed (0)
  2. internal/config/bool-flag.go

    import (
    	"encoding/json"
    	"fmt"
    	"strconv"
    	"strings"
    )
    
    // BoolFlag - wrapper bool type.
    type BoolFlag bool
    
    // String - returns string of BoolFlag.
    func (bf BoolFlag) String() string {
    	if bf {
    		return "on"
    	}
    
    	return "off"
    }
    
    // MarshalJSON - converts BoolFlag into JSON data.
    func (bf BoolFlag) MarshalJSON() ([]byte, error) {
    	return json.Marshal(bf.String())
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Apr 07 15:10:40 UTC 2022
    - 2.3K bytes
    - Viewed (0)
  3. cmd/main.go

    		Usage: "path to certs directory",
    	},
    	cli.BoolFlag{
    		Name:  "quiet",
    		Usage: "disable startup and info messages",
    	},
    	cli.BoolFlag{
    		Name:  "anonymous",
    		Usage: "hide sensitive information from logging",
    	},
    	cli.BoolFlag{
    		Name:  "json",
    		Usage: "output logs in JSON format",
    	},
    	// Deprecated flag, so its hidden now, existing deployments will keep working.
    	cli.BoolFlag{
    		Name:   "compat",
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Tue Jul 30 22:59:48 UTC 2024
    - 6.5K bytes
    - Viewed (0)
  4. cmd/config-versions.go

    	Version string `json:"version"`
    
    	// S3 API configuration.
    	Credential auth.Credentials `json:"credential"`
    	Region     string           `json:"region"`
    	Worm       config.BoolFlag  `json:"worm"`
    
    	// Storage class configuration
    	StorageClass storageclass.Config `json:"storageclass"`
    
    	// Notification queue configuration.
    	Notify notify.Config `json:"notify"`
    
    	// Logger configuration
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 2.5K bytes
    - Viewed (0)
Back to top