Skip to content
Open
Show file tree
Hide file tree
Changes from all 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
166 changes: 119 additions & 47 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,49 +1,121 @@
version: 2
updates:
- package-ecosystem: npm
directory: "/"
schedule:
interval: daily
open-pull-requests-limit: 10
ignore:
- dependency-name: "@types/node"
versions:
- 14.14.26
- 14.14.32
- 14.14.33
- 14.14.34
- 14.14.35
- 14.14.36
- 14.14.37
- 14.14.39
- 14.14.41
- 15.0.0
- dependency-name: y18n
versions:
- 4.0.1
- 4.0.2
- dependency-name: "@types/jest"
versions:
- 26.0.21
- 26.0.22
- dependency-name: ts-jest
versions:
- 26.5.4
- dependency-name: "@nestjs/core"
versions:
- 7.6.12
- 7.6.14
- 7.6.9
- dependency-name: "@nestjs/common"
versions:
- 7.6.12
- 7.6.14
- 7.6.9
- dependency-name: "@nestjs/testing"
versions:
- 7.6.12
- 7.6.14
- 7.6.9
- dependency-name: typescript
versions:
- 4.1.5
- package-ecosystem: npm
directory: "/"

# Update schedule: Run checks for dependency updates every Monday at 08:00 UTC
schedule:
interval: weekly # Changed from daily to weekly for stability
day: monday # Ensure updates happen at the beginning of the week
time: "08:00" # Time (UTC) to trigger dependency checks

# Limits the number of open PRs from Dependabot to avoid excessive PRs
open-pull-requests-limit: 5

# Labels to categorize Dependabot PRs
labels:
- "dependencies"
- "security"
- "automerge"

# Dependencies to ignore (prevents unnecessary updates to specific versions)
ignore:
- dependency-name: "@types/node"
versions:
- 14.14.26
- 14.14.32
- 14.14.33
- 14.14.34
- 14.14.35
- 14.14.36
- 14.14.37
- 14.14.39
- 14.14.41
- 15.0.0
- dependency-name: y18n
versions:
- 4.0.1
- 4.0.2
- dependency-name: "@types/jest"
versions:
- 26.0.21
- 26.0.22
- dependency-name: ts-jest
versions:
- 26.5.4
- 29.2.5
- dependency-name: "@nestjs/core"
versions:
- 7.6.12
- 7.6.14
- 7.6.9
- 9.4.3
- dependency-name: "@nestjs/common"
versions:
- 7.6.12
- 7.6.14
- 7.6.9
- 9.0.5
- dependency-name: "@nestjs/testing"
versions:
- 7.6.12
- 7.6.14
- 7.6.9
- 9.0.5
- dependency-name: typescript
versions:
- 4.1.5
- 4.0.5 # Older version before upgrade
- 5.7.3 # Ignore outdated versions after upgrade
- dependency-name: typeorm
versions:
- 0.3.17
- 0.3.20
- dependency-name: rxjs
versions:
- 6.5.2
- 7.1.0
- dependency-name: sqlite3
versions:
- 5.1.7
- dependency-name: cross-env
versions:
- 7.0.3
- dependency-name: npm-run-all2
versions:
- 7.0.2

# Group minor and patch updates to reduce the number of PRs
groups:
minor-dependencies:
patterns:
- "*" # Applies to all dependencies
update-types:
- "minor"
- "patch"

# Customize commit messages for better PR descriptions
commit-message:
prefix: "chore(deps)"
include: scope # Adds dependency scope (e.g., "chore(deps): bump jest from X to Y")

# Automatically rebase PRs when conflicts occur
rebase-strategy: "auto"

# Only update direct and development dependencies
allow:
- dependency-type: "direct"
- dependency-type: "development"

# Prefer increasing versions rather than using version ranges
versioning-strategy: increase

# Assign reviewers and assignees to Dependabot PRs
reviewers:
- "@bashleigh" # Replace with actual GitHub user/team
assignees:
- "@bashleigh"

# Enable automatic security updates for dependencies
security-updates:
enable: true
68 changes: 21 additions & 47 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,68 +1,42 @@
# This is a basic workflow to help you get started with Actions
# GitHub Actions Workflow for Running Tests & Building the Project

name: Tests

# Controls when the action will run.
on:
# Triggers the workflow on push or pull request events but only for the master branch
push:
branches: [ master ]
branches: [master, main]
pull_request:
branches: [ master ]

# Allows you to run this workflow manually from the Actions tab
branches: [master, main]
workflow_dispatch:

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
test:
# The type of runner that the job will run on
runs-on: ubuntu-latest
env:
COMPOSE_FILE: ./docker-compose.yml

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2

- name: env sync
run: cp .env.dist .env && export $(cat ./.env | xargs)
- name: Checkout repository
uses: actions/checkout@v3

# Runs a single command using the runners shell
- name: build docker db
run: docker-compose up -d

- name: install
run: yarn install --ignore-scripts

- name: build
run: yarn build
- name: Sync environment variables
run: cp .env.dist .env && export $(grep -v '^#' .env | xargs)

- name: Start Docker services
run: docker compose up -d # Updated to modern command

- name: check docker
run: docker-compose up -d
- name: Install dependencies
run: yarn install --frozen-lockfile

- name: docker logs
run: docker-compose logs && docker-compose ps
- name: Build project
run: yarn build

# Runs a set of commands using the runners shell
- name: tests
run: yarn test --coverage
- name: Check Docker services
run: docker compose ps && docker compose logs

- name: Coveralls Parallel
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
flag-name: run-${{ matrix.test_number }}
parallel: true
- name: Run tests with coverage (using npm-run-all2)
run: npx npm-run-all2 -p test test:cov

coverage:
needs: test
runs-on: ubuntu-latest
steps:
- name: Coveralls coverage
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
parallel-finished: true
- name: Store test coverage results
if: success()
run: mv coverage/lcov.info coverage.lcov # Ensures consistent coverage file location
5 changes: 0 additions & 5 deletions coveralls.json

This file was deleted.

2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi
var __exportStar = (this && this.__exportStar) || function(m, exports) {
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
};
exports.__esModule = true;
Object.defineProperty(exports, "__esModule", { value: true });
__exportStar(require("./dist"), exports);
Loading