Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 19 of 19 for ReadBuildInfo (0.34 sec)

  1. src/cmd/vendor/golang.org/x/telemetry/internal/upload/run.go

    	if os.IsNotExist(err) {
    		return nil, nil
    	}
    	if err != nil {
    		return nil, err
    	}
    	if !fd.IsDir() {
    		return nil, fmt.Errorf("debug path %q is not a directory", debugDir)
    	}
    	info, ok := debug.ReadBuildInfo()
    	if !ok {
    		return nil, fmt.Errorf("no build info")
    	}
    	year, month, day := time.Now().UTC().Date()
    	goVers := info.GoVersion
    	// E.g.,  goVers:"go1.22-20240109-RC01 cl/597041403 +dcbe772469 X:loopvar"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 21:12:15 UTC 2024
    - 5.5K bytes
    - Viewed (0)
  2. src/cmd/go/testdata/script/mod_outside.txt

    -- needmod/needmod.go --
    //go:generate touch gen.txt
    
    package main
    
    import (
    	"fmt"
    	"os"
    	"runtime/debug"
    
    	_ "example.com/version"
    )
    
    func main() {
    	info, ok := debug.ReadBuildInfo()
    	if !ok {
    		panic("missing build info")
    	}
    	fmt.Fprintf(os.Stdout, "path is %s\n", info.Path)
    	fmt.Fprintf(os.Stdout, "main is %s %s\n", info.Main.Path, info.Main.Version)
    	for _, m := range info.Deps {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 18 15:34:40 UTC 2023
    - 11.2K bytes
    - Viewed (0)
  3. src/cmd/go/scriptconds_test.go

    		return true, nil
    	default:
    		return false, fmt.Errorf("unexpected error reading file when determining case-sensitivity: %w", err)
    	}
    }
    
    func isTrimpath() (bool, error) {
    	info, _ := debug.ReadBuildInfo()
    	if info == nil {
    		return false, errors.New("missing build info")
    	}
    
    	for _, s := range info.Settings {
    		if s.Key == "-trimpath" && s.Value == "true" {
    			return true, nil
    		}
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Feb 21 22:16:54 UTC 2024
    - 7.4K bytes
    - Viewed (0)
  4. src/cmd/go/testdata/script/mod_vendor_auto.txt

    -- $WORK/auto/vendor/example.com/printversion/printversion.go --
    package main
    
    import (
    	"fmt"
    	"os"
    	"runtime/debug"
    
    	_ "example.com/version"
    )
    
    func main() {
    	info, _ := debug.ReadBuildInfo()
    	fmt.Fprintf(os.Stdout, "path is %s\n", info.Path)
    	fmt.Fprintf(os.Stdout, "main is %s %s\n", info.Main.Path, info.Main.Version)
    	for _, m := range info.Deps {
    		fmt.Fprintf(os.Stdout, "using %s %s\n", m.Path, m.Version)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 07 15:21:14 UTC 2024
    - 9.7K bytes
    - Viewed (0)
  5. src/debug/buildinfo/buildinfo.go

    // about how it was built. This includes the Go toolchain version, and the
    // set of modules used (for binaries built in module mode).
    //
    // Build information is available for the currently running binary in
    // runtime/debug.ReadBuildInfo.
    package buildinfo
    
    import (
    	"bytes"
    	"debug/elf"
    	"debug/macho"
    	"debug/pe"
    	"debug/plan9obj"
    	"encoding/binary"
    	"errors"
    	"fmt"
    	"internal/saferio"
    	"internal/xcoff"
    	"io"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 17:58:53 UTC 2024
    - 12.6K bytes
    - Viewed (0)
  6. api/go1.12.txt

    pkg reflect, method (*MapIter) Next() bool
    pkg reflect, method (*MapIter) Value() Value
    pkg reflect, method (Value) MapRange() *MapIter
    pkg reflect, type MapIter struct
    pkg runtime/debug, func ReadBuildInfo() (*BuildInfo, bool)
    pkg runtime/debug, type BuildInfo struct
    pkg runtime/debug, type BuildInfo struct, Deps []*Module
    pkg runtime/debug, type BuildInfo struct, Main Module
    pkg runtime/debug, type BuildInfo struct, Path string
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 02 21:21:53 UTC 2019
    - 13.5K bytes
    - Viewed (0)
  7. src/cmd/vendor/golang.org/x/telemetry/internal/counter/file.go

    var (
    	errNoBuildInfo = errors.New("counter: missing build info")
    	errCorrupt     = errors.New("counter: corrupt counter file")
    )
    
    func (f *file) init(begin, end time.Time) {
    	info, ok := debug.ReadBuildInfo()
    	if !ok {
    		f.err = errNoBuildInfo
    		return
    	}
    	if mode, _ := telemetry.Default.Mode(); mode == "off" {
    		f.err = ErrDisabled
    		return
    	}
    	dir := telemetry.Default.LocalDir()
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 04 16:19:04 UTC 2024
    - 18.2K bytes
    - Viewed (0)
  8. src/cmd/go/internal/load/pkg.go

    // in the binary. setBuildInfo should only be called on a main package with no
    // errors.
    //
    // This information can be retrieved using debug.ReadBuildInfo.
    //
    // Note that the GoVersion field is not set here to avoid encoding it twice.
    // It is stored separately in the binary, mostly for historical reasons.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 28 17:00:51 UTC 2024
    - 120K bytes
    - Viewed (0)
  9. src/cmd/vendor/golang.org/x/tools/internal/stdlib/manifest.go

    		{"Module.Path", Field, 12},
    		{"Module.Replace", Field, 12},
    		{"Module.Sum", Field, 12},
    		{"Module.Version", Field, 12},
    		{"ParseBuildInfo", Func, 18},
    		{"PrintStack", Func, 0},
    		{"ReadBuildInfo", Func, 12},
    		{"ReadGCStats", Func, 1},
    		{"SetGCPercent", Func, 1},
    		{"SetMaxStack", Func, 2},
    		{"SetMaxThreads", Func, 2},
    		{"SetMemoryLimit", Func, 19},
    		{"SetPanicOnFault", Func, 3},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 02:20:05 UTC 2024
    - 534.2K bytes
    - Viewed (0)
Back to top