package
0.0.0-20240324200706-eaa17bf4a307
Repository: https://github.com/koltyakov/gosip-sandbox.git
Documentation: pkg.go.dev
# README
Folders & Files sync
The sample shows how to arrange local directory changes tracking with the corresponding synchronization with SharePoint document library.
The use-cases are:
- assets deployment pipelines
- file-based integrations
Build
go build -o bin/spsync.exe ./samples/spsync/
Start process
Create ./config/private.json
with SAML auth credentials (or any other, but should be aligned with sources).
Run:
bin/spsync.exe -localFolder ./folder/to/watch -spFolder "Style Library"
Where:
-localFolder
is a local folder to watch-spFolder
is SP folder to sync to
When applied changes are synced with SharePoint.
All flags description
go run ./samples/spsync/ -h
Flag | Description |
---|---|
-strategy | string, Auth strategy (default "saml") |
-config | string, Config path (default "./config/private.json") |
-localFolder | string, Local folder to watch |
-spFolder | string, SP folder to sync to (default "SiteAssets") |
-skipSync | bool, Skips initial sync of files on startup |
-watch | bool, Watch local folder for changes |