diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 08ff6d063..0707b1ed2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,6 +1,6 @@ name: Build ZIP File -on: +on: pull_request: push: workflow_dispatch: @@ -19,7 +19,7 @@ jobs: node-version: 14 - name: Install dependencies - run: npm i + run: npm ci - name: Copy Webpack config run: cp ./webpack/.env-example ./webpack/.env @@ -50,7 +50,7 @@ jobs: rm postcss.config.js rm tsconfig.json rm webpack.config.js - + - name: Create & Upload artifact uses: actions/upload-artifact@v1 with: @@ -65,17 +65,17 @@ jobs: uses: actions/download-artifact@v1 with: name: ${{ github.event.repository.name }} - + - id: release_info uses: toolmantim/release-drafter@v5 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - + - name: Prepare for Release run: | cd ${{ github.event.repository.name }} zip -r ${{ github.event.repository.name }}.zip ${{ github.event.repository.name }} - + - name: Clean existing assets shell: bash run: | @@ -87,7 +87,7 @@ jobs: done env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - + - name: Publish to GitHub Release uses: actions/upload-release-asset@v1.0.1 env: diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index c4e5f145c..ec83ed0a2 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -24,7 +24,7 @@ jobs: node-version: ${{ matrix.node }} - name: Install dependencies - run: npm i + run: npm ci - name: Generate run: npm run build-storybook diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 266a89cc1..041619c08 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -13,7 +13,7 @@ jobs: node-version: '14.x' - name: Lint scss - run: npm install && npm run scss-lint + run: npm ci && npm run scss-lint eslint: name: ESLint runs-on: ubuntu-latest @@ -26,4 +26,4 @@ jobs: node-version: '14.x' - name: Lint js - run: touch ./webpack/.env && npm install && npm run lint + run: touch ./webpack/.env && npm ci && npm run lint diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 9fa349e4e..a138cc238 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -24,5 +24,5 @@ jobs: restore-keys: ${{ runner.os }}-node- - name: Run tests - run: npm install && npm run test + run: npm ci && npm run test working-directory: ./ diff --git a/.github/workflows/typecheck.yml b/.github/workflows/typecheck.yml index 0b5384808..e63aa535e 100644 --- a/.github/workflows/typecheck.yml +++ b/.github/workflows/typecheck.yml @@ -13,4 +13,4 @@ jobs: node-version: '14.x' - name: Build and check types - run: touch ./webpack/.env && npm install && npm run build + run: touch ./webpack/.env && npm ci && npm run build diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 6647e76f1..99cdb8af7 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -24,7 +24,7 @@ There are few things to do before you are ready to contribute. First you need to install every node module: -`npm i` +`npm ci` then create a `.env` file inside the *webpack* folder by copying `webpack/.env-example` and complete it with your environment's informations. Please use a free tcp port. @@ -35,7 +35,7 @@ then build assets: ### Good practices - Follow the BEM convention -- Be careful about creating SCSS files in the right folder, refer to the [documentation](https://build.prestashop.com/hummingbird/) for further informations. +- Be careful about creating SCSS files in the right folder, refer to the [documentation](https://build.prestashop.com/hummingbird/) for further informations. - When you want to submit a PR, please make sure that you ran both linters using `npm run lint-fix && npm run scss-fix` and fixed every lint issues. - If your PR is a work in progress, make sure that you use the Github draft mode. - Fill the PR template as much as possible, it's important to speed the process of testing, reviewing...