mirror of https://github.com/aminya/setup-cpp
ci: fix placing the built artifacts
This commit is contained in:
parent
697fc17c87
commit
4e58b250d7
|
@ -48,9 +48,13 @@ jobs:
|
|||
with:
|
||||
version: ${{ matrix.pnpm }}
|
||||
|
||||
- name: Install and build
|
||||
- name: Install
|
||||
run: |
|
||||
pnpm install
|
||||
|
||||
- name: Build
|
||||
run: |
|
||||
pnpm build
|
||||
pnpm build.docker_tests
|
||||
|
||||
- name: Upload Dist
|
||||
|
@ -62,8 +66,8 @@ jobs:
|
|||
./dev/docker/__tests__/
|
||||
retention-days: 1
|
||||
|
||||
Build_Executable:
|
||||
name: Build_Executable-${{ matrix.os }}
|
||||
BuildExecutable:
|
||||
name: Build-Executable-${{ matrix.os }}
|
||||
needs: [Build]
|
||||
if: ${{ !contains(github.event.head_commit.message, '[skip ci]') }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
@ -85,10 +89,6 @@ jobs:
|
|||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
name: dist
|
||||
- name: Place Artifacts
|
||||
shell: bash
|
||||
run: |
|
||||
mv -v artifact/* ./
|
||||
|
||||
- name: Setup Node
|
||||
uses: actions/setup-node@v3
|
||||
|
@ -100,6 +100,21 @@ jobs:
|
|||
with:
|
||||
version: ${{ matrix.pnpm }}
|
||||
|
||||
- name: Cache node_modules
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: |
|
||||
~/.pnpm-store
|
||||
D:\.pnpm-store
|
||||
./node_modules
|
||||
key: "setupcpp-node_modules-cache-OS:${{ matrix.os }}-node:${{ matrix.node }}-pnpm:${{ matrix.pnpm }}-${{ hashFiles('./.npmrc') }}-deps:${{ hashFiles('./package.json') }}"
|
||||
restore-keys: |
|
||||
"setupcpp-node_modules-cache-OS:${{ matrix.os }}-"
|
||||
|
||||
- name: Install
|
||||
run: |
|
||||
pnpm install
|
||||
|
||||
# Create self-contained executable that bundles Nodejs
|
||||
- name: Create Executable
|
||||
run: |
|
||||
|
@ -114,7 +129,7 @@ jobs:
|
|||
retention-days: 1
|
||||
|
||||
Test:
|
||||
name: ${{ matrix.os }}
|
||||
name: Test-${{ matrix.os }}
|
||||
if: ${{ !contains(github.event.head_commit.message, '[skip ci]') || !contains(github.event.head_commit.message, '[skip test]') }}
|
||||
needs: [Build]
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
@ -141,10 +156,6 @@ jobs:
|
|||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
name: dist
|
||||
- name: Place Dist
|
||||
shell: bash
|
||||
run: |
|
||||
mv -v artifact/* ./
|
||||
|
||||
- name: Setup Node
|
||||
uses: actions/setup-node@v3
|
||||
|
@ -156,13 +167,24 @@ jobs:
|
|||
with:
|
||||
version: ${{ matrix.pnpm }}
|
||||
|
||||
# - name: Setup SSH debugging session
|
||||
# uses: mxschmitt/action-tmate@v3
|
||||
- name: Cache node_modules
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: |
|
||||
~/.pnpm-store
|
||||
D:\.pnpm-store
|
||||
./node_modules
|
||||
key: "setupcpp-node_modules-cache-OS:${{ matrix.os }}-node:${{ matrix.node }}-pnpm:${{ matrix.pnpm }}-${{ hashFiles('./.npmrc') }}-deps:${{ hashFiles('./package.json') }}"
|
||||
restore-keys: |
|
||||
"setupcpp-node_modules-cache-OS:${{ matrix.os }}-"
|
||||
|
||||
- name: Install
|
||||
run: |
|
||||
pnpm install
|
||||
|
||||
# - name: Setup SSH debugging session
|
||||
# uses: mxschmitt/action-tmate@v3
|
||||
|
||||
- name: Test
|
||||
run: |
|
||||
pnpm run test
|
||||
|
@ -184,7 +206,7 @@ jobs:
|
|||
node ./dist/actions/setup-cpp.js --help
|
||||
|
||||
Docker:
|
||||
name: ${{ matrix.container }}
|
||||
name: Test-${{ matrix.container }}
|
||||
if: ${{ !contains(github.event.head_commit.message, '[skip ci]') && !contains(github.event.head_commit.message, '[skip test]') }}
|
||||
needs: [Build]
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
@ -213,10 +235,6 @@ jobs:
|
|||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
name: dist
|
||||
- name: Place Dist
|
||||
shell: bash
|
||||
run: |
|
||||
mv -v artifact/* ./
|
||||
|
||||
- name: Build
|
||||
id: docker_build
|
||||
|
@ -226,7 +244,7 @@ jobs:
|
|||
|
||||
Release:
|
||||
if: startsWith(github.ref, 'refs/tags/')
|
||||
needs: [Build, Build_Executable, Test, Docker]
|
||||
needs: [Build, BuildExecutable, Test, Docker]
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- name: Download All Artifacts
|
||||
|
|
|
@ -3,7 +3,7 @@ import type { Config } from "jest"
|
|||
const jestConfig: Config = {
|
||||
testMatch: ["**/*.test.ts"],
|
||||
testEnvironment: "node",
|
||||
extensionsToTreatAsEsm: [".ts", ".tsx", ".js", ".jsx"],
|
||||
extensionsToTreatAsEsm: [".ts", ".tsx", ".jsx"],
|
||||
transformIgnorePatterns: [], // transform node_modules
|
||||
transform: {
|
||||
"^.+\\.(t|j)sx?$": "@swc/jest",
|
||||
|
|
|
@ -56,7 +56,7 @@
|
|||
"test.lint.eslint": "eslint **/*.{ts,tsx,js,jsx,cjs,mjs,json,yaml} --no-error-on-unmatched-pattern --cache --cache-location ./.cache/eslint/",
|
||||
"test.lint.prettier": "prettier . --check",
|
||||
"test.unit": "jest --runInBand",
|
||||
"build.docker_tests": "pnpm build && node ./dev/docker/__tests__/generate-docker-tests.mjs",
|
||||
"build.docker_tests": "node ./dev/docker/__tests__/generate-docker-tests.mjs",
|
||||
"build.docker.arch": "pnpm build.docker_tests && docker build -f ./dev/docker/__tests__/arch.dockerfile -t setup-cpp:arch .",
|
||||
"build.docker.fedora": "pnpm build.docker_tests && docker build -f ./dev/docker/__tests__/fedora.dockerfile -t setup-cpp:fedora .",
|
||||
"build.docker.ubuntu": "pnpm build.docker_tests && docker build -f ./dev/docker/__tests__/ubuntu.dockerfile -t setup-cpp:ubuntu .",
|
||||
|
|
Loading…
Reference in New Issue