Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 1,260 for semver (0.49 sec)

  1. staging/src/k8s.io/apimachinery/pkg/util/version/version.go

    )
    
    func parse(str string, semver bool) (*Version, error) {
    	parts := versionMatchRE.FindStringSubmatch(str)
    	if parts == nil {
    		return nil, fmt.Errorf("could not parse %q as version", str)
    	}
    	numbers, extra := parts[1], parts[2]
    
    	components := strings.Split(numbers, ".")
    	if (semver && len(components) != 3) || (!semver && len(components) < 2) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Sep 18 19:25:29 UTC 2023
    - 10.5K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apimachinery/pkg/util/version/version_test.go

    	var tests = []struct {
    		version               string
    		semver                bool
    		expectedComponents    []uint
    		expectedMajor         uint
    		expectedMinor         uint
    		expectedPatch         uint
    		expectedPreRelease    string
    		expectedBuildMetadata string
    	}{
    		{
    			version:            "1.0.2",
    			semver:             true,
    			expectedComponents: []uint{1, 0, 2},
    			expectedMajor:      1,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Sep 18 19:25:29 UTC 2023
    - 13.4K bytes
    - Viewed (0)
  3. src/cmd/vendor/golang.org/x/mod/module/module.go

    	cv := semver.Canonical(v)
    	if semver.Build(v) == "+incompatible" {
    		cv += "+incompatible"
    	}
    	return cv
    }
    
    // Sort sorts the list by Path, breaking ties by comparing [Version] fields.
    // The Version fields are interpreted as semantic versions (using [semver.Compare])
    // optionally followed by a tie-breaking suffix introduced by a slash character,
    // like in "v0.0.1/go.mod".
    func Sort(list []Version) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 09 20:17:07 UTC 2024
    - 26.9K bytes
    - Viewed (0)
  4. pkg/apis/resource/structured/namedresources/validation/validation_test.go

    		},
    		"version-bad": {
    			wantFailures: field.ErrorList{field.Invalid(field.NewPath("instances").Index(0).Child("attributes").Index(0).Child("version"), "1.0", "must be a string compatible with semver.org spec 2.0.0")},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 07 21:22:13 UTC 2024
    - 10.4K bytes
    - Viewed (0)
  5. src/cmd/go/internal/modfetch/coderepo.go

    			continue
    		}
    
    		if err := module.CheckPathMajor(v, r.pathMajor); err != nil {
    			if r.codeDir == "" && r.pathMajor == "" && semver.Major(v) > "v1" {
    				incompatible = append(incompatible, v)
    			}
    			continue
    		}
    
    		list = append(list, v)
    	}
    	semver.Sort(list)
    	semver.Sort(incompatible)
    
    	return r.appendIncompatibleVersions(ctx, tags.Origin, list, incompatible)
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun Apr 14 18:50:24 UTC 2024
    - 38.4K bytes
    - Viewed (0)
  6. src/cmd/go/internal/modfetch/codehost/codehost.go

    // in the Tags method's Origin calculation.
    // We can safely ignore tags that are not look like pseudo-versions,
    // because ../coderepo.go's (*codeRepo).Versions ignores them too.
    // We can also ignore non-semver tags, but we have to include semver
    // tags with extra suffixes, because the pseudo-version base finder uses them.
    func isOriginTag(tag string) bool {
    	// modfetch.(*codeRepo).Versions uses Canonical == tag,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun Apr 14 18:50:24 UTC 2024
    - 12.8K bytes
    - Viewed (0)
  7. src/cmd/go/internal/modfetch/proxy.go

    	for _, line := range allLine {
    		f := strings.Fields(line)
    		if len(f) >= 1 && semver.IsValid(f[0]) && strings.HasPrefix(f[0], prefix) && !module.IsPseudoVersion(f[0]) {
    			list = append(list, f[0])
    		}
    	}
    	p.listLatestOnce.Do(func() {
    		p.listLatest, p.listLatestErr = p.latestFromList(ctx, allLine)
    	})
    	semver.Sort(list)
    	return &Versions{List: list}, nil
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Nov 03 15:21:05 UTC 2023
    - 13K bytes
    - Viewed (0)
  8. src/cmd/go/internal/modfetch/cache.go

    		// validation criteria, for example if we are saving the result of
    		// m@master as m@pseudo-version.
    		clean := *info
    		info = &clean
    		o := *info.Origin
    		info.Origin = &o
    
    		// Tags never matter if you are starting with a semver version,
    		// as we would be when finding this cache entry.
    		o.TagSum = ""
    		o.TagPrefix = ""
    		// Ref doesn't matter if you have a pseudoversion.
    		if module.IsPseudoVersion(info.Version) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 03 18:15:22 UTC 2024
    - 24.7K bytes
    - Viewed (0)
  9. src/cmd/vendor/golang.org/x/mod/modfile/rule.go

    		return lineLess(li, lj)
    	}
    	// An exclude specification has two tokens: ModulePath and Version.
    	// Compare module path by string order and version by semver rules.
    	if pi, pj := li.Token[0], lj.Token[0]; pi != pj {
    		return pi < pj
    	}
    	return semver.Compare(li.Token[1], lj.Token[1]) < 0
    }
    
    // lineRetractLess returns whether li should be sorted before lj for lines in
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 18:34:56 UTC 2024
    - 46.5K bytes
    - Viewed (0)
  10. src/cmd/go/internal/modload/query.go

    	if (err == nil && qm.canStat) || err == errRevQuery {
    		// Direct lookup of a commit identifier or complete (non-prefix) semantic
    		// version.
    
    		// If the identifier is not a canonical semver tag — including if it's a
    		// semver tag with a +metadata suffix — then modfetch.Stat will populate
    		// info.Version with a suitable pseudo-version.
    		info, err := repo.Stat(ctx, query)
    		if err != nil {
    			queryErr := err
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Dec 11 22:29:11 UTC 2023
    - 44.7K bytes
    - Viewed (0)
Back to top