Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NEXT-33446 - tidy up ci #16

Merged
merged 19 commits into from
Feb 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
3692f02
NEXT-33446 - get rid of developer portal pipelines
Haberkamp Feb 13, 2024
e459034
NEXT-33446 - delete chromatic workflow
Haberkamp Feb 13, 2024
3136fb3
test
Haberkamp Feb 13, 2024
932d67c
NEXT-33446 - add node_modules caching between jobs
Haberkamp Feb 13, 2024
6089506
NEXT-33446 - only run jobs when needed
Haberkamp Feb 13, 2024
fd013cf
NEXT-33446 - remove scripts in root of repository
Haberkamp Feb 13, 2024
df94d2d
NEXT-33446 - use --filter instead of --prefix in CI
Haberkamp Feb 13, 2024
cd4639f
NEXT-33446 - remove root format command
Haberkamp Feb 13, 2024
037170e
NEXT-33446 - define outputs for turbo tasks
Haberkamp Feb 13, 2024
1f81eb3
NEXT-33446 - rename build command of design-tokens to start
Haberkamp Feb 13, 2024
93fd4c0
NEXT-33446 - define outputs directories for build tasks
Haberkamp Feb 13, 2024
c19f82a
NEXT-33446 - cache visual test
Haberkamp Feb 13, 2024
71692fb
NEXT-33446 - use build caching in CI
Haberkamp Feb 13, 2024
9bfe656
NEXT-33446 - enable caching for meteor admin sdk e2e tests
Haberkamp Feb 14, 2024
9779ffd
NEXT-33446 - supply turborepo env variables to e2e test job
Haberkamp Feb 14, 2024
be31842
NEXT-33446 - bump up playwright to v1.41.0 in admin sdk
Haberkamp Feb 14, 2024
36e5ebb
NEXT-33446 - fix waiting to load for the full page in admin sdk e2e t…
Haberkamp Feb 14, 2024
a8ae5a8
NEXT-33446 - fix scripts in admin sdk package.json file
Haberkamp Feb 14, 2024
7d3a73f
NEXT-33446 - supply env variables to deploy preview command
Haberkamp Feb 14, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 0 additions & 34 deletions .github/workflows/chromatic.yml

This file was deleted.

26 changes: 0 additions & 26 deletions .github/workflows/deploy-developer-portal.yml

This file was deleted.

8 changes: 6 additions & 2 deletions .github/workflows/deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ on:
push:
branches:
- main
paths:
- 'packages/component-library/**'

jobs:
create-storybook-pages:
Expand All @@ -20,12 +22,14 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'

- name: Install dependencies
run: pnpm install --frozen-lockfile --prefer-offline

- name: Create the static pages directory locally in CI
run: pnpm --prefix ./packages/component-library run build-storybook
- name: Build storybook
run: pnpx turbo run build:storybook --filter=@shopware-ag/meteor-component-library

- name: Deploy 🚀
uses: JamesIves/[email protected]
Expand Down
19 changes: 0 additions & 19 deletions .github/workflows/developer-portal-healthckeck.yml

This file was deleted.

9 changes: 6 additions & 3 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: Docs

on: push
on:
push:
branches:
- main

jobs:
create-docs-icon-kit:
Expand All @@ -10,7 +13,6 @@ jobs:
uses: actions/checkout@v4

- name: Deploy redirect
if: github.ref == 'refs/heads/main'
uses: JamesIves/[email protected]
with:
branch: gh-pages
Expand All @@ -31,6 +33,8 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'

- name: Install dependencies
run: pnpm install --frozen-lockfile --prefer-offline
Expand All @@ -45,7 +49,6 @@ jobs:
pnpm run doc

- name: Deploy 🚀
if: github.ref == 'refs/heads/trunk'
uses: JamesIves/[email protected]
with:
branch: gh-pages
Expand Down
20 changes: 12 additions & 8 deletions .github/workflows/preview.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
name: Deploy PR previews

on:
on:
pull_request:
types:
- opened
- reopened
- synchronize
- closed
branches:
- main
paths:
- 'packages/component-library/**'

concurrency: preview-${{ github.ref }}

jobs:
deploy-preview:
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
steps:
- name: Checkout the repository
uses: actions/checkout@v4
Expand All @@ -25,12 +27,14 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'

- name: Install main dependencies
run: pnpm install --frozen-lockfile --prefer-offline

- name: Create the static pages directory locally in CI
run: pnpm --prefix ./packages/component-library run build-storybook
- name: Build storybook
run: pnpx turbo run build:storybook --filter=@shopware-ag/meteor-component-library

