See how a minor change to your commit message style can make a difference. Examples
Have a look at CLI util git-conventional-commits to ensure this conventions and generate changelogs
package tracing | |
import ( | |
"context" | |
"fmt" | |
"os" | |
"sync" | |
"github.com/labstack/echo/v4" | |
"github.com/labstack/echo/v4/middleware" |
See how a minor change to your commit message style can make a difference. Examples
Have a look at CLI util git-conventional-commits to ensure this conventions and generate changelogs
GOCMD=go | |
GOTEST=$(GOCMD) test | |
GOVET=$(GOCMD) vet | |
BINARY_NAME=example | |
VERSION?=0.0.0 | |
SERVICE_PORT?=3000 | |
DOCKER_REGISTRY?= #if set it should finished by / | |
EXPORT_RESULT?=false # for CI please set EXPORT_RESULT to true | |
GREEN := $(shell tput -Txterm setaf 2) |
GOCMD=go | |
GOTEST=$(GOCMD) test | |
GOVET=$(GOCMD) vet | |
BINARY_NAME=example | |
VERSION?=0.0.0 | |
SERVICE_PORT?=3000 | |
DOCKER_REGISTRY?= #if set it should finished by / | |
EXPORT_RESULT?=false # for CI please set EXPORT_RESULT to true | |
GREEN := $(shell tput -Txterm setaf 2) |
// NewWrapResponseWriter wraps an http.ResponseWriter, returning a proxy that allows you to | |
// hook into various parts of the response process. | |
func NewWrapResponseWriter(w http.ResponseWriter, protoMajor int) WrapResponseWriter { | |
_, fl := w.(http.Flusher) | |
bw := basicWriter{ResponseWriter: w} | |
if protoMajor == 2 { | |
_, ps := w.(http.Pusher) | |
if fl && ps { |
type AwsRegion struct { | |
Region string | |
Location string | |
Code string | |
A1 string | |
} | |
var ( | |
regions = []AwsRegion{ |
package main | |
import ( | |
"context" | |
"flag" | |
image2 "github.com/aquasecurity/fanal/artifact/image" | |
"github.com/aquasecurity/fanal/cache" | |
"github.com/aquasecurity/fanal/image" | |
dbTypes "github.com/aquasecurity/trivy-db/pkg/types" | |
"github.com/aquasecurity/trivy/pkg/log" |
#!/usr/bin/env bash | |
set -e | |
# Proxy minikube to localhost on arbitrary port: | |
kubectl proxy --port=8080 & | |
sleep 3 | |
# Now swagger.json is available at localhost:12345/openapi/v2 | |
# Save to /tmp/temp/json and serve with e.g. docker swagger-ui container | |
curl http://localhost:8080/openapi/v2 > /tmp/temp.json | |
docker container run -d -p 9999:8080 -e SWAGGER_JSON=/var/specs/temp.json -v /tmp/temp.json:/var/specs/temp.json swaggerapi/swagger-ui |
while IFS= read -r config; do | |
a=($(echo $config | tr '=' "\n")) | |
if ls *$a[2]* 1> /dev/null 2>&1; then | |
echo "files do exist" | |
else | |
youtube-dl -x --audio-format mp3 $config | |
fi | |
done< <(jq -c -r '.[]' < 32file.json) |