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: main.go
    path of file: ./repos/td/cmd/dlkey
    
    the code of the file until where you have to start completion: // Binary dlkey extracts public keys from remote repo.
package main

import (
	"flag"
	"fmt"
	"io"
	"net/http"
	"net/url"
	"os"
	"path"

	"github.com/gotd/td/keyparser"
)

func main() {
	var (
		name   = flag.String("f", "mtproto_dc_options.cpp", "file name to download")
		base   = flag.String("base", "https://raw.githubusercontent.com/telegramdesktop/tdesktop", "base url")
		branch = flag.String("branch", "dev", "branch to use")
		dir    = flag.String("dir", "Telegram/SourceFiles/mtproto/", "directory")
		out    = flag.String("o", "", "output file name (blank to stdout)")
	)
	flag.Parse()

	u, err := url.Parse(*base)
	if err != nil {
		panic(err)
	}

	u.Path = path.Join(u.Path, *branch, *dir, *name)

	res, err := http.Get(u.String())
	if err != nil {
		panic(err)
	}
	defer func() { _ = res.Body.Close() }()
	if res.StatusCode/100 != 2 {
		panic(fmt.Sprintf("status code %d", res.StatusCode))
	}

	var outWriter io.Writer = os.Stdout
	if *out
    
func main() {
	var (
		name   = flag.String("f", "mtproto_dc_options.cpp", "file name to download")
		base   = flag.String("base", "https://raw.githubusercontent.com/telegramdesktop/tdesktop", "base url")
		branch = flag.String("branch", "dev", "branch to use")
		dir    = flag.String("dir", "Telegram/SourceFiles/mtproto/", "directory")
		out    = flag.String("o", "", "output file name (blank to stdout)")
	)
	flag.Parse()

	u, err := url.Parse(*base)
	if err != nil {
		panic(err)
	}

	u.Path = path.Join(u.Path, *branch, *dir, *name)

	res, err := http.Get(u.String())
	if err != nil {
		panic(err)
	}
	defer func() { _ = res.Body.Close() }()
	if res.StatusCode/100 != 2 {
		panic(fmt.Sprintf("status code %d", res.StatusCode))
	}

	var outWriter io.Writer = os.Stdout
	if *out != "" {
		w, err := os.Create(*out)
		if err != nil {
			panic(err)
		}
		defer func() {
			if err := w.Close(); err != nil {
				panic(err)
			}
		}()
		outWriter = w
	}

	if err := keyparser.Extract(res.Body, outWriter); err != nil {
		panic(err)
	}
}