Skip to content

chore: tailwind plugin use configResolved instead of config hook (#2025) #1148

chore: tailwind plugin use configResolved instead of config hook (#2025)

chore: tailwind plugin use configResolved instead of config hook (#2025) #1148

Workflow file for this run

name: Publish packages and crates
on:
push:
branches:
- main
concurrency: ${{ github.workflow }}-${{ github.ref }}
jobs:
call-rust-build:
uses: ./.github/workflows/rust-build.yaml
release:
name: Release
needs: [call-rust-build]
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup Node.js 18.x
uses: actions/setup-node@v4
with:
node-version: 18.x
# batch download artifacts
- uses: actions/download-artifact@v4
with:
path: /tmp/artifacts
- name: Copy Farm Core Binary
run: cp /tmp/artifacts/${{ github.sha }}-linux-x64-gnu/* ./packages/core/binding
- name: Move Artifacts
run: |
for abi in linux-x64-gnu linux-x64-musl darwin-x64 win32-x64-msvc linux-arm64-musl linux-arm64-gnu darwin-arm64 win32-ia32-msvc win32-arm64-msvc
do
mv /tmp/artifacts/${{ github.sha }}-${abi}/* ./packages/core/npm/${abi}
mv /tmp/artifacts/${{ github.sha }}-${abi}-plugin-react/* ./rust-plugins/react/npm/${abi}
mv /tmp/artifacts/${{ github.sha }}-${abi}-plugin-sass/* ./rust-plugins/sass/npm/${abi}
mv /tmp/artifacts/${{ github.sha }}-${abi}-create-farm/* ./packages/create-farm/npm/${abi}
test -f ./packages/core/npm/${abi}/farm.${abi}.node
test -f ./packages/create-farm/npm/${abi}/create-farm.${abi}.node
test -f ./rust-plugins/react/npm/${abi}/index.farm
test -f ./rust-plugins/sass/npm/${abi}/index.farm
done
for abi in android-arm-eabi linux-arm-gnueabihf android-arm64 freebsd-x64
do
mv /tmp/artifacts/${{ github.sha }}-${abi}-create-farm/* ./packages/create-farm/npm/${abi}
test -f ./packages/create-farm/npm/${abi}/create-farm.${abi}.node
done
- name: Install Dependencies
run: npm install -g [email protected] && pnpm i --frozen-lockfile
- name: Build Plugin Tools
run: pnpm --filter @farmfe/plugin-tools run build
- name: Create Release Pull Request or Publish to npm
id: changesets
uses: changesets/action@v1
with:
version: pnpm bump
publish: pnpm release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
# Test create farm and make sure it works after release
- name: Test Create Farm React
run: cd .. && pnpm create farm my-test-app-react --template react && cd my-test-app-react && pnpm i && pnpm build
- name: Test Create Farm Vue
run: cd .. && pnpm create farm my-test-app-vue --template vue3 && cd my-test-app-vue && pnpm i && pnpm build
- name: Test Create Farm Solid
run: cd .. && pnpm create farm my-test-app-solid --template solid && cd my-test-app-solid && pnpm i && pnpm build
- name: Test Create Farm Svelte
run: cd .. && pnpm create farm my-test-app-svelte --template svelte && cd my-test-app-svelte && pnpm i && pnpm build
- name: Test Create Farm Llit
run: cd .. && pnpm create farm my-test-app-lit --template lit && cd my-test-app-lit && pnpm i && pnpm build
- name: Test Create Farm Vanilla
run: cd .. && pnpm create farm my-test-app-vanilla --template vanilla && cd my-test-app-vanilla && pnpm i && pnpm build
- name: Test Create Farm Preact
run: cd .. && pnpm create farm my-test-app-preact --template preact && cd my-test-app-preact && pnpm i && pnpm build