Compare commits

...

17 Commits

Author SHA1 Message Date
Rainer Killinger
aafc59f6bc refactor: remove deprecated "jetifier" 2025-06-12 18:21:44 +02:00
Rainer Killinger
67e483dc82 ci: let pnpm handle build dependencies 2025-06-12 18:19:16 +02:00
Rainer Killinger
09ce46ed7e fix: prettier package type 2025-06-12 14:48:32 +02:00
Rainer Killinger
69ca673701 ci: update android commandline tools 2025-06-12 14:34:01 +02:00
Rainer Killinger
a00ba67eb3 fix: prettier depencencies 2025-06-12 14:28:35 +02:00
Rainer Killinger
cbd4225ab5 refactor: rebase 2025-06-12 14:00:43 +02:00
a962a35a8b feat: update to node 22 2025-06-12 10:59:54 +02:00
25d18e681b feat: temporarily use external node image in ci 2025-06-12 10:57:04 +02:00
e34807f086 refactor: update node to 22 2025-06-12 10:57:00 +02:00
516168f8e6 fix: test 2025-06-12 10:56:43 +02:00
f4d357e382 fix: build 2025-06-12 10:56:42 +02:00
685ed84c12 refactor: update to ionic v8
refactor: remove deprecated @ionic-native/core (replaced by
@awesome-cordova-plugins/core)
2025-06-12 10:55:23 +02:00
6ef5641aa0 refactor: update ngx-markdown to v18 2025-06-12 10:54:00 +02:00
05aaa227a9 refactor: update capacitor to v6 2025-06-12 10:53:33 +02:00
af4c885e3e fix: angular warning 2025-06-12 10:50:43 +02:00
7b81e19c92 refactor: base migration to Angular v18 2025-06-12 10:50:31 +02:00
5dd966f23c refactor: remove deprecated "jetifier" 2025-06-12 10:48:20 +02:00
46 changed files with 15057 additions and 13492 deletions

View File

@@ -30,13 +30,11 @@ variables:
description: Bypass turbo cache description: Bypass turbo cache
default: default:
image: registry.gitlab.com/openstapps/openstapps/node-builder image: registry.gitlab.com/openstapps/openstapps/node-builder:node-22
tags: tags:
- saas-linux-xlarge-amd64 - saas-linux-xlarge-amd64
interruptible: true interruptible: true
before_script: before_script:
- corepack enable
- corepack prepare pnpm@latest-8 --activate
- echo TURBO_API=$TURBO_API >> .env.local - echo TURBO_API=$TURBO_API >> .env.local
- echo TURBO_TOKEN=$TURBO_TOKEN >> .env.local - echo TURBO_TOKEN=$TURBO_TOKEN >> .env.local
- echo TURBO_TEAM=$TURBO_TEAM >> .env.local - echo TURBO_TEAM=$TURBO_TEAM >> .env.local
@@ -63,7 +61,7 @@ build:
# - pnpm i --prefer-offline # - pnpm i --prefer-offline
# - pnpm build:full:skip || pnpm i -r --prefer-offline # - pnpm build:full:skip || pnpm i -r --prefer-offline
- pnpm install - pnpm install
# TODO: whats the benifit for CI? something doesn't work with git here... # TODO: whats the benfit for CI? something doesn't work with git here...
# "🦋 error Error: Failed to find where HEAD diverged from master. Does master exist?" # "🦋 error Error: Failed to find where HEAD diverged from master. Does master exist?"
# - pnpm changeset:status # - pnpm changeset:status
- pnpm build:full $TURBO_CACHE_BYPASS - pnpm build:full $TURBO_CACHE_BYPASS
@@ -101,7 +99,7 @@ stop review:
rules: *deploy-rules rules: *deploy-rules
unit: unit:
image: registry.gitlab.com/openstapps/openstapps/app-builder image: registry.gitlab.com/openstapps/openstapps/app-builder:node-22
stage: test stage: test
needs: ['build'] needs: ['build']
script: script:
@@ -109,9 +107,9 @@ unit:
# - pnpm i --prefer-offline # - pnpm i --prefer-offline
# - pnpm test:skip || pnpm i -r --prefer-offline # - pnpm test:skip || pnpm i -r --prefer-offline
- pnpm install - pnpm install
- cd node_modules/.pnpm/re2*/node_modules/re2 # - cd node_modules/.pnpm/re2*/node_modules/re2
- npm run install # - npm run install
- cd $CI_PROJECT_DIR # - cd $CI_PROJECT_DIR
- pnpm test $TURBO_CACHE_BYPASS - pnpm test $TURBO_CACHE_BYPASS
coverage: '/Statements[^:]*\:[^:]*\s+([\d\.]+)%/' coverage: '/Statements[^:]*\:[^:]*\s+([\d\.]+)%/'
artifacts: artifacts:

View File

@@ -1,6 +1,6 @@
.limit_scheduled_pipelines: .limit_scheduled_pipelines:
rules: rules:
- if: $CI_COMMIT_BRANCH == 'main' && $CI_PIPELINE_SOURCE == "schedule" - if: $CI_COMMIT_BRANCH == 'ionic-8-update' && $CI_PIPELINE_SOURCE == "schedule"
base image: base image:
image: docker image: docker
@@ -16,8 +16,7 @@ base image:
- > - >
docker login -u "${CI_REGISTRY_USER}" -p "${CI_JOB_TOKEN}" "${CI_REGISTRY}" && docker login -u "${CI_REGISTRY_USER}" -p "${CI_JOB_TOKEN}" "${CI_REGISTRY}" &&
docker build docker build
-t "${CI_REGISTRY_IMAGE}/${IMAGE_NAME}:$(grep -o '"version": "[^"]*' "${DEPLOY_DIR}/package.json" | cut -d'"' -f4)" -t "${CI_REGISTRY_IMAGE}/${IMAGE_NAME}:node-22" "${CI_PROJECT_DIR}/${DEPLOY_DIR}" &&
-t "${CI_REGISTRY_IMAGE}/${IMAGE_NAME}:latest" "${CI_PROJECT_DIR}/${DEPLOY_DIR}" &&
docker push "${CI_REGISTRY_IMAGE}/${IMAGE_NAME}" --all-tags docker push "${CI_REGISTRY_IMAGE}/${IMAGE_NAME}" --all-tags
cache: {} # disable irrelevant cache for this job cache: {} # disable irrelevant cache for this job
before_script: [] # do not run irrelevant before script for this job before_script: [] # do not run irrelevant before script for this job

View File

@@ -27,6 +27,7 @@ const config = {
'bin', 'bin',
'files', 'files',
'engines', 'engines',
'packageManager',
'scripts', 'scripts',
'dependencies', 'dependencies',
'devDependencies', 'devDependencies',

View File

@@ -1,3 +1,3 @@
nodejs 18.19.1 nodejs 22.16.0
pnpm 8.15.4 pnpm 10.12.1
python 3.11.5 python 3.11.5

View File

@@ -1,5 +1,5 @@
integration: integration:
image: registry.gitlab.com/openstapps/openstapps/node-builder image: registry.gitlab.com/openstapps/openstapps/node-builder:node-22
stage: test stage: test
needs: ['build'] needs: ['build']
variables: variables:

View File

@@ -51,7 +51,7 @@
"@types/cors": "2.8.13", "@types/cors": "2.8.13",
"@types/express": "4.17.17", "@types/express": "4.17.17",
"@types/geojson": "1.0.6", "@types/geojson": "1.0.6",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"@types/node-cron": "3.0.7", "@types/node-cron": "3.0.7",
"@types/nodemailer": "6.4.7", "@types/nodemailer": "6.4.7",
"@types/promise-queue": "2.2.0", "@types/promise-queue": "2.2.0",

View File

@@ -44,7 +44,7 @@
"@openstapps/logger": "workspace:*", "@openstapps/logger": "workspace:*",
"@types/config": "3.3.0", "@types/config": "3.3.0",
"@types/dockerode": "3.3.17", "@types/dockerode": "3.3.17",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"@types/sha1": "1.1.3", "@types/sha1": "1.1.3",
"config": "3.3.9", "config": "3.3.9",
"dockerode": "3.3.5", "dockerode": "3.3.5",
@@ -63,7 +63,7 @@
"@types/dockerode": "3.3.17", "@types/dockerode": "3.3.17",
"@types/mocha": "10.0.1", "@types/mocha": "10.0.1",
"@types/mustache": "4.2.2", "@types/mustache": "4.2.2",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"@types/proxyquire": "1.3.28", "@types/proxyquire": "1.3.28",
"@types/semver": "7.5.8", "@types/semver": "7.5.8",
"@types/sha1": "1.1.3", "@types/sha1": "1.1.3",

View File

@@ -17,7 +17,7 @@
], ],
"devDependencies": { "devDependencies": {
"@openstapps/tsconfig": "workspace:*", "@openstapps/tsconfig": "workspace:*",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"eslint": "8.57.0", "eslint": "8.57.0",
"typescript": "5.4.2" "typescript": "5.4.2"
}, },

