You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: gin.go
    path of file: ./repos/eagle/cmd/protoc-gen-go-gin
    
    the code of the file until where you have to start completion: package main

import (
	"fmt"
	"net/http"
	"regexp"
	"strings"

	"google.golang.org/genproto/googleapis/api/annotations"
	"google.golang.org/protobuf/compiler/protogen"
	"google.golang.org/protobuf/proto"
	"google.golang.org/protobuf/types/descriptorpb"
)

const (
	contextPackage     = protogen.GoImportPath("context")
	ginPackage         = protogen.GoImportPath("github.com/gin-gonic/gin")
	metadataPackage    = protogen.GoImportPath("google.golang.org/grpc/metadata")
	eagleAppPackage    = protogen.GoImportPath("github.com/go-eagle/eagle/pkg/app")
	errCodePackage     = protogen.GoImportPath("github.com/go-eagle/eagle/pkg/errcode")
	deprecationComment = "// Deprecated: Do not use."
)

var methodSets = make(map[string]int)

// generateFile
    
func generateFile(gen *protogen.Plugin, file *protogen.File) *protogen.GeneratedFile {
	if len(file.Services) == 0 {
		return nil
	}
	filename := file.GeneratedFilenamePrefix + "_gin.pb.go"
	g := gen.NewGeneratedFile(filename, file.GoImportPath)
	g.P("// Code generated protoc-gen-go-gin. DO NOT EDIT.")
	g.P(fmt.Sprintf("// protoc-gen-go-gin %s", version))
	g.P()
	g.P("package ", file.GoPackageName)
	g.P()
	g.P("// This is a compile-time assertion to ensure that this generated file")
	g.P("// is compatible with the eagle package it is being compiled against.")
	g.P()
	g.P("// ", contextPackage.Ident(""))
	g.P("// ", metadataPackage.Ident(""))
	g.P("// ", ginPackage.Ident(""), eagleAppPackage.Ident(""), errCodePackage.Ident(""))
	g.P()

	for _, service := range file.Services {
		genService(gen, file, g, service)
	}
	return g
}