- name: Deploy preview
uses: rossjrw/pr-preview-action@v1
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'

- name: Install dependencies
run: pnpm i
Expand Down
21 changes: 16 additions & 5 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,18 +28,20 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'

- name: Install dependencies
run: pnpm i

- name: Check formatting
run: pnpm run format:check
run: pnpx turbo run format:check

- name: Perform typecheck
run: pnpm run lint:types
run: pnpx turbo run lint:types

- name: Lint code
run: pnpm run lint:eslint
run: pnpx turbo run lint:eslint

unit-tests:
name: Unit tests
Expand All @@ -59,12 +61,14 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'

- name: Install dependencies
run: pnpm install --frozen-lockfile --prefer-offline

- name: unit
run: pnpm run test:unit
run: pnpx turbo run test:unit

circular-dependencies:
name: Check for circular dependencies (Madge)
Expand All @@ -84,6 +88,8 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'

- name: Install dependencies
run: pnpm install --frozen-lockfile --prefer-offline
Expand All @@ -99,6 +105,9 @@ jobs:
- circular-dependencies
- unit-tests
- static-analysis
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
steps:
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -111,6 +120,8 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'

- name: Install dependencies
run: pnpm install --frozen-lockfile --prefer-offline
Expand All @@ -119,7 +130,7 @@ jobs:
run: npx playwright install

- name: Run Playwright tests
run: pnpm --filter @shopware-ag/meteor-admin-sdk run test:e2e
run: pnpx turbo run test:e2e --filter @shopware-ag/meteor-admin-sdk

- uses: actions/upload-artifact@v2
if: always()
Expand Down
38 changes: 0 additions & 38 deletions .github/workflows/update-healthcheck.yml

This file was deleted.

6 changes: 4 additions & 2 deletions .github/workflows/update-icons.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,17 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'

- name: Install dependencies
run: pnpm install --frozen-lockfile --prefer-offline

- name: Build
run: pnpm --prefix ./packages/icon-kit run build
run: pnpm --filter @shopware-ag/meteor-component-library run build

- name: Update icons
run: pnpm --prefix ./packages/icon-kit run start
run: pnpm --filter @shopware-ag/meteor-component-library run start

- name: Create Pull Request
uses: peter-evans/create-pull-request@v4
Expand Down
16 changes: 9 additions & 7 deletions .github/workflows/visual-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ on:
push:
branches:
- main
paths:
- 'packages/component-library/**'

workflow_dispatch:

Expand All @@ -27,23 +29,23 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'pnpm'
cache-dependency-path: '**/pnpm-lock.yaml'

- name: Install dependencies
run: pnpm install --frozen-lockfile --prefer-offline

- name: Install Playwright
run: pnpm dlx playwright install

- name: Create the static pages directory locally in CI
run: pnpm --prefix ./packages/component-library run build-storybook
- name: Build storybook
run: pnpx turbo run build:storybook --filter=@shopware-ag/meteor-component-library

- name: Run Tests
id: storybookTests
run: |
cd ./packages/component-library &&
npx concurrently --kill-others --success first --names "SB,TEST" --prefix-colors "magenta,blue" \
"http-server storybook-static -a 127.0.0.1 --port 6006" \
"wait-on http://127.0.0.1:6006 && pnpm run test-storybook"
"pnpm --filter @shopware-ag/meteor-component-library run start:storybook" \
"wait-on http://127.0.0.1:6006 && pnpx turbo run test:storybook --filter=@shopware-ag/meteor-component-library"

- name: Archive visual test diffs
uses: actions/upload-artifact@v3
Expand Down
11 changes: 1 addition & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,7 @@
"version": "0.0.0",
"private": true,
"description": "The monorepo that contains all Meteor related projects",
"scripts": {
"build": "turbo run build",
"lint:all": "turbo run lint:all",
"lint:types": "turbo run lint:types",
"lint:eslint": "turbo run lint:eslint",
"format": "turbo run format",
"format:check": "turbo run format:check",
"test:unit": "turbo run test:unit",
"test:e2e": "turbo run test:e2e"
},
"scripts": {},
"keywords": [],
"license": "MIT",
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion packages/admin-sdk/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# meteor-admin-sdk
# meteor-admin-sdk
[![Tests](https://github.com/shopware/meteor-admin-sdk/actions/workflows/tests.yml/badge.svg)](https://github.com/shopware/meteor-admin-sdk/actions/workflows/tests.yml)
[![NPM Package](https://img.shields.io/npm/v/@shopware-ag/meteor-admin-sdk)](https://www.npmjs.com/package/@shopware-ag/meteor-admin-sdk)

Expand Down
Loading
Loading