From 679cee5d812e5c0552ce1839a175ec469b6e0f1b Mon Sep 17 00:00:00 2001 From: rizaldy Date: Sun, 28 Apr 2024 23:28:42 +0700 Subject: [PATCH] ci: setup ci --- .gitea/workflows/eleventy.yaml | 22 ++++++++++++++++++++++ .gitignore | 1 + 2 files changed, 23 insertions(+) create mode 100644 .gitea/workflows/eleventy.yaml diff --git a/.gitea/workflows/eleventy.yaml b/.gitea/workflows/eleventy.yaml new file mode 100644 index 0000000..aba3049 --- /dev/null +++ b/.gitea/workflows/eleventy.yaml @@ -0,0 +1,22 @@ +name: eleventy +on: [push] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@master + - run: echo "LAST_COMMIT=`git rev-parse --short HEAD`" >> $GITHUB_ENV + - name: Build + uses: TartanLlama/actions-eleventy@master + with: + install_dependencies: true + - uses: actions/setup-node@v3 + with: + node-version: "20.x" + - run: npx wrangler pages deploy dist --project-name=$CF_PROJECT_NAME --branch=$GITHUB_REF_NAME + env: + CLOUDFLARE_API_TOKEN: ${{ vars.CLOUDFLARE_API_TOKEN }} + CLOUDFLARE_ACCOUNT_ID: ${{ vars.CLOUDFLARE_ACCOUNT_ID }} + CF_PROJECT_NAME: ${{ vars.CF_PROJECT_NAME }} diff --git a/.gitignore b/.gitignore index 785f7a5..3f6e421 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ node_modules dist +.DS_Store .wrangler