godiff

package
v0.0.0-...-fe6e0c2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 29, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Overview

* 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. * * Copyright 2023 Red Hat, Inc. *

* 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. * * Copyright 2023 Red Hat, Inc. *

* 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. * * Copyright 2023 Red Hat, Inc. *

Index

Constants

This section is empty.

Variables

View Source
var Green = "\033[32m"
View Source
var Red = "\033[31m"
View Source
var Reset = "\033[0m"

Functions

func CleanIniSections

func CleanIniSections(config string) string

func CompareFiles

func CompareFiles(origin string, dest string, print bool, verbose bool, iniFilters []string) ([]string, error)

func CompareFilesFromRemote

func CompareFilesFromRemote(origin string, dest string, originRemoteCmd string, destRemoteCmd string, verbose bool) error

func CompareIni

func CompareIni(rawdata1 []byte, rawdata2 []byte, origin string, dest string, verbose bool, iniFilters []string) ([]string, error)

func CompareJSON

func CompareJSON(orgData, destData interface{}, path string) ([]string, error)

func CompareJSONFiles

func CompareJSONFiles(origin []byte, dest []byte) ([]string, error)

func CompareRawData

func CompareRawData(rawdata1 []byte, rawdata2 []byte, origin string, dest string) ([]string, error)

func CompareYAML

func CompareYAML(origin []byte, dest []byte) ([]string, error)

func FilesEqual

func FilesEqual(file1, file2 string) (bool, error)

func GetConfigFromRemote

func GetConfigFromRemote(remoteCmd string, configPath string) ([]byte, error)

func PrintReport

func PrintReport(report []string) error

func WriteReport

func WriteReport(content []string, reportPath string) error

Types

type GoDiffDataStruct

type GoDiffDataStruct struct {
	Origin      string
	Destination string
	// contains filtered or unexported fields
}

func (*GoDiffDataStruct) Process

func (p *GoDiffDataStruct) Process(dir1 string, dir2 string) error

func (*GoDiffDataStruct) ProcessDirectories

func (p *GoDiffDataStruct) ProcessDirectories(reverse bool) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL