Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/OpenSLO/oslo
/ functions
Functions
25 in github.com/OpenSLO/oslo
⨍
Functions
25
◇
Types & classes
0
↓ 5 callers
Function
readRawSchema
readRawSchema reads raw OpenSLO schema from file path, HTTP address or stdin (path "-") to a byte slice.
internal/files/reader.go:49
↓ 3 callers
Function
Discover
Discover returns all file paths that come from file paths provided as the argument. Return directly if they are standard files. For directories list a
internal/files/discover.go:15
↓ 3 callers
Function
printStderr
(err any)
internal/cli/validate.go:75
↓ 2 callers
Function
Format
Format formats multiple files and writes it to the provided writer, separated with "---".
internal/files/format.go:11
↓ 2 callers
Function
NewRootCmd
(version string)
internal/cli/root.go:7
↓ 2 callers
Function
indentString
(s string, i int)
internal/cli/validate.go:66
↓ 2 callers
Function
isStdin
(p string)
internal/files/reader.go:67
↓ 2 callers
Function
isURL
(p string)
internal/files/reader.go:71
↓ 2 callers
Function
readObjectsFromRawData
readObjectsFromRawData reads [openslo.Object] from a byte slice.
internal/files/reader.go:40
↓ 2 callers
Function
registerFileRelatedFlags
registerFileRelatedFlags registers flags --file | -f and --recursive | -R for command passed as the argument and make them required.
internal/cli/flags.go:7
↓ 1 callers
Function
NewFmtCmd
NewFmtCmd returns a new command for formatting a file.
internal/cli/fmt.go:13
↓ 1 callers
Function
NewValidateCmd
NewValidateCmd returns a new cobra.Command for the validate command.
internal/cli/validate.go:19
↓ 1 callers
Function
ReadObjects
ReadObjects reads [openslo.Object] from the provided sources. It returns a map where the key is a file path and the value are objects read form this f
internal/files/reader.go:19
↓ 1 callers
Function
format
()
internal/scripts/format-cspell-config.js:11
↓ 1 callers
Function
formatFile
formatFile formats a single formatFile and writes it to the provided writer.
internal/files/format.go:26
↓ 1 callers
Function
getBuildVersion
(version string)
cmd/oslo/main.go:20
↓ 1 callers
Function
getRuntimeVersion
()
cmd/oslo/main.go:27
↓ 1 callers
Function
isJSONBuffer
isJSONBuffer scans the provided buffer, looking for an open brace indicating this is JSON. While a simple list like ["a", "b", "c"] is still a valid J
internal/files/reader.go:80
↓ 1 callers
Function
readObjectsFromSource
(source string)
internal/files/reader.go:31
Function
FindModuleRoot
FindModuleRoot finds the root of the current module. It does so by looking for a go.mod file in the current working directory.
internal/pathutils/pathutils.go:16
Function
TestDiscoverFilePaths
TestDiscoverFilePaths tests it on real filesystem, content of those file doesn't matter, thus they're empty.
internal/files/discover_test.go:14
Function
TestFormatFiles
(t *testing.T)
internal/files/format_test.go:14
Function
TestNewRootCmd
nolint:lll
internal/cli/root_test.go:11
Function
TestReadConf
(t *testing.T)
internal/files/reader_test.go:16
Function
main
()
cmd/oslo/main.go:15