Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 11 for ReplaceAllString (0.23 sec)

  1. operator/cmd/mesh/profile-dump_test.go

    			if err != nil {
    				t.Fatal(err)
    			}
    			// installPackagePath may change, we will remove it for consistent output
    			got = installPackagePathRegex.ReplaceAllString(got, "")
    
    			if refreshGoldenFiles() {
    				t.Logf("Refreshing golden file for %s", outPath)
    				if err := os.WriteFile(outPath, []byte(got), 0o644); err != nil {
    					t.Error(err)
    				}
    			}
    
    Go
    - Registered: Wed Mar 20 22:53:08 GMT 2024
    - Last Modified: Thu Jan 20 11:44:25 GMT 2022
    - 3.7K bytes
    - Viewed (0)
  2. tests/sql_builder_test.go

    	actually = updatedAtRe.ReplaceAllString(actually, `"updated_at"=?`)
    	expected = updatedAtRe.ReplaceAllString(expected, `"updated_at"=?`)
    
    	// ignore RETURNING "id" (only in PostgreSQL)
    	returningRe := regexp.MustCompile(`(?i)RETURNING "id"`)
    	actually = returningRe.ReplaceAllString(actually, ``)
    	expected = returningRe.ReplaceAllString(expected, ``)
    
    	actually = strings.TrimSpace(actually)
    Go
    - Registered: Sun Apr 28 09:35:09 GMT 2024
    - Last Modified: Fri Jan 12 08:42:21 GMT 2024
    - 16.7K bytes
    - Viewed (0)
  3. internal/config/cache/remote.go

    var etagRegex = regexp.MustCompile("\"*?([^\"]*?)\"*?$")
    
    // canonicalizeETag returns ETag with leading and trailing double-quotes removed,
    // if any present
    func canonicalizeETag(etag string) string {
    	return etagRegex.ReplaceAllString(etag, "$1")
    }
    
    // Init - populates the input values, initializes CondCheck
    // before sending the request remotely.
    func (r *CondCheck) Init(bucket, object string, header http.Header) {
    	r.Key = object
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Wed Nov 22 21:46:17 GMT 2023
    - 3.7K bytes
    - Viewed (0)
  4. schema/utils.go

    	}
    	return
    }
    
    func removeSettingFromTag(tag reflect.StructTag, names ...string) reflect.StructTag {
    	for _, name := range names {
    		tag = reflect.StructTag(regexp.MustCompile(`(?i)(gorm:.*?)(`+name+`(:.*?)?)(;|("))`).ReplaceAllString(string(tag), "${1}${5}"))
    	}
    	return tag
    }
    
    func appendSettingFromTag(tag reflect.StructTag, value string) reflect.StructTag {
    	t := tag.Get("gorm")
    	if strings.Contains(t, value) {
    		return tag
    	}
    Go
    - Registered: Sun Apr 28 09:35:09 GMT 2024
    - Last Modified: Sat Aug 19 13:35:14 GMT 2023
    - 5.5K bytes
    - Viewed (0)
  5. logger/sql.go

    				if len(vars) > idx {
    					newSQL.WriteString(vars[idx])
    					idx++
    					continue
    				}
    			}
    			newSQL.WriteByte(v)
    		}
    
    		sql = newSQL.String()
    	} else {
    		sql = numericPlaceholder.ReplaceAllString(sql, "$$$1$$")
    
    		sql = numericPlaceholderRe.ReplaceAllStringFunc(sql, func(v string) string {
    			num := v[1 : len(v)-1]
    			n, _ := strconv.Atoi(num)
    
    			// position var start from 1 ($1, $2)
    			n -= 1
    Go
    - Registered: Sun Apr 28 09:35:09 GMT 2024
    - Last Modified: Thu Mar 21 08:00:02 GMT 2024
    - 5K bytes
    - Viewed (0)
  6. schema/naming.go

    	result := strings.ReplaceAll(strings.Title(strings.ReplaceAll(name, "_", " ")), " ", "")
    	for _, initialism := range commonInitialisms {
    		result = regexp.MustCompile(strings.Title(strings.ToLower(initialism))+"([A-Z]|$|_)").ReplaceAllString(result, initialism+"$1")
    	}
    	return result
    Go
    - Registered: Sun Apr 28 09:35:09 GMT 2024
    - Last Modified: Mon Oct 30 09:15:49 GMT 2023
    - 5.2K bytes
    - Viewed (0)
  7. src/archive/zip/reader_test.go

    0000190 00 00 00 00 00 00 00 00 00 00 00 72 2f 72 2e 7a
    00001a0 69 70 50 4b 05 06 00 00 00 00 01 00 01 00 35 00
    00001b0 00 00 6d 01 00 00 00 00`
    	s = regexp.MustCompile(`[0-9a-f]{7}`).ReplaceAllString(s, "")
    	s = regexp.MustCompile(`\s+`).ReplaceAllString(s, "")
    	b, err := hex.DecodeString(s)
    	if err != nil {
    		panic(err)
    	}
    	return b
    }
    
    func returnRecursiveZip() (r io.ReaderAt, size int64) {
    	b := rZipBytes()
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Wed Mar 27 18:23:49 GMT 2024
    - 55.3K bytes
    - Viewed (0)
  8. cmd/object-handlers-common.go

    }
    
    // canonicalizeETag returns ETag with leading and trailing double-quotes removed,
    // if any present
    func canonicalizeETag(etag string) string {
    	return etagRegex.ReplaceAllString(etag, "$1")
    }
    
    // isETagEqual return true if the canonical representations of two ETag strings
    // are equal, false otherwise
    func isETagEqual(left, right string) bool {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Tue Apr 09 08:17:49 GMT 2024
    - 14.6K bytes
    - Viewed (0)
  9. src/cmd/api/main_test.go

    	}
    	return s
    }
    
    var spaceParensRx = regexp.MustCompile(` \(\S+?\)`)
    
    func featureWithoutContext(f string) string {
    	if !strings.Contains(f, "(") {
    		return f
    	}
    	return spaceParensRx.ReplaceAllString(f, "")
    }
    
    // portRemoved reports whether the given port-specific API feature is
    // okay to no longer exist because its port was removed.
    func portRemoved(feature string) bool {
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Tue Apr 09 20:48:51 GMT 2024
    - 31.4K bytes
    - Viewed (0)
  10. cmd/admin-handlers.go

    		re := regexp.MustCompile(`^(.*minio\s+server\s+)(--[^\s]+\s+[^\s]+\s+)*(.*)`)
    
    		// stays unchanged in the anonymized version
    		cmdLineWithoutPools := re.ReplaceAllString(cmdLine, `$1$2`)
    
    		// to be anonymized
    		poolsArgs := re.ReplaceAllString(cmdLine, `$3`)
    		var anonPools []string
    
    		if !(strings.Contains(poolsArgs, "{") && strings.Contains(poolsArgs, "}")) {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sun Apr 21 11:43:18 GMT 2024
    - 97.3K bytes
    - Viewed (2)
Back to top