View File

@@ -12,4 +12,4 @@ const config = {
endOfLine: 'lf' endOfLine: 'lf'
} }
export default config; module.exports = config;

View File

@@ -2,7 +2,7 @@
"name": "@openstapps/prettier-config", "name": "@openstapps/prettier-config",
"description": "StApps Prettier Config", "description": "StApps Prettier Config",
"version": "3.2.0", "version": "3.2.0",
"type": "module", "type": "commonjs",
"license": "GPL-3.0-only", "license": "GPL-3.0-only",
"repository": "git@gitlab.com:openstapps/prettier-config.git", "repository": "git@gitlab.com:openstapps/prettier-config.git",
"author": "Thea Schöbl <dev@theaninova.de>", "author": "Thea Schöbl <dev@theaninova.de>",

View File

@@ -56,7 +56,7 @@
"@types/glob": "8.1.0", "@types/glob": "8.1.0",
"@types/mocha": "10.0.1", "@types/mocha": "10.0.1",
"@types/mustache": "4.2.2", "@types/mustache": "4.2.2",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"@types/tmp": "0.2.3", "@types/tmp": "0.2.3",
"c8": "7.14.0", "c8": "7.14.0",
"chai": "4.3.7", "chai": "4.3.7",

View File

@@ -9,7 +9,7 @@ const args = files.map(it => `${it.split('/', 2)[1]}='${it}'`);
console.log( console.log(
'Collecting coverage...', 'Collecting coverage...',
await promisify(exec)(`cobertura-merge -o ./coverage.xml ${args.join(' ')}`), await promisify(exec)(`merge-cobertura -o ./coverage.xml ${args.join(' ')}`),
); );
const reportFiles = await glob('./*/*/coverage/report-junit.xml'); const reportFiles = await glob('./*/*/coverage/report-junit.xml');

View File

@@ -45,7 +45,7 @@
"@types/chai": "4.3.5", "@types/chai": "4.3.5",
"@types/chai-as-promised": "7.1.5", "@types/chai-as-promised": "7.1.5",
"@types/mocha": "10.0.1", "@types/mocha": "10.0.1",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"c8": "7.14.0", "c8": "7.14.0",
"chai": "4.3.7", "chai": "4.3.7",
"chai-as-promised": "7.1.1", "chai-as-promised": "7.1.1",

View File

@@ -42,7 +42,7 @@
"@openstapps/prettier-config": "workspace:*", "@openstapps/prettier-config": "workspace:*",
"@openstapps/tsconfig": "workspace:*", "@openstapps/tsconfig": "workspace:*",
"@types/express": "4.17.17", "@types/express": "4.17.17",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"tsup": "6.7.0", "tsup": "6.7.0",
"typescript": "5.4.2" "typescript": "5.4.2"
}, },

12
flake.lock generated
View File

