<commit_before>// Copyright 2015 The Cockroach Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
// implied. See the License for the specific language governing
// permissions and limitations under the License.
//
// Author: <NAME> (<EMAIL>)

package util

import (
	"fmt"
	"runtime"
)

// const char* compilerVersion() {
// #if defined(__clang__)
// 	return __VERSION__;
// #elif defined(__GNUC__) || defined(__GNUG__)
// 	return "gcc " __VERSION__;
// #else
// 	return "unknown";
// #endif
// }
import "C"

var (
	// These variables are initialized via the linker -X flag in the
	// top-level Makefile when compiling release binaries.
	buildTag         string // Tag of this build (git describe)
	buildTime        string // Build time in UTC (year/month/day hour:min:sec)
	buildDeps        string // Git SHAs of dependencies
	buildCgoCompiler = C.GoString(C.compilerVersion())
	buildPlatform    = fmt.Sprintf("%s %s", runtime.GOOS, runtime.GOARCH)
)

// GetBuildInfo ...
func GetBuildInfo() BuildInfo {
	return BuildInfo{
		GoVersion:   runtime.Version(),
		Tag:         buildTag,
		Time:        buildTime,
		Deps:        buildDeps,
		CgoCompiler: buildCgoCompiler,
		Platform:    buildPlatform,<commit_msg>util: make 'unknown' compiler name more specific<commit_after>// Copyright 2015 The Cockroach Authors.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
// implied. See the License for the specific language governing
// permissions and limitations under the License.
//
// Author: <NAME> (<EMAIL>)

package util

import (
	"fmt"
	"runtime"
)

// const char* compilerVersion() {
// #if defined(__clang__)
// 	return __VERSION__;
// #elif defined(__GNUC__) || defined(__GNUG__)
// 	return "gcc " __VERSION__;
// #else
// 	return "non-gcc, non-clang (or an unrecognized version)";
// #endif
// }
import "C"

var (
	// These variables are initialized via the linker -X flag in the
	// top-level Makefile when compiling release binaries.
	buildTag         string // Tag of this build (git describe)
	buildTime        string // Build time in UTC (year/month/day hour:min:sec)
	buildDeps        string // Git SHAs of dependencies
	buildCgoCompiler = C.GoString(C.compilerVersion())
	buildPlatform    = fmt.Sprintf("%s %s", runtime.GOOS, runtime.GOARCH)
)

// GetBuildInfo ...
func GetBuildInfo() BuildInfo {
	return BuildInfo{
		GoVersion:   runtime.Version(),
		Tag:         buildTag,
		Time:        buildTime,
		Deps:        buildDeps,
		CgoCompiler: buildCgoCompiler,
		Platform:    buildPlatform,
{'fraction_non_alphanumeric': 0.11215519854501364, 'fraction_numerical': 0.004849954531676266, 'mean_word_length': 3.1666666666666665, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3164193', 'n_tokens_mistral': 990, 'n_tokens_neox': 949, 'n_words': 362}