The one-stop shop for most common Go functions

Pandati

Docker image build. GitHub release (latest by date) Go Reference

The one stop shop for most common Go functions

Table of contents

Purpose of the project

Keeping things DRY for your projects. Set of most popular and frequently used helper functions making it easier to focus on the logic you want to implement rather than re-inventing the wheel ( and spending precious time going through StackOverflow ).

Available helpers

Class Function Description
Errors CheckForError(err error, msg ...string) (string) Checks for error and returns pre-formatted message with stack trace
Errors Trace() string Returns a formatted stack trace
Maps FlattenMap(nested map[string]interface{}, opts *FlattenOptions) (m map[string]interface{}, err error) Flattens provided map using customisation options
Maps UnflattenMap(flat map[string]interface{}, opts *FlattenOptions) (nested map[string]interface{}, err error) Unflattens provided map into nested map using customisation options
Slices ExistsInSlice(slice interface{}, value interface{}) bool Checks if value exists in slice
Slices RemoveFromSlice(slice interface{}, value interface{}) Removes value from slice
Slices RemoveFromSliceByIndex(slice interface{}, index int) Removes value from slice by index
Checks IsZero(v interface{}) bool Checks if value of anything passed is zero / empty / nil

Contributing

If you have any suggestions or want to contribute to the project, please open an issue or create a pull request. Pull requests should contain test cases and documentation describing the added functionality.

Name of the project

It's one of the sweet names I use to call my wife. She's always full of ideas and able to help with absolutely everything.

Similar Resources

A fully Go userland with Linux bootloaders! u-root can create a one-binary root file system (initramfs) containing a busybox-like set of tools written in Go.

u-root Description u-root embodies four different projects. Go versions of many standard Linux tools, such as ls, cp, or shutdown. See cmds/core for m

Dec 29, 2022

📚 Clone all your repositories from GitHub with one command!

An utility to clone easily all your repositories from GitHub. The process is done concurrently so it is quite fast.

Apr 6, 2022

A super simple Lodash like utility library with essential functions that empowers the development in Go

A super simple Lodash like utility library with essential functions that empowers the development in Go

A simple Utility library for Go Go does not provide many essential built in functions when it comes to the data structure such as slice and map. This

Jan 4, 2023

This is an open source project for commonly used functions for the Go programming language.

Common Functions This is an open source project for commonly used functions for the Go programming language. This package need = go 1.3 Code Conventi

Jan 8, 2023

randstr is a module that contains functions for generating random strings.

randstr is a module that contains functions for generating random strings. The functions in this module uses the crypto/rand package. Installa

Nov 13, 2021

Go linter that warns about number of arguments in functions.

argslen linter Argslen is a linter that checks for long list of argument in functions. The default limit is 5 (maxArguments) and skip the test files (

Sep 17, 2022

Utility functions for work with the Kubernetes Go-Client

go-k8s-utils This repository contains utils for the work with Kubernetes, in specific with the go-client library. Testing This package contains utils

Dec 14, 2022

Extended library functions using generics in Go.

Just few extended standard library functions for Golang using generics.

Dec 16, 2021

Simple library to handle ANSI functions and parsing of color formatting strings

Emerald A basic color library for use in my Go projects, built on top of mgutz/ansi. Package ansi is a small, fast library to create ANSI colored stri

Oct 28, 2022
Helper functions for common scenarios, using Go generics.

zeroflucs generics When writing Go code for Go 1.17 or below, we've all written more than our fair share of methods to check "does this slice contain

Feb 18, 2022
Govalid is a data validation library that can validate most data types supported by golang

Govalid is a data validation library that can validate most data types supported by golang. Custom validators can be used where the supplied ones are not enough.

Apr 22, 2022
sigurls is a reconnaissance tool, it fetches URLs from AlienVault's OTX, Common Crawl, URLScan, Github and the Wayback Machine.

sigurls is a reconnaissance tool, it fetches URLs from AlienVault's OTX, Common Crawl, URLScan, Github and the Wayback Machine. DiSCLAIMER: fe

May 22, 2021
a decision & trigger framework backed by Google's Common Expression Language used in graphikDB

a decision & trigger framework backed by Google's Common Expression Language used in graphikDB

Nov 15, 2022
common tools for golang

utils common tools for golang package main

Dec 27, 2021
redis-util business-friendly encapsulation of redis operations, such as the common cache set get operation

redis-util 方便业务使用的redis操作封装,比如常见的缓存set get操作, 一行代码搞定,不像开源库需要写好多行 使用方法

Oct 22, 2021
Common utils that need in every development

Utils modules Common utils that need in every development Modules Conversion String IntToString(num int) string Int8ToString(num int8) string Int16ToS

Nov 5, 2021
With Pasteback you can store common terms and paste them back to clipboard

Pasteback With Pasteback you can store common terms and paste them back to clipboard when needed. There is one central spot to put every string into y

Nov 22, 2021
safe and easy casting from one type to another in Go

cast Easy and safe casting from one type to another in Go Don’t Panic! ... Cast What is Cast? Cast is a library to convert between different go types

Jan 1, 2023
Go implementation Welford’s method for one-pass variance computation

Welford - Online method of calculating variance and standard deviation Go implementation Welford’s method for one-pass variance computation with D. H.

Jan 6, 2023