Skip to content

Commit

Permalink
Added project-site copy step
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrei15193 committed Oct 25, 2020
1 parent 8849a1e commit 3460170
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions .github/workflows/build-and-deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,18 @@ jobs:
- name: Checkout
uses: actions/checkout@v2

- name: Copy Project Site for Updates
shell: pwsh
run: |
git fetch origin gh-pages
git checkout gh-pages
New-Item -ItemType Directory -Name project-site -ErrorAction SilentlyContinue | Out-Null
New-Item -ItemType Directory -Name project-site/dev -ErrorAction SilentlyContinue | Out-Null
Get-ChildItem -Exclude @(".*", "project-site") |
Where-Object { ($_ -is [System.IO.DirectoryInfo] -and -not $_.Name.StartsWith("EmbeddedResourceBrowser")) -or $_ -is [System.IO.FileInfo] } |
Move-Item -Destination project-site
git checkout ($env:GITHUB_REF.Substring("refs/heads/".Length))
- name: Generate Package Info
id: package_info
shell: pwsh
Expand Down Expand Up @@ -177,12 +189,6 @@ jobs:
asset_name: EmbeddedResourceBrowser.${{ steps.package_info.outputs.package_version }}.nupkg
asset_content_type: application/zip

- name: Prepare Project Site Build
shell: pwsh
run: |
mkdir ./project-site
mkdir ./project-site/dev
- name: Generate Project Site (dev)
if: github.ref == 'refs/heads/master'
working-directory: ./project-site/dev
Expand Down

0 comments on commit 3460170

Please sign in to comment.