@@ -5,11 +5,11 @@
"systems": "systems" "systems": "systems"
}, },
"locked": { "locked": {
"lastModified": 1709126324, "lastModified": 1710146030,
"narHash": "sha256-q6EQdSeUZOG26WelxqkmR7kArjgWCdw5sfJVHPH/7j8=", "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
"owner": "numtide", "owner": "numtide",
"repo": "flake-utils", "repo": "flake-utils",
"rev": "d465f4819400de7c8d874d50b982301f28a84605", "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -20,11 +20,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1709747860, "lastModified": 1717112898,
"narHash": "sha256-RT4zuBy579m+l8VyIQFOR66WXfcs4g1jntZUHjh6eoI=", "narHash": "sha256-7R2ZvOnvd9h8fDd65p0JnB7wXfUvreox3xFdYWd1BnY=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "58ae79ea707579c40102ddf62d84b902a987c58b", "rev": "6132b0f6e344ce2fe34fc051b72fb46e34f668e0",
"type": "github" "type": "github"
}, },
"original": { "original": {

View File

@@ -11,7 +11,7 @@
flake-utils, flake-utils,
}: }:
let let
aapt2buildToolsVersion = "33.0.2"; aapt2buildToolsVersion = "34.0.0";
in in
flake-utils.lib.eachDefaultSystem ( flake-utils.lib.eachDefaultSystem (
system: system:
@@ -19,7 +19,7 @@
pkgs = import nixpkgs { pkgs = import nixpkgs {
inherit system; inherit system;
overlays = [ overlays = [
(final: prev: rec { (final: prev: {
fontMin = prev.python311.withPackages ( fontMin = prev.python311.withPackages (
ps: ps:
with ps; with ps;
@@ -30,21 +30,20 @@
++ (with fonttools.optional-dependencies; [ woff ]) ++ (with fonttools.optional-dependencies; [ woff ])
); );
android = prev.androidenv.composeAndroidPackages { android = prev.androidenv.composeAndroidPackages {
buildToolsVersions = [ buildToolsVersions = prev.lib.lists.unique [
"34.0.0" "34.0.0"
aapt2buildToolsVersion aapt2buildToolsVersion
]; ];
platformVersions = [ "34" ]; platformVersions = [ "34" ];
}; };
cypress = prev.cypress.overrideAttrs (cyPrev: rec { cypress = prev.cypress.overrideAttrs (cyPrev: rec {
version = "13.2.0"; version = "13.10.0";
src = prev.fetchzip { src = prev.fetchzip {
url = "https://cdn.cypress.io/desktop/${version}/linux-x64/cypress.zip"; url = "https://cdn.cypress.io/desktop/${version}/linux-x64/cypress.zip";
hash = "sha256-9o0nprGcJhudS1LNm+T7Vf0Dwd1RBauYKI+w1FBQ3ZM="; hash = "sha256-wKNXo2lWndsQaouOiul0rsOWah+RRQ6fljzdeC8/KW4=";
}; };
}); });
nodejs = prev.nodejs_18; nodejs = prev.nodejs_22;
corepack = prev.corepack_18;
}) })
]; ];
config = { config = {
@@ -54,7 +53,6 @@
}; };
androidFhs = pkgs.buildFHSUserEnv { androidFhs = pkgs.buildFHSUserEnv {
name = "android-env"; name = "android-env";
targetPkgs = pkgs: with pkgs; [ ];
runScript = "bash"; runScript = "bash";
profile = '' profile = ''
export ALLOW_NINJA_ENV=true export ALLOW_NINJA_ENV=true
@@ -68,7 +66,7 @@
nativeBuildInputs = [ androidFhs ]; nativeBuildInputs = [ androidFhs ];
buildInputs = with pkgs; [ buildInputs = with pkgs; [
nodejs nodejs
corepack nodePackages.pnpm
# tools # tools
curl curl
jq jq
@@ -83,6 +81,8 @@
GRADLE_OPTS = "-Dorg.gradle.project.android.aapt2FromMavenOverride=${ANDROID_SDK_ROOT}/build-tools/${aapt2buildToolsVersion}/aapt2"; GRADLE_OPTS = "-Dorg.gradle.project.android.aapt2FromMavenOverride=${ANDROID_SDK_ROOT}/build-tools/${aapt2buildToolsVersion}/aapt2";
CYPRESS_INSTALL_BINARY = "0"; CYPRESS_INSTALL_BINARY = "0";
CYPRESS_RUN_BINARY = "${pkgs.cypress}/bin/Cypress"; CYPRESS_RUN_BINARY = "${pkgs.cypress}/bin/Cypress";
# https://github.com/nodejs/node/issues/48444#issuecomment-1591882694
UV_USE_IO_URING = "0";
}; };
} }
); );

View File

@@ -1,12 +1,12 @@
e2e: e2e:
image: registry.gitlab.com/openstapps/openstapps/app-cypress:node-18 image: registry.gitlab.com/openstapps/openstapps/app-cypress:node-22
stage: test stage: test
script: script:
- pnpm --filter=@openstapps/app install - pnpm install
- pnpm --filter=@openstapps/app exec cypress install - pnpm --filter=@openstapps/app exec cypress install
- cd node_modules/.pnpm/re2*/node_modules/re2 # - cd node_modules/.pnpm/re2*/node_modules/re2
- npm run install # - npm run install
- cd $CI_PROJECT_DIR # - cd $CI_PROJECT_DIR
- pnpm test:integration:app - pnpm test:integration:app
artifacts: artifacts:
when: on_failure when: on_failure

View File

@@ -51,7 +51,7 @@ include ':capacitor-splash-screen'
project(':capacitor-splash-screen').projectDir = new File('../../../node_modules/.pnpm/@capacitor+splash-screen@6.0.1_@capacitor+core@6.1.1/node_modules/@capacitor/splash-screen/android') project(':capacitor-splash-screen').projectDir = new File('../../../node_modules/.pnpm/@capacitor+splash-screen@6.0.1_@capacitor+core@6.1.1/node_modules/@capacitor/splash-screen/android')
include ':transistorsoft-capacitor-background-fetch' include ':transistorsoft-capacitor-background-fetch'
project(':transistorsoft-capacitor-background-fetch').projectDir = new File('../../../node_modules/.pnpm/@transistorsoft+capacitor-background-fetch@5.2.0_@capacitor+core@6.1.1/node_modules/@transistorsoft/capacitor-background-fetch/android') project(':transistorsoft-capacitor-background-fetch').projectDir = new File('../../../node_modules/.pnpm/@transistorsoft+capacitor-background-fetch@6.0.0_@capacitor+core@6.0.0/node_modules/@transistorsoft/capacitor-background-fetch/android')
include ':capacitor-secure-storage-plugin' include ':capacitor-secure-storage-plugin'
project(':capacitor-secure-storage-plugin').projectDir = new File('../../../node_modules/.pnpm/capacitor-secure-storage-plugin@0.9.0_@capacitor+core@6.1.1/node_modules/capacitor-secure-storage-plugin/android') project(':capacitor-secure-storage-plugin').projectDir = new File('../../../node_modules/.pnpm/capacitor-secure-storage-plugin@0.10.0_@capacitor+core@6.0.0/node_modules/capacitor-secure-storage-plugin/android')

View File

@@ -1,11 +1,11 @@
#!/usr/bin/env bash #!/usr/bin/env bash
rm coverage/integration-report-junit-*.xml rm coverage/integration-report-junit-*.xml || true
ng e2e --watch=false --headless=true --browser="$BROWSER" ng e2e --watch=false --headless=true --browser="$BROWSER"
exit_code=$? exit_code=$?
jrm coverage/integration-report-junit.xml coverage/integration-report-junit-*.xml jrm coverage/integration-report-junit.xml coverage/integration-report-junit-*.xml || true
rm coverage/integration-report-junit-*.xml rm coverage/integration-report-junit-*.xml || true
exit $exit_code exit $exit_code

View File

@@ -14,9 +14,7 @@
"Thea Schöbl <dev@theaninova.de>" "Thea Schöbl <dev@theaninova.de>"
], ],
"scripts": { "scripts": {
"analyze": "webpack-bundle-analyzer www/stats.json", "build": "pnpm check-icons && ng build --configuration=production --stats-json",
"build": "pnpm check-icons && ng build --configuration=production --stats-json && webpack-bundle-analyzer www/stats.json --mode static --report www/bundle-info.html --no-open",
"build:analyze": "npm run build:stats && npm run analyze",
"build:android": "ionic capacitor build android --no-open && cd android && ./gradlew clean assemble && cd ..", "build:android": "ionic capacitor build android --no-open && cd android && ./gradlew clean assemble && cd ..",
"build:prod": "ng build --configuration=production", "build:prod": "ng build --configuration=production",
"build:stats": "ng build --configuration=production --stats-json", "build:stats": "ng build --configuration=production --stats-json",
@@ -39,7 +37,6 @@
"lint": "ng lint && stylelint \"**/*.scss\"", "lint": "ng lint && stylelint \"**/*.scss\"",
"lint:fix": "eslint --fix -c .eslintrc.json --ignore-path .eslintignore --ext .ts,.html src/ && stylelint --fix \"**/*.scss\"", "lint:fix": "eslint --fix -c .eslintrc.json --ignore-path .eslintignore --ext .ts,.html src/ && stylelint --fix \"**/*.scss\"",
"minify-icons": "node scripts/minify-icon-font.mjs", "minify-icons": "node scripts/minify-icon-font.mjs",
"postinstall": "jetify && echo \"skipping jetify in production mode\"",
"preview": "http-server www --p 8101 -o", "preview": "http-server www --p 8101 -o",
"push": "git push && git push origin \"v$npm_package_version\"", "push": "git push && git push origin \"v$npm_package_version\"",
"resources:ios": "capacitor-assets generate --ios --iconBackgroundColor $(grep -oE \"^@include ion-color\\(primary, #[a-fA-F0-9]{3,6}\" src/theme/colors.scss | grep -oE \"#[a-fA-F0-9]{3,6}\") --splashBackgroundColor $(grep -oE \"^@include ion-color\\(primary, #[a-fA-F0-9]{3,6}\" src/theme/colors.scss | grep -oE \"#[a-fA-F0-9]{3,6}\")", "resources:ios": "capacitor-assets generate --ios --iconBackgroundColor $(grep -oE \"^@include ion-color\\(primary, #[a-fA-F0-9]{3,6}\" src/theme/colors.scss | grep -oE \"#[a-fA-F0-9]{3,6}\") --splashBackgroundColor $(grep -oE \"^@include ion-color\\(primary, #[a-fA-F0-9]{3,6}\" src/theme/colors.scss | grep -oE \"#[a-fA-F0-9]{3,6}\")",
@@ -52,13 +49,13 @@
"test:integration": "sh integration-test.sh" "test:integration": "sh integration-test.sh"
}, },
"dependencies": { "dependencies": {
"@angular/animations": "17.3.0", "@angular/animations": "18.0.1",
"@angular/cdk": "17.3.0", "@angular/cdk": "18.0.1",
"@angular/common": "17.3.0", "@angular/common": "18.0.1",
"@angular/core": "17.3.0", "@angular/core": "18.0.1",
"@angular/forms": "17.3.0", "@angular/forms": "18.0.1",
"@angular/platform-browser": "17.3.0", "@angular/platform-browser": "18.0.1",
"@angular/router": "17.3.0", "@angular/router": "18.0.1",
"@awesome-cordova-plugins/calendar": "6.6.0", "@awesome-cordova-plugins/calendar": "6.6.0",
"@awesome-cordova-plugins/core": "6.6.0", "@awesome-cordova-plugins/core": "6.6.0",
"@capacitor-community/screen-brightness": "6.0.0", "@capacitor-community/screen-brightness": "6.0.0",
@@ -79,7 +76,7 @@
"@capacitor/share": "6.0.1", "@capacitor/share": "6.0.1",
"@capacitor/splash-screen": "6.0.1", "@capacitor/splash-screen": "6.0.1",
"@ionic-native/core": "5.36.0", "@ionic-native/core": "5.36.0",
"@ionic/angular": "7.8.0", "@ionic/angular": "8.2.0",
"@ionic/storage-angular": "4.0.0", "@ionic/storage-angular": "4.0.0",
"@maplibre/ngx-maplibre-gl": "17.4.1", "@maplibre/ngx-maplibre-gl": "17.4.1",
"@ngx-translate/core": "15.0.0", "@ngx-translate/core": "15.0.0",
@@ -88,25 +85,26 @@
"@openstapps/api": "workspace:*", "@openstapps/api": "workspace:*",
"@openstapps/collection-utils": "workspace:*", "@openstapps/collection-utils": "workspace:*",
"@openstapps/core": "workspace:*", "@openstapps/core": "workspace:*",
"@transistorsoft/capacitor-background-fetch": "5.2.0", "@transistorsoft/capacitor-background-fetch": "6.0.0",
"@types/dom-view-transitions": "1.0.4", "@types/dom-view-transitions": "1.0.4",
"capacitor-secure-storage-plugin": "0.9.0", "capacitor-secure-storage-plugin": "0.10.0",
"cordova-plugin-calendar": "5.1.6", "cordova-plugin-calendar": "5.1.6",
"date-fns": "3.6.0", "date-fns": "3.6.0",
"deepmerge": "4.3.1", "deepmerge": "4.3.1",
"form-data": "4.0.0", "form-data": "4.0.0",
"geojson": "0.5.0", "geojson": "0.5.0",
"ionic-appauth": "0.9.0", "ionic-appauth": "0.9.0",
"jsonpath-plus": "10.0.7", "jsonpath-plus": "10.3.0",
"maplibre-gl": "4.0.2", "maplibre-gl": "4.0.2",
"material-symbols": "0.17.1", "material-symbols": "0.17.1",
"moment": "2.30.1", "moment": "2.30.1",
"ngx-date-fns": "11.0.0", "ngx-date-fns": "11.0.0",
"ngx-logger": "5.0.12", "ngx-logger": "5.0.12",
"ngx-markdown": "17.1.1", "ngx-markdown": "18.0.0",
"ngx-moment": "6.0.2", "ngx-moment": "6.0.2",
"opening_hours": "3.8.0", "opening_hours": "3.8.0",
"pmtiles": "3.0.3", "pmtiles": "3.0.3",
"prettier": "3.1.1",
"rxjs": "7.8.1", "rxjs": "7.8.1",
"semver": "7.6.0", "semver": "7.6.0",
"swiper": "8.4.5", "swiper": "8.4.5",
@@ -114,24 +112,24 @@
"zone.js": "0.14.4" "zone.js": "0.14.4"
}, },
"devDependencies": { "devDependencies": {
"@angular-devkit/architect": "0.1703.0", "@angular-devkit/architect": "0.1800.2",
"@angular-devkit/build-angular": "17.3.0", "@angular-devkit/build-angular": "18.0.2",
"@angular-devkit/core": "17.3.0", "@angular-devkit/core": "18.0.2",
"@angular-devkit/schematics": "17.3.0", "@angular-devkit/schematics": "18.0.2",
"@angular-eslint/builder": "17.3.0", "@angular-eslint/builder": "18.0.1",
"@angular-eslint/eslint-plugin": "17.3.0", "@angular-eslint/eslint-plugin": "18.0.1",
"@angular-eslint/eslint-plugin-template": "17.3.0", "@angular-eslint/eslint-plugin-template": "18.0.1",
"@angular-eslint/schematics": "17.3.0", "@angular-eslint/schematics": "18.0.1",
"@angular-eslint/template-parser": "17.3.0", "@angular-eslint/template-parser": "18.0.1",
"@angular/cli": "17.3.0", "@angular/cli": "18.0.2",
"@angular/compiler": "17.3.0", "@angular/compiler": "18.0.1",
"@angular/compiler-cli": "17.3.0", "@angular/compiler-cli": "18.0.1",
"@angular/language-server": "17.3.0", "@angular/language-server": "17.3.0",
"@angular/language-service": "17.3.0", "@angular/language-service": "18.0.1",
"@angular/platform-browser-dynamic": "17.3.0", "@angular/platform-browser-dynamic": "18.0.1",
"@capacitor/android": "6.1.1", "@capacitor/android": "6.1.1",
"@capacitor/assets": "3.0.4", "@capacitor/assets": "3.0.4",
"@capacitor/cli": "6.1.1", "@capacitor/cli": "7.3.0",
"@capacitor/ios": "6.1.1", "@capacitor/ios": "6.1.1",
"@compodoc/compodoc": "1.1.23", "@compodoc/compodoc": "1.1.23",
"@cypress/schematic": "2.5.1", "@cypress/schematic": "2.5.1",
@@ -148,12 +146,12 @@
"@types/karma": "6.3.8", "@types/karma": "6.3.8",
"@types/karma-coverage": "2.0.3", "@types/karma-coverage": "2.0.3",
"@types/karma-jasmine": "4.0.5", "@types/karma-jasmine": "4.0.5",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"@types/semver": "7.5.8", "@types/semver": "7.5.8",
"@typescript-eslint/eslint-plugin": "7.2.0", "@typescript-eslint/eslint-plugin": "7.2.0",
"@typescript-eslint/parser": "7.2.0", "@typescript-eslint/parser": "7.2.0",
"cordova-res": "0.15.4", "cordova-res": "0.15.4",
"cypress": "13.7.0", "cypress": "13.10.0",
"eslint": "8.57.0", "eslint": "8.57.0",
"eslint-plugin-jsdoc": "48.2.1", "eslint-plugin-jsdoc": "48.2.1",
"eslint-plugin-prettier": "5.1.3", "eslint-plugin-prettier": "5.1.3",
@@ -165,7 +163,6 @@
"is-docker": "2.2.1", "is-docker": "2.2.1",
"jasmine-core": "5.1.2", "jasmine-core": "5.1.2",
"jasmine-spec-reporter": "7.0.0", "jasmine-spec-reporter": "7.0.0",
"jetifier": "2.0.0",
"junit-report-merger": "6.0.3", "junit-report-merger": "6.0.3",
"karma": "6.4.3", "karma": "6.4.3",
"karma-chrome-launcher": "3.2.0", "karma-chrome-launcher": "3.2.0",
@@ -181,8 +178,7 @@
"stylelint-config-standard-scss": "13.0.0", "stylelint-config-standard-scss": "13.0.0",
"surge": "0.23.1", "surge": "0.23.1",
"ts-node": "10.9.2", "ts-node": "10.9.2",
"typescript": "5.4.2", "typescript": "5.4.2"
"webpack-bundle-analyzer": "4.10.1"
}, },
"cordova": { "cordova": {
"plugins": {}, "plugins": {},

View File

@@ -21,7 +21,7 @@ import {ModalController, Platform} from '@ionic/angular';
import {TranslateService} from '@ngx-translate/core'; import {TranslateService} from '@ngx-translate/core';
import {ThingTranslateService} from './translation/thing-translate.service'; import {ThingTranslateService} from './translation/thing-translate.service';
import {HttpClientTestingModule} from '@angular/common/http/testing'; import {provideHttpClientTesting} from '@angular/common/http/testing';
import {AppComponent} from './app.component'; import {AppComponent} from './app.component';
import {AuthModule} from './modules/auth/auth.module'; import {AuthModule} from './modules/auth/auth.module';
import {ConfigProvider} from './modules/config/config.provider'; import {ConfigProvider} from './modules/config/config.provider';
@@ -32,6 +32,7 @@ import {ScheduleSyncService} from './modules/background/schedule/schedule-sync.s
import {sampleAuthConfiguration} from './_helpers/data/sample-configuration'; import {sampleAuthConfiguration} from './_helpers/data/sample-configuration';
import {StorageProvider} from './modules/storage/storage.provider'; import {StorageProvider} from './modules/storage/storage.provider';
import {SimpleBrowser} from './util/browser.factory'; import {SimpleBrowser} from './util/browser.factory';
import {provideHttpClient, withInterceptorsFromDi} from '@angular/common/http';
describe('AppComponent', () => { describe('AppComponent', () => {
let platformReadySpy: any; let platformReadySpy: any;
@@ -75,8 +76,9 @@ describe('AppComponent', () => {
modalController = jasmine.createSpyObj('ModalController', ['create', 'dismiss', 'getTop']); modalController = jasmine.createSpyObj('ModalController', ['create', 'dismiss', 'getTop']);
TestBed.configureTestingModule({ TestBed.configureTestingModule({
imports: [RouterTestingModule.withRoutes([]), HttpClientTestingModule, AuthModule],
declarations: [AppComponent], declarations: [AppComponent],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
imports: [RouterTestingModule.withRoutes([]), AuthModule],
providers: [ providers: [
{provide: Platform, useValue: platformSpy}, {provide: Platform, useValue: platformSpy},
{provide: TranslateService, useValue: translateServiceSpy}, {provide: TranslateService, useValue: translateServiceSpy},
@@ -88,8 +90,9 @@ describe('AppComponent', () => {
{provide: StorageProvider, useValue: storageProvider}, {provide: StorageProvider, useValue: storageProvider},
{provide: SimpleBrowser, useValue: simpleBrowser}, {provide: SimpleBrowser, useValue: simpleBrowser},
{provide: ModalController, useValue: modalController}, {provide: ModalController, useValue: modalController},
provideHttpClient(withInterceptorsFromDi()),
provideHttpClientTesting(),
], ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
}).compileComponents(); }).compileComponents();
}); });

View File

@@ -13,7 +13,7 @@
* this program. If not, see <https://www.gnu.org/licenses/>. * this program. If not, see <https://www.gnu.org/licenses/>.
*/ */
import {CommonModule, LocationStrategy, PathLocationStrategy, registerLocaleData} from '@angular/common'; import {CommonModule, LocationStrategy, PathLocationStrategy, registerLocaleData} from '@angular/common';
import {HTTP_INTERCEPTORS, HttpClient, HttpClientModule} from '@angular/common/http'; import {HTTP_INTERCEPTORS, HttpClient, provideHttpClient, withInterceptorsFromDi} from '@angular/common/http';
import localeDe from '@angular/common/locales/de'; import localeDe from '@angular/common/locales/de';
import {APP_INITIALIZER, NgModule} from '@angular/core'; import {APP_INITIALIZER, NgModule} from '@angular/core';
import {BrowserModule} from '@angular/platform-browser'; import {BrowserModule} from '@angular/platform-browser';
@@ -161,7 +161,6 @@ export function createTranslateLoader(http: HttpClient) {
JobModule, JobModule,
FavoritesModule, FavoritesModule,
LibraryModule, LibraryModule,
HttpClientModule,
ProfilePageModule, ProfilePageModule,
FeedbackModule, FeedbackModule,
MapModule, MapModule,
@@ -221,6 +220,7 @@ export function createTranslateLoader(http: HttpClient) {
useClass: ServiceHandlerInterceptor, useClass: ServiceHandlerInterceptor,
multi: true, multi: true,
}, },
provideHttpClient(withInterceptorsFromDi()),
], ],
}) })
export class AppModule { export class AppModule {

View File

@@ -22,7 +22,7 @@ import {Requestor, StorageBackend} from '@openid/appauth';
import {TranslateService} from '@ngx-translate/core'; import {TranslateService} from '@ngx-translate/core';
import {PAIAAuthService} from './paia/paia-auth.service'; import {PAIAAuthService} from './paia/paia-auth.service';
import {StAppsWebHttpClient} from '../data/stapps-web-http-client.provider'; import {StAppsWebHttpClient} from '../data/stapps-web-http-client.provider';
import {HttpClientModule} from '@angular/common/http'; import {provideHttpClient, withInterceptorsFromDi} from '@angular/common/http';
import {SimpleBrowser} from '../../util/browser.factory'; import {SimpleBrowser} from '../../util/browser.factory';
import {LoggerTestingModule} from 'ngx-logger/testing'; import {LoggerTestingModule} from 'ngx-logger/testing';
@@ -54,7 +54,7 @@ describe('AuthHelperService', () => {
beforeEach(() => { beforeEach(() => {
TestBed.configureTestingModule({ TestBed.configureTestingModule({
imports: [HttpClientModule, LoggerTestingModule], imports: [LoggerTestingModule],
providers: [ providers: [
StAppsWebHttpClient, StAppsWebHttpClient,
{ {
@@ -88,6 +88,7 @@ describe('AuthHelperService', () => {
provide: SimpleBrowser, provide: SimpleBrowser,
useValue: simpleBrowserMock, useValue: simpleBrowserMock,
}, },
provideHttpClient(withInterceptorsFromDi()),
], ],
}); });
authHelperService = TestBed.inject(AuthHelperService); authHelperService = TestBed.inject(AuthHelperService);

View File

@@ -20,7 +20,7 @@ import {Browser} from 'ionic-appauth';
import {nowInSeconds, Requestor, StorageBackend} from '@openid/appauth'; import {nowInSeconds, Requestor, StorageBackend} from '@openid/appauth';
import {TranslateService} from '@ngx-translate/core'; import {TranslateService} from '@ngx-translate/core';
import {StAppsWebHttpClient} from '../data/stapps-web-http-client.provider'; import {StAppsWebHttpClient} from '../data/stapps-web-http-client.provider';
import {HttpClientModule} from '@angular/common/http'; import {provideHttpClient, withInterceptorsFromDi} from '@angular/common/http';
import {IonicStorage} from 'ionic-appauth/lib'; import {IonicStorage} from 'ionic-appauth/lib';
import {RouterModule} from '@angular/router'; import {RouterModule} from '@angular/router';
import {LoggerTestingModule} from 'ngx-logger/testing'; import {LoggerTestingModule} from 'ngx-logger/testing';
@@ -35,7 +35,7 @@ describe('AuthService', () => {
storageBackendSpy = jasmine.createSpyObj('StorageBackend', ['getItem']); storageBackendSpy = jasmine.createSpyObj('StorageBackend', ['getItem']);
TestBed.configureTestingModule({ TestBed.configureTestingModule({
imports: [HttpClientModule, LoggerTestingModule, RouterModule.forRoot([])], imports: [LoggerTestingModule, RouterModule.forRoot([])],
providers: [ providers: [
StAppsWebHttpClient, StAppsWebHttpClient,
{ {
@@ -54,6 +54,7 @@ describe('AuthService', () => {
useValue: storageBackendSpy, useValue: storageBackendSpy,
}, },
Requestor, Requestor,
provideHttpClient(withInterceptorsFromDi()),
], ],
}); });
defaultAuthService = TestBed.inject(DefaultAuthService); defaultAuthService = TestBed.inject(DefaultAuthService);

View File

@@ -37,8 +37,5 @@
{{ 'dashboard.jobs.noJobs' | translate }} {{ 'dashboard.jobs.noJobs' | translate }}
</ion-label> </ion-label>
</ion-item> </ion-item>
<ion-button slot="button-end" fill="clear" color="medium" [routerLink]="['/jobs']">
<ion-icon slot="icon-only" name="search" [size]="24"></ion-icon>
</ion-button>
} }
</stapps-section> </stapps-section>

View File

@@ -14,7 +14,7 @@
*/ */
import {ScrollingModule} from '@angular/cdk/scrolling'; import {ScrollingModule} from '@angular/cdk/scrolling';
import {CommonModule} from '@angular/common'; import {CommonModule} from '@angular/common';
import {HttpClientModule} from '@angular/common/http'; import {provideHttpClient, withInterceptorsFromDi} from '@angular/common/http';
import {NgModule} from '@angular/core'; import {NgModule} from '@angular/core';
import {FormsModule} from '@angular/forms'; import {FormsModule} from '@angular/forms';
import {IonicModule, Platform} from '@ionic/angular'; import {IonicModule, Platform} from '@ionic/angular';
@@ -181,12 +181,33 @@ import {ShareButtonComponent} from './elements/share-button.component';
PeriodicalDetailContentComponent, PeriodicalDetailContentComponent,
ShareButtonComponent, ShareButtonComponent,
], ],
exports: [
DataDetailComponent,
DataDetailContentComponent,
DataIconPipe,
DataListComponent,
DataListItemComponent,
DateSeriesListItemComponent,
PlaceListItemComponent,
SimpleCardComponent,
SkeletonListItemComponent,
SkeletonSimpleCardComponent,
SearchPageComponent,
SimpleDataListComponent,
OriginDetailComponent,
FavoriteButtonComponent,
TreeListComponent,
ExternalLinkComponent,
ArticleDetailContentComponent,
BookDetailContentComponent,
PeriodicalDetailContentComponent,
TitleCardComponent,
],
imports: [ imports: [
CommonModule, CommonModule,
DataRoutingModule, DataRoutingModule,
FormsModule, FormsModule,
MapWidgetComponent, MapWidgetComponent,
HttpClientModule,
IonicModule.forRoot(), IonicModule.forRoot(),
MarkdownModule.forRoot(), MarkdownModule.forRoot(),
MenuModule, MenuModule,
@@ -218,28 +239,7 @@ import {ShareButtonComponent} from './elements/share-button.component';
useFactory: browserFactory, useFactory: browserFactory,
deps: [Platform], deps: [Platform],
}, },
], provideHttpClient(withInterceptorsFromDi()),
exports: [
DataDetailComponent,
DataDetailContentComponent,
DataIconPipe,
DataListComponent,
DataListItemComponent,
DateSeriesListItemComponent,
PlaceListItemComponent,
SimpleCardComponent,
SkeletonListItemComponent,
SkeletonSimpleCardComponent,
SearchPageComponent,
SimpleDataListComponent,
OriginDetailComponent,
FavoriteButtonComponent,
TreeListComponent,
ExternalLinkComponent,
ArticleDetailContentComponent,
BookDetailContentComponent,
PeriodicalDetailContentComponent,
TitleCardComponent,
], ],
}) })
export class DataModule {} export class DataModule {}

View File

@@ -21,7 +21,7 @@ import {StAppsWebHttpClient} from '../data/stapps-web-http-client.provider';
import {StorageProvider} from '../storage/storage.provider'; import {StorageProvider} from '../storage/storage.provider';
import {LoggerTestingModule} from 'ngx-logger/testing'; import {LoggerTestingModule} from 'ngx-logger/testing';
import {MapModule} from '../map/map.module'; import {MapModule} from '../map/map.module';
import {HttpClientModule} from '@angular/common/http'; import {provideHttpClient, withInterceptorsFromDi} from '@angular/common/http';
import {StorageModule} from '../storage/storage.module'; import {StorageModule} from '../storage/storage.module';
import {DaiaHolding, DaiaService} from './protocol/response'; import {DaiaHolding, DaiaService} from './protocol/response';
import {Observable, of} from 'rxjs'; import {Observable, of} from 'rxjs';
@@ -47,7 +47,6 @@ describe('DaiaDataProvider', () => {
imports: [ imports: [
HebisModule, HebisModule,
MapModule, MapModule,
HttpClientModule,
StorageModule, StorageModule,
LoggerTestingModule, LoggerTestingModule,
TranslateModule.forRoot({ TranslateModule.forRoot({
@@ -62,6 +61,7 @@ describe('DaiaDataProvider', () => {
StAppsWebHttpClient, StAppsWebHttpClient,
StorageProvider, StorageProvider,
DaiaDataProvider, DaiaDataProvider,
provideHttpClient(withInterceptorsFromDi()),
], ],
}); });
daiaDataProvider = TestBed.inject(DaiaDataProvider); daiaDataProvider = TestBed.inject(DaiaDataProvider);

View File

@@ -14,7 +14,7 @@
*/ */
import {ScrollingModule} from '@angular/cdk/scrolling'; import {ScrollingModule} from '@angular/cdk/scrolling';
import {CommonModule} from '@angular/common'; import {CommonModule} from '@angular/common';
import {HttpClientModule} from '@angular/common/http'; import {provideHttpClient, withInterceptorsFromDi} from '@angular/common/http';
import {NgModule} from '@angular/core'; import {NgModule} from '@angular/core';
import {FormsModule} from '@angular/forms'; import {FormsModule} from '@angular/forms';
import {IonicModule} from '@ionic/angular'; import {IonicModule} from '@ionic/angular';
@@ -54,7 +54,6 @@ import {DaiaHoldingComponent} from './daia-availability/daia-holding.component';
FormsModule, FormsModule,
HebisRoutingModule, HebisRoutingModule,
IonIconModule, IonIconModule,
HttpClientModule,
IonicModule.forRoot(), IonicModule.forRoot(),
MarkdownModule.forRoot(), MarkdownModule.forRoot(),
MenuModule, MenuModule,
@@ -69,6 +68,11 @@ import {DaiaHoldingComponent} from './daia-availability/daia-holding.component';
ThingTranslateModule.forChild(), ThingTranslateModule.forChild(),
UtilModule, UtilModule,
], ],
providers: [HebisDataProvider, DaiaDataProvider, StAppsWebHttpClient], providers: [
HebisDataProvider,
DaiaDataProvider,
StAppsWebHttpClient,
provideHttpClient(withInterceptorsFromDi()),
],
}) })
export class HebisModule {} export class HebisModule {}

View File

@@ -14,7 +14,7 @@
*/ */
import {TestBed} from '@angular/core/testing'; import {TestBed} from '@angular/core/testing';
import {MapModule} from './map.module'; import {MapModule} from './map.module';
import {HttpClientModule} from '@angular/common/http'; import {provideHttpClient, withInterceptorsFromDi} from '@angular/common/http';
import {StorageModule} from '../storage/storage.module'; import {StorageModule} from '../storage/storage.module';
import {MapPosition, PositionService} from './position.service'; import {MapPosition, PositionService} from './position.service';
import {ConfigProvider} from '../config/config.provider'; import {ConfigProvider} from '../config/config.provider';
@@ -39,12 +39,13 @@ describe('PositionService', () => {
}, },
}); });
TestBed.configureTestingModule({ TestBed.configureTestingModule({
imports: [MapModule, HttpClientModule, StorageModule, LoggerTestingModule], imports: [MapModule, StorageModule, LoggerTestingModule],
providers: [ providers: [
{ {
provider: ConfigProvider, provider: ConfigProvider,
useValue: configProviderMock, useValue: configProviderMock,
}, },
provideHttpClient(withInterceptorsFromDi()),
], ],
}); });
positionService = TestBed.inject(PositionService); positionService = TestBed.inject(PositionService);

