Skip to content
This repository has been archived by the owner on Jun 1, 2023. It is now read-only.

GitHub Actionsのパスを統一する #6922

Closed
wants to merge 10 commits into from
2 changes: 1 addition & 1 deletion .github/workflows/audit-staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/cache@v1
with:
path: ~/.npm
path: ${{ github.workspace }}/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/check-statuses-of-forked-sites.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:

- name: Run scripts
run: |
python ./audit-forked-sites/check_status.py
python ${{ github.workspace }}/audit-forked-sites/check_status.py

- name: Create a pull request
uses: peter-evans/create-pull-request@v3
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ jobs:
- run: yarn run test
- name: generate
run: |
echo "GOOGLE_ANALYTICS_ID=${GOOGLE_ANALYTICS_ID}" >> .env.production
echo "GTM_CONTAINER_ID=${GTM_CONTAINER_ID}" >> .env.production
cat .env.production
echo "GOOGLE_ANALYTICS_ID=${GOOGLE_ANALYTICS_ID}" >> ${{ github.workspace }}/.env.production
echo "GTM_CONTAINER_ID=${GTM_CONTAINER_ID}" >> ${{ github.workspace }}/.env.production
cat ${{ github.workspace }}/.env.production
yarn run generate:deploy
env:
GOOGLE_ANALYTICS_ID: ${{ secrets.GOOGLE_ANALYTICS_ID }}
Expand All @@ -48,7 +48,7 @@ jobs:
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./dist
publish_dir: ${{ github.workspace }}/dist
publish_branch: production

- name: Create GitHub release
Expand All @@ -58,8 +58,8 @@ jobs:

- name: run delete_fbcache.sh
run: |
echo "FB_ACCESS_TOKEN=${FACEBOOK_ACCESS_TOKEN}" > .env
cd ui-test
echo "FB_ACCESS_TOKEN=${FACEBOOK_ACCESS_TOKEN}" > ${{ github.workspace }}/.env
cd ${{ github.workspace }}/ui-test
./delete_fbcache.sh
env:
FACEBOOK_ACCESS_TOKEN: ${{ secrets.FACEBOOK_ACCESS_TOKEN }}
3 changes: 2 additions & 1 deletion .github/workflows/i18n_generator.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,9 @@ jobs:
python -m pip install --upgrade pip
pip install BeautifulSoup4
- name: Run script
# Since i18n_generator.py uses os.pardir, the cd command is used to move the directory.
run: |
cd auto-i18n
cd ${{ github.workspace }}/auto-i18n
python i18n_generator.py
cd ..
- name: Create Pull Request
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ogp_builder.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ jobs:
name: ogp
- name: Commit files
run: |
cp -rp ogp static/
cp -rp ${{ github.workspace }}/ogp ${{ github.workspace }}/static/
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git add static
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/screenshot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- run: cp ui-test\dummy.json dist\data/\data.json
- run: cp ${{ github.workspace }}\ui-test\dummy.json ${{ github.workspace }}\dist\data/\data.json
- name: Setup Node
uses: actions/setup-node@v1
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@ jobs:
- run: yarn install --frozen-lockfile
- run: yarn run test
- run: yarn run generate:dev
- run: "echo \"User-agent: *\nDisallow: /\" > ./dist/robots.txt"
- run: "echo \"User-agent: *\nDisallow: /\" > ${{ github.workspace }}/dist/robots.txt"

- name: deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./dist
publish_dir: ${{ github.workspace }}/dist