Skip to content

Commit

Permalink
chore(deps): upgrade node.js and all packages to latest compat
Browse files Browse the repository at this point in the history
  • Loading branch information
rozsival committed Aug 21, 2024
1 parent 5c87e43 commit e4c0e80
Show file tree
Hide file tree
Showing 10 changed files with 2,274 additions and 1,371 deletions.
3 changes: 0 additions & 3 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

yarn commitlint --edit "$1"
3 changes: 0 additions & 3 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

yarn lint-staged
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
16.15
22
1 change: 1 addition & 0 deletions .prettierrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@ module.exports = {
singleQuote: true,
tabWidth: 2,
trailingComma: 'all',
plugins: ['prettier-plugin-package'],
useTabs: false,
};
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:16.15
FROM node:22-alpine

COPY . .

Expand Down
59 changes: 31 additions & 28 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"name": "oribot",
"version": "0.0.1",
"version": "0.0.0",
"private": true,
"description": "Where's your worklog?",
"license": "UNLICENSED",
"author": "Vít Rozsíval <[email protected]>",
"engines": {
"node": ">=16.15"
"node": ">=22"
},
"scripts": {
"build": "NODE_ENV=production run-s build:clean build:ts",
Expand All @@ -15,7 +15,7 @@
"eslint": "eslint --cache --ext js,ts .",
"eslint:fix": "yarn eslint --fix",
"fix": "run-s ts prettier:fix eslint:fix",
"prepare": "is-ci || husky install",
"prepare": "is-ci || husky",
"prettier": "prettier --check './**/*.{html,json,md,yml}'",
"prettier:fix": "yarn prettier --write",
"qa": "run-s ts prettier eslint",
Expand All @@ -25,36 +25,39 @@
"ts": "tsc --project tsconfig.json"
},
"dependencies": {
"@slack/bolt": "3.12.1",
"consola": "2.15.3",
"dotenv": "16.0.2",
"node-schedule": "2.1.0",
"@slack/bolt": "3.21.1",
"consola": "3.2.3",
"dotenv": "16.4.5",
"node-schedule": "2.1.1",
"node-static": "0.7.11"
},
"devDependencies": {
"@commitlint/cli": "17.1.2",
"@commitlint/config-conventional": "17.1.0",
"@types/node": "16.11.42",
"@types/node-schedule": "2.1.0",
"@types/node-static": "0.7.7",
"@typescript-eslint/eslint-plugin": "5.36.2",
"@typescript-eslint/parser": "5.36.2",
"eslint": "8.19.0",
"@commitlint/cli": "19.4.0",
"@commitlint/config-conventional": "19.2.2",
"@types/node": "22.4.2",
"@types/node-schedule": "2.1.7",
"@types/node-static": "0.7.11",
"@typescript-eslint/eslint-plugin": "8.2.0",
"@typescript-eslint/parser": "8.2.0",
"eslint": "8.57.0",
"eslint-config-airbnb": "19.0.4",
"eslint-config-prettier": "8.5.0",
"eslint-import-resolver-typescript": "3.1.2",
"eslint-plugin-formatjs": "4.0.2",
"eslint-plugin-import": "2.26.0",
"eslint-plugin-prettier": "4.0.0",
"eslint-plugin-unicorn": "42.0.0",
"eslint-plugin-unused-imports": "2.0.0",
"husky": "8.0.1",
"eslint-config-prettier": "9.1.0",
"eslint-import-resolver-typescript": "3.6.1",
"eslint-plugin-formatjs": "4.13.3",
"eslint-plugin-import": "2.29.1",
"eslint-plugin-jsx-a11y": "6.9.0",
"eslint-plugin-prettier": "5.2.1",
"eslint-plugin-react": "7.35.0",
"eslint-plugin-react-hooks": "4.6.2",
"eslint-plugin-unicorn": "55.0.0",
"eslint-plugin-unused-imports": "3.2.0",
"husky": "9.1.5",
"is-ci": "3.0.1",
"lint-staged": "13.0.3",
"lint-staged": "15.2.9",
"npm-run-all": "4.1.5",
"prettier": "2.7.1",
"prettier-plugin-package": "1.3.0",
"rimraf": "3.0.2",
"typescript": "4.7.4"
"prettier": "3.3.3",
"prettier-plugin-package": "1.4.0",
"rimraf": "6.0.1",
"typescript": "5.5.4"
}
}
2 changes: 1 addition & 1 deletion public/index.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html>
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
Expand Down
2 changes: 1 addition & 1 deletion src/app.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* eslint-disable unicorn/no-process-exit */
/* eslint-disable unicorn/no-process-exit,unicorn/prefer-top-level-await */
import { Range, RecurrenceRule, scheduleJob } from 'node-schedule';

import { MAX_MONTH } from './constants';
Expand Down
12 changes: 8 additions & 4 deletions src/run.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,18 @@ const getMessage = () => {
const day = date.getDate();
logger.logInfo(`DAY: ${day}`);
switch (day) {
case getFirstMessageDay():
case getFirstMessageDay(): {
return createFirstMessage();
case getFirstNotificationDay():
}
case getFirstNotificationDay(): {
return createNotificationMessage(FIRST_NOTIFICATION_DAYS);
case getLastNotificationDay():
}
case getLastNotificationDay(): {
return createNotificationMessage(LAST_NOTIFICATION_DAYS);
case getFinalDay():
}
case getFinalDay(): {
return createFinalMessage();
}
}
};

Expand Down
Loading

0 comments on commit e4c0e80

Please sign in to comment.