From 6e97bc09f8b4f9f62d08286e557a73ecce76529b Mon Sep 17 00:00:00 2001 From: Yuki Okushi Date: Thu, 13 Aug 2020 16:04:50 +0900 Subject: [PATCH] Use action to upload docs --- .github/workflows/bench.yml | 2 +- .github/workflows/linux.yml | 2 +- .github/workflows/macos.yml | 2 +- .github/workflows/upload-doc.yml | 12 +++++++----- .github/workflows/windows.yml | 2 +- 5 files changed, 11 insertions(+), 9 deletions(-) diff --git a/.github/workflows/bench.yml b/.github/workflows/bench.yml index 754091dd..d19471a1 100644 --- a/.github/workflows/bench.yml +++ b/.github/workflows/bench.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@master + - uses: actions/checkout@v2 - name: Install Rust uses: actions-rs/toolchain@v1 diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index d49874ce..a068070f 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -21,7 +21,7 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@master + - uses: actions/checkout@v2 - name: Install ${{ matrix.version }} uses: actions-rs/toolchain@v1 diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index 0683fcc8..dc8558ac 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -20,7 +20,7 @@ jobs: runs-on: macOS-latest steps: - - uses: actions/checkout@master + - uses: actions/checkout@v2 - name: Install ${{ matrix.version }} uses: actions-rs/toolchain@v1 diff --git a/.github/workflows/upload-doc.yml b/.github/workflows/upload-doc.yml index 75d534b2..99fa663c 100644 --- a/.github/workflows/upload-doc.yml +++ b/.github/workflows/upload-doc.yml @@ -11,7 +11,7 @@ jobs: if: github.repository == 'actix/actix-web' steps: - - uses: actions/checkout@master + - uses: actions/checkout@v2 - name: Install Rust uses: actions-rs/toolchain@v1 @@ -29,7 +29,9 @@ jobs: - name: Tweak HTML run: echo "" > target/doc/index.html - - name: Upload documentation - run: | - git clone https://github.com/davisp/ghp-import.git - ./ghp-import/ghp_import.py -n -p -f -m "Documentation upload" -r https://${{ secrets.GITHUB_TOKEN }}@github.com/"${{ github.repository }}.git" target/doc + - name: Deploy to GitHub Pages + uses: JamesIves/github-pages-deploy-action@3.5.8 + with: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + BRANCH: gh-pages + FOLDER: target/doc diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index c09c7cea..d53d50a6 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -23,7 +23,7 @@ jobs: runs-on: windows-latest steps: - - uses: actions/checkout@master + - uses: actions/checkout@v2 - name: Install ${{ matrix.version }} uses: actions-rs/toolchain@v1