Skip to content

Commit

Permalink
url表示
Browse files Browse the repository at this point in the history
  • Loading branch information
Kenshin0011 committed Jun 14, 2024
1 parent eb35745 commit 92efd89
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions .github/workflows/static.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ jobs:
build-and-deploy:
runs-on: ubuntu-latest

uses:
steps:
- name: Checkout code
uses: actions/checkout@v3
Expand Down Expand Up @@ -40,3 +41,17 @@ jobs:
npm run deploy
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Get GitHub Pages URL
uses: actions/github-script@v6
id: get-url
with:
script: |
const repo = context.repo.repo;
const owner = context.repo.owner;
const pages = await github.repos.getPages({ owner, repo });
return pages.data.html_url;
- name: Output GitHub Pages URL
run: |
echo "GitHub Pages URL: ${{ steps.get-url.outputs.result }}"

0 comments on commit 92efd89

Please sign in to comment.