tools

package module
v0.0.0-...-6c4a57a Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2021 License: MIT Imports: 11 Imported by: 0

README

Logo

Golang Tools

Just import and use!

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Exists

func Exists(filePath string) (bool, error)

Exists check a file exists

func FileContains

func FileContains(filePath string, str string) (bool, error)

FileContains check that string exist in file

func FileLinesCounter

func FileLinesCounter(filePath string) (int, error)

FileLinesCounter counts lines of file

func FileMix

func FileMix(filePath string, start string, end string, betweenWords string) (string, error)

Synonym return combine text from file

func FileMixRegExp

func FileMixRegExp(filePath string, start string, end string, betweenWords string) (string, error)

FileMixRegExp return combine text from file

func Flush

func Flush(filePath string, str string) error

Flush append data to file

func GetStringInBetween

func GetStringInBetween(str string, homeChar string, endChar string) (string, bool, error)

GetStringInBetween return string between two characters

func Random

func Random(min int, max int) int

Random return random numbers in rage

func RandomFileLine

func RandomFileLine(filePath string) (string, error)

RandomFileLine return random line in file

func SpecifyLineByNumber

func SpecifyLineByNumber(filePath string, specifyLine int) (string, error)

SpecifyLineByNumber return specific text of line in file

func SpecifyLineByText

func SpecifyLineByText(filePath string, str string) (string, error)

SpecifyLineByText return specific text of line in file

func StringMix

func StringMix(text string, start string, end string, betweenWords string) (string, error)

Synonym return combine text from string

func StringMixWithRegExp

func StringMixWithRegExp(text string, start string, end string, betweenWords string) string

StringMixWithRegExp works better with

Types

This section is empty.

Jump to

Keyboard shortcuts

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