// create creates a new copy of repo in dir.
// The parent of dir must exist; dir must not.
778422
func (v *vcsCmd) create(dir, repo string) error {
	return v.run(".", v.createCmd, "dir", dir, "repo", repo)
}
1005599
func (dfs *DistributedFilesystem) Create(tenantID string) error {
	glog.V(1).Infof("Creating volume for %s", tenantID)
	vol, err := dfs.disk.Create(tenantID)
	if err != nil {
		glog.Errorf("Could not create volume for tenant %s: %s", tenantID, err)
		return err
	}
	glog.V(1).Infof("Volume created for %s at %s", tenantID, vol.Path())
	if err := dfs.export(vol.Path()); err != nil {
		glog.Errorf("Could not export volume at %s: %s", vol.Path(), err)
		return err
	}
	return nil
}
484868
func (d *Domain) Create() error {
	var err C.virError
	result := C.virDomainCreateWrapper(d.ptr, &err)
	if result == -1 {
		return makeError(&err)
	}
	return nil
}
260504
func (c *Client) CreateOrgRepo(org string, opt CreateRepoOption) (*Repository, error) {
	body, err := json.Marshal(&opt)
	if err != nil {
		return nil, err
	}
	repo := new(Repository)
	return repo, c.getParsedResponse("POST", fmt.Sprintf("/org/%s/repos", org), jsonHeader, bytes.NewReader(body), repo)
}
619356
func Create(path string) (*Writer, error) {
	f, err := os.Create(path)
	if err != nil {
		return nil, err
	}

	return NewWriter(f, nil)
}
344038
func Create(rootFS vfs.Filesystem) *MountFS {
	return &MountFS{
		rootFS:  rootFS,
		mounts:  make(map[string]vfs.Filesystem),
		parents: make(map[string][]string),
	}
}
850857
func (idx *AddrIndex) Create(dbTx database.Tx) error {
	_, err := dbTx.Metadata().CreateBucket(addrIndexKey)
	return err
}
1160661
func (wc walCryptor) Create(dirpath string, metadata []byte) (WAL, error) {
	w, err := wal.Create(dirpath, metadata)
	if err != nil {
		return nil, err
	}
	return &wrappedWAL{
		WAL:       w,
		encrypter: wc.encrypter,
		decrypter: wc.decrypter,
	}, nil
}
514285
func (repo *repo) Create(user service.Entity) bool {
	if dbconn.DB.NewRecord(user) {
		dbconn.DB.Create(&user)
	}
	return !dbconn.DB.NewRecord(user)
}
138560
func New(dir string) (Git, error) {
	if err := os.MkdirAll(dir, 0755); err != nil {
		return Git{}, err
	}
	return Git{dir: dir}, nil
}
1204496
func (rfs *RootFS) Create(_ string) (billy.File, error) {
	return nil, errors.New("RootFS cannot create files")
}
829007
func (virtualDisk *VirtualDisk) Create(ctx context.Context, datastore *vclib.Datastore) (string, error) {
	if virtualDisk.VolumeOptions.DiskFormat == "" {
		virtualDisk.VolumeOptions.DiskFormat = vclib.ThinDiskType
	}
	if !virtualDisk.VolumeOptions.VerifyVolumeOptions() {
		klog.Error("VolumeOptions verification failed. volumeOptions: ", virtualDisk.VolumeOptions)
		return "", vclib.ErrInvalidVolumeOptions
	}
	if virtualDisk.VolumeOptions.StoragePolicyID != "" && virtualDisk.VolumeOptions.StoragePolicyName != "" {
		return "", fmt.Errorf("Storage Policy ID and Storage Policy Name both set, Please set only one parameter")
	}
	return getDiskManager(virtualDisk, VirtualDiskCreateOperation).Create(ctx, datastore)
}
789715
func (r *RepoKeyResource) Create(owner, slug, key, label string) (*Key, error) {

	values := url.Values{}
	values.Add("key", key)
	values.Add("label", label)

	k := Key{}
	path := fmt.Sprintf("/repositories/%s/%s/deploy-keys", owner, slug)
	if err := r.client.do("POST", path, nil, values, &k); err != nil {
		return nil, err
	}

	return &k, nil
}
1324563
func (l *Layer0) Create(id string, parent string, mountLabel string, storageOpts map[string]string) error {
	id, vol, err := l.create(id, parent)
	if err != nil {
		return err
	}
	err = l.Driver.Create(id, parent, mountLabel, storageOpts)
	if err != nil || vol == nil {
		return err
	}
	// This is layer0. Restore saved upper dir, if one exists.
	savedUpper := path.Join(vol.path, "upper")
	if _, err := os.Stat(savedUpper); err != nil {
		// It's not an error if didn't have a saved upper
		return nil
	}
	// We found a saved upper, restore to newly created upper.
	upperDir := path.Join(path.Join(l.home, id), "upper")
	os.RemoveAll(upperDir)
	return os.Rename(savedUpper, upperDir)
}
804883
func (command ZipToS3BucketResource) Create(awsSession *session.Session,
	event *CloudFormationLambdaEvent,
	logger *logrus.Logger) (map[string]interface{}, error) {
	return command.unzip(awsSession, event, logger)
}
849652
func (d *DevTools) Create(ctx context.Context) (*Target, error) {
	return d.CreateURL(ctx, "")
}
1079392
func (f *FakeFS) Create(path string) (io.WriteCloser, error) {
	buf := new(bytes.Buffer)
	f.Files[path] = buf
	return inMemoryCloser{buf: buf}, nil
}