From 4fb43662d86f9214e35d3ed27f58ba36b68e7524 Mon Sep 17 00:00:00 2001 From: Erwin de Haan Date: Sun, 15 Sep 2019 14:19:47 +0200 Subject: [PATCH 1/2] Made GitHub Releases trigger on BuildCompletion and added update submodules command. --- .ci/azure-pipelines.yml | 10 ++++++++-- src/jellyfin | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.ci/azure-pipelines.yml b/.ci/azure-pipelines.yml index 75871fc34..6cd788bf0 100644 --- a/.ci/azure-pipelines.yml +++ b/.ci/azure-pipelines.yml @@ -17,6 +17,12 @@ jobs: submodules: true persistCredentials: true + - task: CmdLine@2 + displayName: "Update submodules" + inputs: + script: 'git submodule update --recursive --remote' + workingDirectory: '$(Build.SourcesDirectory)' + - task: PowerShell@2 displayName: "DocFX Build" inputs: @@ -25,7 +31,7 @@ jobs: workingDirectory: '$(Build.SourcesDirectory)' - task: ArchiveFiles@2 - condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/master'), in(variables['Build.Reason'], 'IndividualCI', 'BatchedCI')) + condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/master'), in(variables['Build.Reason'], 'IndividualCI', 'BatchedCI', 'BuildCompletion')) displayName: "Package Documentation Website" inputs: rootFolderOrFile: '$(Build.SourcesDirectory)/_site' @@ -38,7 +44,7 @@ jobs: #quiet: # Optional - task: GitHubRelease@0 - condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/master'), in(variables['Build.Reason'], 'IndividualCI', 'BatchedCI')) + condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/master'), in(variables['Build.Reason'], 'IndividualCI', 'BatchedCI', 'BuildCompletion')) displayName: "Create GitHub release" inputs: gitHubConnection: Jellyfin Release Download diff --git a/src/jellyfin b/src/jellyfin index e13107867..cb32bf1c4 160000 --- a/src/jellyfin +++ b/src/jellyfin @@ -1 +1 @@ -Subproject commit e1310786734efb5101e5c29c9e0259eee63b38e6 +Subproject commit cb32bf1c4f671c3d4c2ed451d5513ce7d6b2002d From 170a8674e1e5f1205b69a42f73637a05d6b95f6b Mon Sep 17 00:00:00 2001 From: Erwin de Haan Date: Sun, 15 Sep 2019 14:26:18 +0200 Subject: [PATCH 2/2] Create publish-to-gh-pages.sh --- .ci/publish-to-gh-pages.sh | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 .ci/publish-to-gh-pages.sh diff --git a/.ci/publish-to-gh-pages.sh b/.ci/publish-to-gh-pages.sh new file mode 100644 index 000000000..486a68e44 --- /dev/null +++ b/.ci/publish-to-gh-pages.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +# Download the latest release. +curl -s https://api.github.com/repos/jellyfin/jellyfin-docs/releases/latest | grep "browser_download_url.*docs-.*\.tar\.gz" | cut -d : -f 2,3 | tr -d \" | wget -O /tmp/docs.tar.gz -qi - +# Clean any old files +rm -rf docs/ + +mkdir -p docs/ +pushd docs +# Extract the files +tar -xzf /tmp/docs.tar.gz +popd +git add docs/ +git commit -m "CI Documentation update" +git push origin \ No newline at end of file