goutils

module
v0.0.0-...-ad3f877 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2023 License: Apache-2.0

README

goutils

Collection of golang utilities

Usage

  1. Simple utility to start HTTP Server
  2. Log handler
  3. Environment variable reader
  4. Generates application scafold
  5. Random number generator

Build

Create a Golang microservice

# example usage
goutils create-app \
    --type=go-grpc \
    --name=hello \
    --fqdn-name=github.com/finiteloopme/demo/hello \
    --output=hello

Configure basic build

cd hello
# Initiatlise basic Golang module
make create-module
# Generate gRPC code
make grpc-codegen
# Tidy up all the dependencies
make fmt-deps

Directories

Path Synopsis
pkg
codegen
Create three types of Go modules 1.
Create three types of Go modules 1.
gcp
grpc
Simple utility to start a gRPC Service Consumer should: 1.
Simple utility to start a gRPC Service Consumer should: 1.
http
Simple utility to start HTTP Server The server will start serving files from the current working directory If index.html doesn't exist, it will create a simple handler at / Call: StartHTTPServer()
Simple utility to start HTTP Server The server will start serving files from the current working directory If index.html doesn't exist, it will create a simple handler at / Call: StartHTTPServer()
io
Create directory if one doesn't exist
Create directory if one doesn't exist
log
A simple log utility.
A simple log utility.
os

Jump to

Keyboard shortcuts

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