View File

@@ -15,7 +15,7 @@
import {CUSTOM_ELEMENTS_SCHEMA} from '@angular/core'; import {CUSTOM_ELEMENTS_SCHEMA} from '@angular/core';
import {ComponentFixture, TestBed} from '@angular/core/testing'; import {ComponentFixture, TestBed} from '@angular/core/testing';
import {HttpClientTestingModule} from '@angular/common/http/testing'; import {provideHttpClientTesting} from '@angular/common/http/testing';
import {RouterTestingModule} from '@angular/router/testing'; import {RouterTestingModule} from '@angular/router/testing';
import {AuthModule} from '../../auth/auth.module'; import {AuthModule} from '../../auth/auth.module';
import {ProfilePageComponent} from './profile-page.component'; import {ProfilePageComponent} from './profile-page.component';
@@ -27,6 +27,7 @@ import {ScheduleProvider} from '../../calendar/schedule.provider';
import {DataProvider} from '../../data/data.provider'; import {DataProvider} from '../../data/data.provider';
import {StAppsWebHttpClient} from '../../data/stapps-web-http-client.provider'; import {StAppsWebHttpClient} from '../../data/stapps-web-http-client.provider';
import {SimpleBrowser} from '../../../util/browser.factory'; import {SimpleBrowser} from '../../../util/browser.factory';
import {provideHttpClient, withInterceptorsFromDi} from '@angular/common/http';
describe('ProfilePage', () => { describe('ProfilePage', () => {
let component: ProfilePageComponent; let component: ProfilePageComponent;
@@ -47,7 +48,8 @@ describe('ProfilePage', () => {
TestBed.configureTestingModule({ TestBed.configureTestingModule({
declarations: [ProfilePageComponent], declarations: [ProfilePageComponent],
imports: [HttpClientTestingModule, RouterTestingModule, AuthModule, TranslateModule.forRoot()], schemas: [CUSTOM_ELEMENTS_SCHEMA],
imports: [RouterTestingModule, AuthModule, TranslateModule.forRoot()],
providers: [ providers: [
{provide: ConfigProvider, useValue: configProvider}, {provide: ConfigProvider, useValue: configProvider},
{provide: StorageProvider, useValue: storageProvider}, {provide: StorageProvider, useValue: storageProvider},
@@ -55,8 +57,9 @@ describe('ProfilePage', () => {
{provide: SimpleBrowser, useValue: simpleBrowser}, {provide: SimpleBrowser, useValue: simpleBrowser},
ScheduleProvider, ScheduleProvider,
DataProvider, DataProvider,
provideHttpClient(withInterceptorsFromDi()),
provideHttpClientTesting(),
], ],
schemas: [CUSTOM_ELEMENTS_SCHEMA],
}).compileComponents(); }).compileComponents();
}); });

View File

@@ -1,5 +1,5 @@
### Set base image ### Set base image
FROM ubuntu:20.04 FROM ubuntu:22.04
LABEL version="2.0.0" \ LABEL version="2.0.0" \
description="Build environment for the StApps app." \ description="Build environment for the StApps app." \
@@ -8,18 +8,18 @@ LABEL version="2.0.0" \
### Configure versions to install ### Configure versions to install
ENV ANDROID_APIS="android-34" \ ENV ANDROID_APIS="android-34" \
ANDROID_BUILD_TOOLS_VERSION="34.0.0" \ ANDROID_BUILD_TOOLS_VERSION="34.0.0" \
NODE_VERSION="22.x" \
NPM_VERSION="^10.0.0" \ NPM_VERSION="^10.0.0" \
IONIC_VERSION="^6.0.0" \ IONIC_VERSION="^7.0.0" \
CORDOVA_RES_VERSION="latest" \ CORDOVA_RES_VERSION="latest" \
### Configure download URLs ### Configure download URLs
ANDROID_SDK_TOOLS_DOWNLOAD_URL="https://dl.google.com/android/repository/commandlinetools-linux-6858069_latest.zip" \ ANDROID_SDK_TOOLS_DOWNLOAD_URL="https://dl.google.com/android/repository/commandlinetools-linux-13114758_latest.zip" \
GOOGLE_SIGNING_KEY_URL="https://dl-ssl.google.com/linux/linux_signing_key.pub" \ GOOGLE_SIGNING_KEY_URL="https://dl-ssl.google.com/linux/linux_signing_key.pub" \
GOOGLE_CHROME_REPOSITORY_URL="http://dl.google.com/linux/chrome/deb/" \ GOOGLE_CHROME_REPOSITORY_URL="http://dl.google.com/linux/chrome/deb/" \
### Android SDK path ### Android SDK path
ANDROID_SDK_ROOT="/opt/android-sdk" \ ANDROID_SDK_ROOT="/opt/android-sdk" \
### Installation files ### Installation files
SCRIPTS_DIRECTORY="scripts" \ SCRIPTS_DIRECTORY="scripts" \
NODE_SETUP_SCRIPT="node_setup.sh" \
TMP_PROJECT_NAME="tmp-project" TMP_PROJECT_NAME="tmp-project"
### Set $PATH ### Set $PATH
@@ -43,7 +43,7 @@ RUN apt-get update && \
git \ git \
gradle \ gradle \
ca-certificates-java \ ca-certificates-java \
python \ python3 \
python3-pip \ python3-pip \
software-properties-common \ software-properties-common \
ssh \ ssh \
@@ -54,9 +54,9 @@ RUN apt-get update && \
musl-dev \ musl-dev \
&& rm -rf /var/lib/apt/lists/* && rm -rf /var/lib/apt/lists/*
### Install Java Development Kit 17 ### Install Java Development Kit 21
RUN add-apt-repository -y ppa:openjdk-r/ppa && apt-get update && \ RUN add-apt-repository -y ppa:openjdk-r/ppa && apt-get update && \
apt-get install --no-install-recommends -y openjdk-17-jdk \ apt-get install --no-install-recommends -y openjdk-21-jdk \
&& rm -rf /var/lib/apt/lists/* && rm -rf /var/lib/apt/lists/*
### Setup the locale ### Setup the locale
@@ -96,25 +96,25 @@ RUN curl $ANDROID_SDK_TOOLS_DOWNLOAD_URL > /tmp/android-sdk.zip && \
sdkmanager "platforms;$ANDROID_APIS" "build-tools;$ANDROID_BUILD_TOOLS_VERSION" sdkmanager "platforms;$ANDROID_APIS" "build-tools;$ANDROID_BUILD_TOOLS_VERSION"
### Copy scripts directory into the tmp folder, so it's available to the following commands ### Copy scripts directory into the tmp folder, so it's available to the following commands
COPY $SCRIPTS_DIRECTORY/$NODE_SETUP_SCRIPT /tmp/
RUN bash /tmp/$NODE_SETUP_SCRIPT && apt-get install -y nodejs && \ RUN curl -fsSL https://deb.nodesource.com/setup_${NODE_VERSION} | bash && \
apt-get install -y nodejs && \
### Install wanted npm version ### Install wanted npm version
npm install -g --unsafe-perm npm@$NPM_VERSION && \ npm install -g --unsafe-perm npm@$NPM_VERSION && \
### Install needed global npm packages ### Install needed global npm packages
npm install -g --unsafe-perm @ionic/cli@$IONIC_VERSION cordova-res@$CORDOVA_RES_VERSION npm install -g --unsafe-perm @ionic/cli@$IONIC_VERSION cordova-res@$CORDOVA_RES_VERSION
RUN cd / && ionic start $TMP_PROJECT_NAME blank --type=angular --capacitor --no-git --no-interactive && \ RUN cd / && ionic start $TMP_PROJECT_NAME blank --type=angular --capacitor --no-git --no-interactive && \
cd $TMP_PROJECT_NAME && ionic capacitor add android && export NG_CLI_ANALYTICS=ci && ionic capacitor build android --no-open && \ cd $TMP_PROJECT_NAME && ionic capacitor add android && export NG_CLI_ANALYTICS=ci && ionic capacitor build android --no-open && \
cd android && ./gradlew assembleDebug && \ cd android && ./gradlew assembleDebug && \
cd / && rm -rf $TMP_PROJECT_NAME cd / && rm -rf $TMP_PROJECT_NAME
### Compatibility with musl libc ### Compatibility with musl libc
RUN ln -s /usr/lib/x86_64-linux-musl/libc.so /lib/libc.musl-x86_64.so.1 RUN ln -s /usr/lib/x86_64-linux-musl/libc.so /lib/libc.musl-x86_64.so.1
### PNPM ### PNPM
RUN corepack enable && corepack prepare pnpm@latest-8 --activate RUN corepack enable
### Set working directory ### Set working directory
WORKDIR /app WORKDIR /app

View File

@@ -1,108 +0,0 @@
#!/bin/bash
# Logger Function
log() {
local message="$1"
local type="$2"
local timestamp=$(date '+%Y-%m-%d %H:%M:%S')
local color
local endcolor="\033[0m"
case "$type" in
"info") color="\033[38;5;79m" ;;
"success") color="\033[1;32m" ;;
"error") color="\033[1;31m" ;;
*) color="\033[1;34m" ;;
esac
echo -e "${color}${timestamp} - ${message}${endcolor}"
}
# Error handler function
handle_error() {
local exit_code=$1
local error_message="$2"
log "Error: $error_message (Exit Code: $exit_code)" "error"
exit $exit_code
}
# Function to check for command availability
command_exists() {
command -v "$1" &> /dev/null
}
check_os() {
if ! [ -f "/etc/debian_version" ]; then
echo "Error: This script is only supported on Debian-based systems."
exit 1
fi
}
# Function to Install the script pre-requisites
install_pre_reqs() {
log "Installing pre-requisites" "info"
# Run 'apt-get update'
if ! apt-get update -y; then
handle_error "$?" "Failed to run 'apt-get update'"
fi
# Run 'apt-get install'
if ! apt-get install -y apt-transport-https ca-certificates curl gnupg; then
handle_error "$?" "Failed to install packages"
fi
if ! mkdir -p /usr/share/keyrings; then
handle_error "$?" "Makes sure the path /usr/share/keyrings exist or run ' mkdir -p /usr/share/keyrings' with sudo"
fi
rm -f /usr/share/keyrings/nodesource.gpg || true
rm -f /etc/apt/sources.list.d/nodesource.list || true
# Run 'curl' and 'gpg'
if ! curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /usr/share/keyrings/nodesource.gpg; then
handle_error "$?" "Failed to download and import the NodeSource signing key"
fi
}
# Function to configure the Repo
configure_repo() {
local node_version=$1
arch=$(dpkg --print-architecture)
if [ "$arch" != "amd64" ] && [ "$arch" != "arm64" ] && [ "$arch" != "armhf" ]; then
handle_error "1" "Unsupported architecture: $arch. Only amd64, arm64, and armhf are supported."
fi
echo "deb [arch=$arch signed-by=/usr/share/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$node_version nodistro main" | tee /etc/apt/sources.list.d/nodesource.list > /dev/null
# N|solid Config
echo "Package: nsolid" | tee /etc/apt/preferences.d/nsolid > /dev/null
echo "Pin: origin deb.nodesource.com" | tee -a /etc/apt/preferences.d/nsolid > /dev/null
echo "Pin-Priority: 600" | tee -a /etc/apt/preferences.d/nsolid > /dev/null
# Nodejs Config
echo "Package: nodejs" | tee /etc/apt/preferences.d/nodejs > /dev/null
echo "Pin: origin deb.nodesource.com" | tee -a /etc/apt/preferences.d/nodejs > /dev/null
echo "Pin-Priority: 600" | tee -a /etc/apt/preferences.d/nodejs > /dev/null
# Run 'apt-get update'
if ! apt-get update -y; then
handle_error "$?" "Failed to run 'apt-get update'"
else
log "Repository configured successfully."
log "To install Node.js, run: apt-get install nodejs -y" "info"
log "You can use N|solid Runtime as a node.js alternative" "info"
log "To install N|solid Runtime, run: apt-get install nsolid -y \n" "success"
fi
}
# Define Node.js version
NODE_VERSION="18.x"
# Check OS
check_os
# Main execution
install_pre_reqs || handle_error $? "Failed installing pre-requisites"
configure_repo "$NODE_VERSION" || handle_error $? "Failed configuring repository"

View File

@@ -1,5 +1,5 @@
### Set base image ### Set base image
FROM cypress/base:18.16.1 FROM cypress/base:22.16.0
USER root USER root
@@ -61,9 +61,9 @@ ENV DBUS_SESSION_BUS_ADDRESS=/dev/null
# install Firefox browser # install Firefox browser
RUN export FIREFOX_VERSION=$(curl -fsSL https://product-details.mozilla.org/1.0/firefox_versions.json | jq -r '.LATEST_FIREFOX_VERSION') && \ RUN export FIREFOX_VERSION=$(curl -fsSL https://product-details.mozilla.org/1.0/firefox_versions.json | jq -r '.LATEST_FIREFOX_VERSION') && \
wget --no-verbose -O /tmp/firefox.tar.bz2 "https://download-installer.cdn.mozilla.net/pub/firefox/releases/${FIREFOX_VERSION}/linux-x86_64/en-US/firefox-${FIREFOX_VERSION}.tar.bz2" && \ wget --no-verbose -O /tmp/firefox.tar.xz "https://download-installer.cdn.mozilla.net/pub/firefox/releases/${FIREFOX_VERSION}/linux-x86_64/en-US/firefox-${FIREFOX_VERSION}.tar.xz" && \
tar -C /opt -xjf /tmp/firefox.tar.bz2 && \ tar -C /opt -xJf /tmp/firefox.tar.xz && \
rm /tmp/firefox.tar.bz2 && \ rm /tmp/firefox.tar.xz && \
ln -fs /opt/firefox/firefox /usr/bin/firefox ln -fs /opt/firefox/firefox /usr/bin/firefox
RUN echo "Downloading Latest Edge version..." RUN echo "Downloading Latest Edge version..."
@@ -83,6 +83,9 @@ RUN apt-get update && \
# Add a link to the browser that allows Cypress to find it # Add a link to the browser that allows Cypress to find it
RUN ln -s /usr/bin/microsoft-edge /usr/bin/edge RUN ln -s /usr/bin/microsoft-edge /usr/bin/edge
### PNPM
RUN corepack enable
# versions of local tools # versions of local tools
RUN echo " node version: $(node -v) \n" \ RUN echo " node version: $(node -v) \n" \
"npm version: $(npm -v) \n" \ "npm version: $(npm -v) \n" \

View File

@@ -1,7 +1,9 @@
FROM node:18-alpine3.18 FROM node:22-alpine
RUN apk update && apk add git curl jq && mkdir -p /opt RUN apk update && apk add git curl jq && mkdir -p /opt
RUN corepack enable
COPY --chown=root:root wait-for.sh /opt/wait-for COPY --chown=root:root wait-for.sh /opt/wait-for
RUN chmod +x /opt/wait-for && ln -s /opt/wait-for /usr/local/bin/wait-for RUN chmod +x /opt/wait-for && ln -s /opt/wait-for /usr/local/bin/wait-for

View File

@@ -1,7 +1,7 @@
FROM node:18-alpine3.18 FROM node:22-alpine
RUN apk update && apk add git jq curl python3 build-base RUN apk update && apk add git jq curl python3 build-base
RUN npm install turbo pnpm --global RUN corepack enable
CMD [] CMD []

View File

@@ -2,9 +2,10 @@
"name": "@openstapps/openstapps", "name": "@openstapps/openstapps",
"private": true, "private": true,
"engines": { "engines": {
"node": "^18.19.1", "node": "^22.16.0",
"pnpm": "^8.15.4" "pnpm": "^10.12.1"
}, },
"packageManager": "pnpm@10.12.1",
"scripts": { "scripts": {
"build": "dotenv -c -- turbo run build", "build": "dotenv -c -- turbo run build",
"build:full": "dotenv -c -- turbo run syncpack build lint format --summarize", "build:full": "dotenv -c -- turbo run syncpack build lint format --summarize",
@@ -31,7 +32,7 @@
"devDependencies": { "devDependencies": {
"@changesets/changelog-git": "0.1.14", "@changesets/changelog-git": "0.1.14",
"@changesets/cli": "2.26.1", "@changesets/cli": "2.26.1",
"cobertura-merge": "1.0.4", "merge-cobertura": "1.0.1",
"deepmerge": "4.3.1", "deepmerge": "4.3.1",
"dotenv-cli": "7.2.1", "dotenv-cli": "7.2.1",
"glob": "10.3.10", "glob": "10.3.10",
@@ -39,8 +40,8 @@
"junit-report-merger": "6.0.3", "junit-report-merger": "6.0.3",
"prettier": "3.1.1", "prettier": "3.1.1",
"syncpack": "12.3.0", "syncpack": "12.3.0",
"turbo": "1.10.16", "turbo": "1.13.3",
"turbo-ignore": "1.10.16", "turbo-ignore": "1.13.3",
"typedoc": "0.25.12", "typedoc": "0.25.12",
"typescript": "5.4.2" "typescript": "5.4.2"
} }

View File

@@ -38,15 +38,14 @@
"@openstapps/api": "workspace:*", "@openstapps/api": "workspace:*",
"@openstapps/core": "workspace:*", "@openstapps/core": "workspace:*",
"@openstapps/core-tools": "workspace:*", "@openstapps/core-tools": "workspace:*",
"@openstapps/eslint-config": "workspace:*",
"@openstapps/logger": "workspace:*", "@openstapps/logger": "workspace:*",
"@types/cli-progress": "3.11.0", "@types/cli-progress": "3.11.0",
"@types/express": "4.17.17", "@types/express": "4.17.17",
"@types/fs-extra": "9.0.13", "@types/fs-extra": "9.0.13",
"@types/json-schema": "7.0.11", "@types/json-schema": "7.0.15",
"@types/junit-report-builder": "3.0.0", "@types/junit-report-builder": "3.0.0",
"@types/mocha": "10.0.1", "@types/mocha": "10.0.1",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"@types/wait-on": "5.3.1", "@types/wait-on": "5.3.1",
"cli-progress": "3.12.0", "cli-progress": "3.12.0",
"commander": "10.0.0", "commander": "10.0.0",
@@ -55,6 +54,7 @@
"wait-on": "6.0.1" "wait-on": "6.0.1"
}, },
"devDependencies": { "devDependencies": {
"@openstapps/eslint-config": "workspace:*",
"@openstapps/prettier-config": "workspace:*", "@openstapps/prettier-config": "workspace:*",
"@openstapps/tsconfig": "workspace:*", "@openstapps/tsconfig": "workspace:*",
"@types/chai": "4.3.5", "@types/chai": "4.3.5",

View File

@@ -38,7 +38,7 @@
"@openstapps/logger": "workspace:*", "@openstapps/logger": "workspace:*",
"@types/body-parser": "1.19.2", "@types/body-parser": "1.19.2",
"@types/express": "4.17.17", "@types/express": "4.17.17",
"@types/json-schema": "7.0.11", "@types/json-schema": "7.0.15",
"@types/morgan": "1.9.4", "@types/morgan": "1.9.4",
"body-parser": "1.20.2", "body-parser": "1.20.2",
"express": "4.18.2", "express": "4.18.2",

View File

@@ -24,7 +24,7 @@
"@openstapps/tsconfig": "workspace:*", "@openstapps/tsconfig": "workspace:*",
"@types/chai": "4.3.5", "@types/chai": "4.3.5",
"@types/mocha": "10.0.1", "@types/mocha": "10.0.1",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"c8": "7.14.0", "c8": "7.14.0",
"chai": "4.3.7", "chai": "4.3.7",
"mocha": "10.2.0", "mocha": "10.2.0",

View File

@@ -62,7 +62,7 @@
"mustache": "4.2.0", "mustache": "4.2.0",
"openapi-types": "12.1.0", "openapi-types": "12.1.0",
"plantuml-encoder": "1.4.0", "plantuml-encoder": "1.4.0",
"re2": "1.18.2", "re2": "1.21.0",
"toposort": "2.0.2", "toposort": "2.0.2",
"ts-json-schema-generator": "1.2.0" "ts-json-schema-generator": "1.2.0"
}, },
@@ -73,10 +73,10 @@
"@types/chai": "4.3.5", "@types/chai": "4.3.5",
"@types/fs-extra": "9.0.13", "@types/fs-extra": "9.0.13",
"@types/glob": "8.1.0", "@types/glob": "8.1.0",
"@types/json-schema": "7.0.11", "@types/json-schema": "7.0.15",
"@types/mocha": "10.0.1", "@types/mocha": "10.0.1",
"@types/mustache": "4.2.2", "@types/mustache": "4.2.2",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"c8": "7.14.0", "c8": "7.14.0",
"chai": "4.3.7", "chai": "4.3.7",
"mocha": "10.2.0", "mocha": "10.2.0",

View File

@@ -60,9 +60,9 @@
"@openstapps/tsconfig": "workspace:*", "@openstapps/tsconfig": "workspace:*",
"@types/chai": "4.3.5", "@types/chai": "4.3.5",
"@types/json-patch": "0.0.30", "@types/json-patch": "0.0.30",
"@types/json-schema": "7.0.11", "@types/json-schema": "7.0.15",
"@types/mocha": "10.0.1", "@types/mocha": "10.0.1",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"c8": "7.14.0", "c8": "7.14.0",
"chai": "4.3.7", "chai": "4.3.7",
"conditional-type-checks": "1.0.6", "conditional-type-checks": "1.0.6",

View File

@@ -34,7 +34,7 @@
"@openstapps/tsconfig": "workspace:*", "@openstapps/tsconfig": "workspace:*",
"@types/chai": "4.3.5", "@types/chai": "4.3.5",
"@types/mocha": "10.0.1", "@types/mocha": "10.0.1",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"c8": "7.14.0", "c8": "7.14.0",
"chai": "4.3.7", "chai": "4.3.7",
"mocha": "10.2.0", "mocha": "10.2.0",

View File

@@ -37,7 +37,7 @@
"@openstapps/eslint-config": "workspace:*", "@openstapps/eslint-config": "workspace:*",
"@openstapps/prettier-config": "workspace:*", "@openstapps/prettier-config": "workspace:*",
"@openstapps/tsconfig": "workspace:*", "@openstapps/tsconfig": "workspace:*",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"ts-node": "10.9.2", "ts-node": "10.9.2",
"tsup": "6.7.0", "tsup": "6.7.0",
"typedoc": "0.25.12", "typedoc": "0.25.12",

View File

@@ -41,7 +41,7 @@
"@types/chai-as-promised": "7.1.5", "@types/chai-as-promised": "7.1.5",
"@types/chai-spies": "1.0.3", "@types/chai-spies": "1.0.3",
"@types/mocha": "10.0.1", "@types/mocha": "10.0.1",
"@types/node": "18.15.3", "@types/node": "22.15.31",
"c8": "7.14.0", "c8": "7.14.0",
"chai": "4.3.7", "chai": "4.3.7",
"chai-as-promised": "7.1.1", "chai-as-promised": "7.1.1",

28075
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff

View File

@@ -4,4 +4,18 @@ packages:
- "examples/*" - "examples/*"
- "frontend/*" - "frontend/*"
- "packages/*" - "packages/*"
- "images/*" - "images/*"
onlyBuiltDependencies:
- '@compodoc/compodoc'
- cpu-features
- cypress
- esbuild
- lmdb
- msgpackr-extract
- nice-napi
- nx
- re2
- sharp
- ssh2
- swiper