feat(config): add branding to action.yml to publish in marketplace #11
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Continuous Integration | |
env: | |
HUSKY: 0 | |
on: [push] | |
jobs: | |
ci: | |
name: Complete Check | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [20] | |
steps: | |
- name: Checkout | |
id: checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Install pnpm | |
uses: pnpm/action-setup@v4 | |
with: | |
version: 9 | |
- name: Setup Node.js | |
id: setup-node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: 'pnpm' | |
- name: Install Dependencies | |
id: pnpmi | |
run: pnpm install | |
- name: Check last commit message | |
id: commitlint-main | |
if: github.ref_name == 'main' | |
run: pnpm commitlint --last --verbose | |
- name: Check commit message | |
id: commitlint-not_main | |
if: github.ref_name != 'main' | |
run: pnpm commitlint --from=origin/main --verbose | |
- name: Type Check | |
id: pnpm-typecheck | |
run: pnpm typecheck | |
- name: Lint | |
id: pnpm-lint | |
run: pnpm lint | |
- name: Test | |
id: pnpm-ci-test-main | |
if: github.ref_name == 'main' | |
run: pnpm test:all --ci | |
- name: Test | |
id: pnpm-ci-test-not_main | |
if: github.ref_name != 'main' | |
run: pnpm test -- --ci | |
- name: Build | |
id: pnpm-build | |
run: pnpm build | |
# This will fail the workflow if the `dist/` directory is different than | |
# expected. | |
- name: Compare Directories | |
id: diff | |
run: | | |
if [ ! -d dist/ ]; then | |
echo "Expected dist/ directory does not exist. See status below:" | |
ls -la ./ | |
exit 1 | |
fi | |
if [ "$(git diff --ignore-space-at-eol --text dist/ | wc -l)" -gt "0" ]; then | |
echo "Detected uncommitted changes after build. See status below:" | |
git diff --ignore-space-at-eol --text dist/ | |
exit 1 | |
fi |