MCPcopy
hub / github.com/rclone/rclone / Mkdir

Method Mkdir

backend/s3/s3.go:2821–2828  ·  view source on GitHub ↗

Mkdir creates the bucket if it doesn't exist

(ctx context.Context, dir string)

Source from the content-addressed store, hash-verified

2819
2820// Mkdir creates the bucket if it doesn't exist
2821func (f *Fs) Mkdir(ctx context.Context, dir string) error {
2822 bucket, _ := f.split(dir)
2823 e := f.makeBucket(ctx, bucket)
2824 if e != nil {
2825 return e
2826 }
2827 return f.createDirectoryMarker(ctx, bucket, dir)
2828}
2829
2830// mkdirParent creates the parent bucket/directory if it doesn't exist
2831func (f *Fs) mkdirParent(ctx context.Context, remote string) error {

Callers 1

mkdirParentMethod · 0.95

Calls 3

splitMethod · 0.95
makeBucketMethod · 0.95
createDirectoryMarkerMethod · 0.95

Tested by

no test coverage detected