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: vcs.go
    path of file: ./repos/govendor/vcs
    
    the code of the file until where you have to start completion: // Copyright 2015 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

// package vcs gets version control information from the file system.
package vcs

import (
	"path/filepath"
	"sync"
	"time"

	"github.com/kardianos/govendor/internal/pathos"
)

// VcsInfo returns information about a given repo.
type VcsInfo struct {
	Dirty        bool
	Revision     string
	RevisionTime *time.Time
}

// Vcs represents a version 
    
func FindVcs(root, packageDir string) (info *VcsInfo, err error) {
	if !filepath.IsAbs(root) {
		return nil, nil
	}
	if !filepath.IsAbs(packageDir) {
		return nil, nil
	}
	path := packageDir
	for i := 0; i <= looplimit; i++ {
		for _, vcs := range vcsRegistry {
			info, err = vcs.Find(path)
			if err != nil {
				return nil, err
			}
			if info != nil {
				return info, nil
			}
		}

		nextPath := filepath.Clean(filepath.Join(path, ".."))
		// Check for root.
		if nextPath == path {
			return nil, nil
		}
		if !pathos.FileHasPrefix(nextPath, root) {
			return nil, nil
		}
		path = nextPath
	}
	panic("loop limit")
}