Update to to cli/backup/sharepoint.go
Bug Fix: FileCreated flags updated. Commment fixes.
This commit is contained in:
parent
4b58ac472f
commit
b22c00424e
@ -2,6 +2,7 @@ package backup
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
"fmt"
|
||||||
|
|
||||||
"github.com/hashicorp/go-multierror"
|
"github.com/hashicorp/go-multierror"
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
@ -55,10 +56,10 @@ const (
|
|||||||
sharePointServiceCommandCreateExamples = `# Backup SharePoint data for <site>
|
sharePointServiceCommandCreateExamples = `# Backup SharePoint data for <site>
|
||||||
corso backup create sharepoint --site <site_id>
|
corso backup create sharepoint --site <site_id>
|
||||||
|
|
||||||
# Backup SharePoint for Alice and Bob
|
# Backup SharePoint for two different sites
|
||||||
corso backup create sharepoint --site <site_id_1>,<site_id_2>
|
corso backup create sharepoint --web-url <url_1>,<url_2>
|
||||||
|
|
||||||
# TODO: Site IDs may contain commas. We'll need to warn the site about escaping them.
|
# Site IDs may contain commas. Either use the web-url or escape the commas within the Site ID.
|
||||||
|
|
||||||
# Backup all SharePoint data for all sites
|
# Backup all SharePoint data for all sites
|
||||||
corso backup create sharepoint --site '*'`
|
corso backup create sharepoint --site '*'`
|
||||||
@ -431,10 +432,10 @@ func detailsSharePointCmd(cmd *cobra.Command, args []string) error {
|
|||||||
LibraryPaths: libraryPaths,
|
LibraryPaths: libraryPaths,
|
||||||
Sites: site,
|
Sites: site,
|
||||||
WebURLs: weburl,
|
WebURLs: weburl,
|
||||||
FileCreatedAfter: fileCreatedAfter,
|
FileCreatedAfter: utils.FileCreatedAfter,
|
||||||
FileCreatedBefore: fileCreatedBefore,
|
FileCreatedBefore: utils.FileCreatedBefore,
|
||||||
FileModifiedAfter: fileModifiedAfter,
|
FileModifiedAfter: utils.FileModifiedAfter,
|
||||||
FileModifiedBefore: fileModifiedBefore,
|
FileModifiedBefore: utils.FileModifiedBefore,
|
||||||
|
|
||||||
Populated: utils.GetPopulatedFlags(cmd),
|
Populated: utils.GetPopulatedFlags(cmd),
|
||||||
}
|
}
|
||||||
@ -474,6 +475,7 @@ func runDetailsSharePointCmd(
|
|||||||
skipReduce bool,
|
skipReduce bool,
|
||||||
) (*details.Details, error) {
|
) (*details.Details, error) {
|
||||||
if err := utils.ValidateSharePointRestoreFlags(backupID, opts); err != nil {
|
if err := utils.ValidateSharePointRestoreFlags(backupID, opts); err != nil {
|
||||||
|
fmt.Println("Fail on validate")
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user