Skip to content

Commit

Permalink
ci
Browse files Browse the repository at this point in the history
  • Loading branch information
cssho committed Mar 11, 2024
1 parent 176e644 commit 7c74a1e
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 36 deletions.
37 changes: 3 additions & 34 deletions .github/workflows/astro.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,40 +34,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Detect package manager
id: detect-package-manager
run: |
if [ -f "${{ github.workspace }}/yarn.lock" ]; then
echo "manager=yarn" >> $GITHUB_OUTPUT
echo "command=install" >> $GITHUB_OUTPUT
echo "runner=yarn" >> $GITHUB_OUTPUT
exit 0
elif [ -f "${{ github.workspace }}/package.json" ]; then
echo "manager=npm" >> $GITHUB_OUTPUT
echo "command=ci" >> $GITHUB_OUTPUT
echo "runner=npx --no-install" >> $GITHUB_OUTPUT
exit 0
else
echo "Unable to determine package manager"
exit 1
fi
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: "20"
cache: ${{ steps.detect-package-manager.outputs.manager }}
cache-dependency-path: ${{ env.BUILD_PATH }}/package-lock.json
# - name: Setup Pages
# id: pages
# uses: actions/configure-pages@v4
- name: Install dependencies
run: ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }}
working-directory: ${{ env.BUILD_PATH }}
- name: Build with Astro
run: |
${{ steps.detect-package-manager.outputs.runner }} astro build
working-directory: ${{ env.BUILD_PATH }}
uses: actions/checkout@v4
- name: Install, build, and upload your site
uses: withastro/action@v1
- name: html to pdf
uses: fifsky/html-to-pdf-action@master
with:
Expand Down
3 changes: 2 additions & 1 deletion astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { defineConfig } from "astro/config";

// https://astro.build/config
export default defineConfig({
site: "https://vscodejp.github.io/conference-2024",
site: "https://vscodejp.github.io",
base: "/conference-2024",
integrations: [tailwind(), icon()],
});
2 changes: 1 addition & 1 deletion src/components/github-corner.astro
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<!-- https://github.com/tholman/github-corners -->
<a
href="https://github.com/mhyfritz/astro-landing-page"
href="https://github.com/vscodejp/conference-2024"
aria-label="View source on GitHub"
class="absolute right-0 top-0 z-10 text-white hover:text-white focus:ring-0 focus:ring-offset-0"
><svg
Expand Down

0 comments on commit 7c74a1e

Please sign in to comment.