Skip to content
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
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
12 changes: 9 additions & 3 deletions .github/workflows/CreateGWRelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,22 @@ jobs:
with:
submodules: false

- name: Setup pnpm
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda #v4.1.0
with:
version: 10

- name: "Defining node version"
uses: actions/setup-node@1f8c6b94b26d0feae1e387ca63ccbdc44d27b561 # v2
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
node-version-file: ".nvmrc"
cache: 'pnpm'

- name: "Installing dependencies"
run: npm install
run: pnpm install

- name: "Creating GW release and MR"
run: "npm run release:gw"
run: "pnpm --dir packages/release-tools run release:gw"
env:
GH_USERNAME: ${{ secrets.GH_USERNAME }}
GH_EMAIL: ${{ secrets.GH_EMAIL }}
Expand Down
12 changes: 9 additions & 3 deletions .github/workflows/CreatePWTRelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,22 @@ jobs:
with:
submodules: false

- name: Setup pnpm
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda #v4.1.0
with:
version: 10

- name: "Defining node version"
uses: actions/setup-node@1f8c6b94b26d0feae1e387ca63ccbdc44d27b561 # v2
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
node-version-file: ".nvmrc"
cache: 'pnpm'

- name: "Installing dependencies"
run: npm install
run: pnpm install

- name: "Creating PWT release and MR"
run: "npm run release:pwt"
run: "pnpm --dir packages/release-tools run release:pwt"
env:
GH_USERNAME: ${{ secrets.GH_USERNAME }}
GH_EMAIL: ${{ secrets.GH_EMAIL }}
Expand Down
24 changes: 13 additions & 11 deletions .github/workflows/PublishNpm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,30 +16,32 @@ jobs:
uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579 # v2
with:
submodules: false

- name: Setup pnpm
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda #v4.1.0
with:
version: 10

- name: "Defining Environment Variables"
id: variables
run: echo "::set-output name=tag::$(git tag --points-at HEAD)"

- name: "Defining node version"
uses: actions/setup-node@1f8c6b94b26d0feae1e387ca63ccbdc44d27b561 # v2
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
node-version-file: ".nvmrc"
- name: "Installing root dependencies"
working-directory: ./
run: npm install
- name: "Installing pluggable-widgets-tools dependencies"
working-directory: ./packages/pluggable-widgets-tools
if: contains(steps.variables.outputs.tag, 'pluggable-widgets-tools-v')
run: npm install
cache: 'pnpm'

- name: "Installing generator-widget dependencies"
working-directory: ./packages/generator-widget
if: contains(steps.variables.outputs.tag, 'generator-widget-v')
run: npm install
run: pnpm install

- name: "Targeting Pluggable Widgets Tools"
if: contains(steps.variables.outputs.tag, 'pluggable-widgets-tools-v')
uses: JS-DevTools/npm-publish@0f451a94170d1699fd50710966d48fb26194d939 # v1
with:
package: "./packages/pluggable-widgets-tools/package.json"
token: ${{ secrets.NPM_TOKEN }}

- name: "Targeting Pluggable Widgets Generator"
if: contains(steps.variables.outputs.tag, 'generator-widget-v')
uses: JS-DevTools/npm-publish@0f451a94170d1699fd50710966d48fb26194d939 # v1
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/ShaCheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ jobs:
uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579 # v2
with:
submodules: false

- name: "Ensure SHA pinned actions"
uses: zgosalvez/github-actions-ensure-sha-pinned-actions@0b552a197e44b819629237e065d781f5ca691460 # v1.1.1
with:
Expand Down
28 changes: 20 additions & 8 deletions .github/workflows/TestPWTCommands.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,10 @@ jobs:
with:
filters: |
packages:
- 'packages/**/*'
- 'packages/generator-widget/*'
- 'packages/pluggable-widgets-tools/*'
tests:
- 'tests/**/*'
- 'packages/command-tests/*'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Expand All @@ -38,24 +39,35 @@ jobs:
env:
cache-name: cache-node-modules
with:
path: ~/.npm
path: ~/.pnpm-store
key: ${{ runner.os }}-${{ matrix.node }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}

- name: Setup pnpm
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda #v4.1.0
if: matrix.node == 16
with:
version: 8
- name: Setup pnpm
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda #v4.1.0
if: matrix.node == 18
with:
version: 10

- name: "Defining node version"
uses: actions/setup-node@1f8c6b94b26d0feae1e387ca63ccbdc44d27b561 # v2
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
node-version: ${{ matrix.node == 18 && '18.15.0' || matrix.node }}
cache: 'pnpm'

- name: "Installing dependencies"
working-directory: ./
if: steps.filter.outputs.packages == 'true' || steps.filter.outputs.tests == 'true'
run: npm install
run: pnpm install

- name: Increase number of watchers
if: (steps.filter.outputs.packages == 'true' || steps.filter.outputs.tests == 'true') && startsWith(matrix.os, 'ubuntu')
run: echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

- name: "Testing PWT commands"
working-directory: ./
working-directory: ./packages/command-tests
if: steps.filter.outputs.packages == 'true' || steps.filter.outputs.tests == 'true'
run: npm run test:pwt:commands
run: pnpm test
25 changes: 12 additions & 13 deletions .github/workflows/UnitTests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,30 +33,29 @@ jobs:
env:
cache-name: cache-node-modules
with:
path: ~/.npm
path: ~/.pnpm-store
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}

- name: Setup pnpm
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda #v4.1.0
with:
version: 10

- name: "Defining node version"
uses: actions/setup-node@1f8c6b94b26d0feae1e387ca63ccbdc44d27b561 # v2
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
node-version-file: ".nvmrc"
cache: 'pnpm'

- name: "Installing dependencies"
working-directory: ./
if: steps.filter.outputs.packages == 'true'
run: npm install
run: pnpm install

- name: "Running pluggable-widgets-tools unit tests"
working-directory: ./packages/pluggable-widgets-tools
if: steps.filter.outputs.packages == 'true'
run: npm run test

- name: "Running generator-widget unit tests"
working-directory: ./packages/generator-widget
- name: "Running unit tests"
if: steps.filter.outputs.packages == 'true'
run: npm run test
run: pnpm -r test

- name: "Linting generator-widget"
working-directory: ./packages/generator-widget
if: steps.filter.outputs.packages == 'true'
run: npm run lint
run: pnpm run lint
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ node_modules
mxproject
coverage

# tests
# Packed packages
mendix-*.tgz
Loading
Loading