Skip to content

Upload a folder to a Sharepoint library, retaining the subfolder structure

License

Notifications You must be signed in to change notification settings

swedwise/action-sharepoint-folder-upload

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

action-sharepoint-folder-upload

This action will upload the contents of a specified folder to a Sharepoint site.

Inputs

Input name Required Description Example
site_url Yes The Sharepoint site url https://swedwise-my.sharepoint.com/personal/henrik_blidh_swedwise_se
sharepoint_user Yes The username to use for authentication henrik.blidh@swedwise.se
sharepoint_password Yes The user's password
Use GitHub Actions Secrets to store sensible informations
MyPassword123!
destination_folder Yes The path relative to site where to upload a file Documents/Upload
folder Yes The path of the folder you want to upload ${{ github.workspace }}/MyFolder

Example usage

This can be used for e.g. publishing static sites to a Sharepoint server.

name: 'Sharepoint Upload'

on:
  release:
    types: created

jobs:
  publish:
    runs-on: ubuntu-latest
    steps:

      - name: Clone your repo
        uses: actions/checkout@v3

      - name: Sharepoint upload file
        uses: swedwise/action-sharepoint-folder-upload@v1.2
        with:
          site_url: 'https://swedwise-my.sharepoint.com/personal/henrik_blidh_swedwise_se'
          sharepoint_user: ${{ secrets.USER }}
          sharepoint_password: ${{ secrets.PASS }}
          destination_folder: "Documents/Upload"
          folder: "./_build/html/"

About

Upload a folder to a Sharepoint library, retaining the subfolder structure

Resources

License

Stars

Watchers

Forks

Packages

No packages published