Documentation
¶
Index ¶
- Constants
- Variables
- func DeleteSentenceFromFile(filePath, searchString string) error
- func FilterSentenceFromFile(fsys fs.FS, filePath string, searchString string) ([]byte, error)
- func GetHomeDir() string
- func GetWords(fsys fs.FS, filename string, numberOfLines int) ([]string, error)
- func HttpGetDictionary[T any](parser func(io.Reader, int) (T, error), url string) (T, error)
- func MoveSentenceToFile(trashPath, wordsPath, sentence string) error
- func OverrideFile(data []byte, filepath string) error
- func PrintGreen(out io.Writer, message string)
- func PrintRed(out io.Writer, message string)
- func PrintWithColor(out io.Writer, message, color string)
- func WriteFile(sentence, filepath string) error
- type File
- type IFile
- type UserFilePath
Constants ¶
View Source
const ( ColorReset = "\033[0m" ColorRed = "\033[31m" ColorGreen = "\033[32m" ColorCyan = "\033[36m" ColorPink = "\033[38;5;205m" ColorGold = "\033[38;2;243;134;48m" )
Variables ¶
View Source
var NotFoundError = errors.New("Info not found while fetching data")
Functions ¶
func DeleteSentenceFromFile ¶
func FilterSentenceFromFile ¶
func GetHomeDir ¶
func GetHomeDir() string
func HttpGetDictionary ¶
func MoveSentenceToFile ¶
func OverrideFile ¶
func PrintGreen ¶
func PrintWithColor ¶
Types ¶
type UserFilePath ¶
Click to show internal directories.
Click to hide internal directories.