Skip to content

Commit

Permalink
コアのキャッシュkeyを修正 (#407)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hiroshiba authored May 15, 2022
1 parent dc918b2 commit d6c18ba
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 43 deletions.
29 changes: 4 additions & 25 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ jobs:
include:
- os: macos-11
python_architecture: "x64"
pip_cache_path: ~/Library/Caches/pip
voicevox_core_asset_prefix: voicevox_core-osx-universal2-cpu
onnxruntime_url: https://github.com/microsoft/onnxruntime/releases/download/v1.10.0/onnxruntime-osx-universal2-1.10.0.tgz
artifact_name: macos-x64
Expand Down Expand Up @@ -55,15 +54,7 @@ jobs:
with:
python-version: ${{ env.PYTHON_VERSION }}
architecture: ${{ matrix.python_architecture }}

- name: Prepare Python dependencies cache
uses: actions/cache@v2
id: pip-cache
with:
path: ${{ matrix.pip_cache_path }}
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt', '**/requirements-dev.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: pip

- name: Install Python dependencies
shell: bash
Expand Down Expand Up @@ -137,7 +128,7 @@ jobs:
uses: actions/cache@v2
id: voicevox-core-cache
with:
key: ${{ matrix.os }}-voicevox-core-${{ env.VOICEVOX_CORE_VERSION }}
key: ${{ matrix.os }}-voicevox-core-${{ matrix.voicevox_core_asset_prefix }}-${{ env.VOICEVOX_CORE_VERSION }}
path: download/core

- name: Download VOICEVOX Core release
Expand Down Expand Up @@ -381,7 +372,6 @@ jobs:
ccache_url: https://github.com/ccache/ccache/releases/download/v4.4.1/ccache-4.4.1-windows-64.zip
artifact_name: windows-cpu
nuitka_cache_path: nuitka_cache
pip_cache_path: ~\AppData\Local\pip\Cache
# Windows DirectML
- os: windows-2019
architecture: "x64"
Expand All @@ -391,7 +381,6 @@ jobs:
ccache_url: https://github.com/ccache/ccache/releases/download/v4.4.1/ccache-4.4.1-windows-64.zip
artifact_name: windows-directml
nuitka_cache_path: nuitka_cache
pip_cache_path: ~\AppData\Local\pip\Cache
# Windows NVIDIA GPU
- os: windows-2019
architecture: "x64"
Expand All @@ -402,7 +391,6 @@ jobs:
ccache_url: https://github.com/ccache/ccache/releases/download/v4.4.1/ccache-4.4.1-windows-64.zip
artifact_name: windows-nvidia
nuitka_cache_path: nuitka_cache
pip_cache_path: ~\AppData\Local\pip\Cache

runs-on: ${{ matrix.os }}

Expand Down Expand Up @@ -498,16 +486,7 @@ jobs:
with:
python-version: ${{ env.PYTHON_VERSION }}
architecture: ${{ matrix.architecture }}

# Install Python dependencies
- name: Prepare Python dependencies cache
uses: actions/cache@v2
id: pip-cache
with:
path: ${{ matrix.pip_cache_path }}
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt', '**/requirements-dev.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: pip

- name: Install Python dependencies
shell: bash
Expand Down Expand Up @@ -657,7 +636,7 @@ jobs:
uses: actions/cache@v2
id: voicevox-core-cache
with:
key: ${{ matrix.os }}-voicevox-core-${{ env.VOICEVOX_CORE_VERSION }}
key: ${{ matrix.os }}-voicevox-core-${{ matrix.voicevox_core_asset_prefix }}-${{ env.VOICEVOX_CORE_VERSION }}
path: download/core

- name: Download VOICEVOX Core
Expand Down
9 changes: 1 addition & 8 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,7 @@ jobs:
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python }}

- uses: actions/cache@v2
id: pip-cache
with:
path: ${{ matrix.path }}
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt', '**/requirements-test.txt', '**/requirements-dev.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: pip

- name: Install libraries for ubuntu
if: matrix.os == 'ubuntu-latest'
Expand Down
11 changes: 1 addition & 10 deletions .github/workflows/upload-gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ on:
- "master"

env:
PIP_CACHE_PATH: "~/.cache/pip"
PYTHON_VERSION: "3.8.10"
PUBLISH_DIR: "./docs/api"
PUBLISH_BRANCH: "gh-pages"
Expand All @@ -23,15 +22,7 @@ jobs:
uses: actions/setup-python@v2
with:
python-version: ${{ env.PYTHON_VERSION }}

- name: Prepare Python dependencies cache
uses: actions/cache@v2
id: pip-cache
with:
path: ${{ env.PIP_CACHE_PATH }}
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
cache: pip

- name: Install libraries for ubuntu
run: sudo apt-get install libsndfile1
Expand Down

0 comments on commit d6c18ba

Please sign in to comment.