osrl - profile | config | clear

This commit is contained in:
babayaga 2025-12-29 09:42:55 +01:00
parent a7ee97717b
commit a8d2edf6a9
14 changed files with 154 additions and 38 deletions

View File

@ -23,7 +23,7 @@
"format": "unix-time"
}
],
"default": "2025-12-28T08:31:54.457Z"
"default": "2025-12-29T08:42:36.086Z"
},
"description": {
"type": "string",

File diff suppressed because one or more lines are too long

View File

@ -222,9 +222,9 @@
"osrl": {
"env": "astro-release",
"env_dev": "astro-debug",
"module_name": "polymech.io",
"module_name": "polymech.info",
"lang_flavor": "osr",
"product_profile": "./src/app/profile.json"
"product_profile": "./profile.json"
},
"features": {
"show_description": false,

48
app.log Normal file
View File

@ -0,0 +1,48 @@
{"level":"INFO","time":"2025-12-29T08:10:13.976Z","pid":25480,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:10:17.539Z","pid":25480,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json"}
{"level":"INFO","time":"2025-12-29T08:10:19.327Z","pid":25480,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:10:19.343Z","pid":25480,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:17:19.504Z","pid":19404,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:17:23.049Z","pid":19404,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:17:24.789Z","pid":19404,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:17:24.804Z","pid":19404,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:18:25.082Z","pid":15920,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:18:28.749Z","pid":15920,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:18:30.507Z","pid":15920,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:18:30.521Z","pid":15920,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:23:47.026Z","pid":15920,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:24:26.419Z","pid":24312,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:24:30.105Z","pid":24312,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:24:31.865Z","pid":24312,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:24:31.881Z","pid":24312,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:25:49.689Z","pid":25876,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:25:51.849Z","pid":25876,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:25:52.839Z","pid":25876,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:25:52.851Z","pid":25876,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:27:04.208Z","pid":27624,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:27:07.726Z","pid":27624,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:27:09.516Z","pid":27624,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:27:09.531Z","pid":27624,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:28:48.668Z","pid":16348,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:28:52.342Z","pid":16348,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:28:54.157Z","pid":16348,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:28:54.176Z","pid":16348,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:32:24.226Z","pid":27900,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:32:27.797Z","pid":27900,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:32:29.583Z","pid":27900,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:32:29.598Z","pid":27900,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:36:20.237Z","pid":2948,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:36:23.795Z","pid":2948,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:36:25.630Z","pid":2948,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:36:25.645Z","pid":2948,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:38:36.636Z","pid":14416,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:38:40.191Z","pid":14416,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:38:41.968Z","pid":14416,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:38:41.992Z","pid":14416,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:40:08.483Z","pid":11204,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:40:10.649Z","pid":11204,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:40:11.662Z","pid":11204,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:40:11.673Z","pid":11204,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:42:07.108Z","pid":16792,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:42:07.946Z","pid":16792,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from ./app-config.json for locale en"}
{"level":"INFO","time":"2025-12-29T08:42:29.585Z","pid":12492,"hostname":"DESKTOP-OL563U1","msg":"Loading library config from C:\\Users\\zx\\Desktop\\polymech\\library.polymech\\app-config.json for locale en"}

View File

@ -9,6 +9,7 @@
"dev:all": "concurrently \"npm run dev\" \"npm run serve:products\"",
"start": "astro dev",
"build": "pm-astro build -- --logLevel=info --branch=site-dev",
"build:clear": "sh scripts/clear.sh",
"test:build": "astro build ; cd dist ; serve",
"preview": "astro preview",
"astro": "astro",

41
profile.json Normal file
View File

@ -0,0 +1,41 @@
{
"includes": [],
"variables": {
"PRODUCT_ROOT": "${root}/${product}/",
"abs_url": "https://assets.osr-plastic.org",
"CACHE": "${root}/cache/",
"CACHE_URL": "${abs_url}/cache/",
"GIT_REPO": "https://git.polymech.io/",
"OSR_MACHINES_ASSETS_URL": "https://assets.osr-plastic.org",
"PRODUCTS_ASSETS_URL": "https://assets.osr-plastic.org/${product_rel}",
"OSR_FILES_WEB": "https://files.polymech.info/files/machines",
"PRODUCTS_FILES_URL": "${OSR_FILES_WEB}/${product_rel}",
"DISCORD": "https://discord.gg/s8K7yKwBRc"
},
"env": {
"astro-release": {
"includes": [
"${PRODUCT_ROOT}"
],
"variables": {
"OSR_MACHINES_ASSETS_URL": "https://assets.osr-plastic.org/"
}
},
"astro-debug": {
"includes": [
"${PRODUCT_ROOT}"
],
"variables": {
"OSR_MACHINES_ASSETS_URL": "https://assets.osr-plastic.org",
"showCart": false,
"showPrice": false,
"showResources": false,
"showShipping": false,
"showPaymentTerms": false,
"showHowtos": false,
"showRenderings": true,
"debug": true
}
}
}
}

2
scripts/clear.sh Normal file
View File

@ -0,0 +1,2 @@
rm -rf dist
rm -rf cache

View File

@ -1,6 +1,10 @@
---
import path from "path";
import { decode } from "html-entities";
import { sync as exists } from "@polymech/fs/exists";
import { sync as read } from "@polymech/fs/read";
import type { MarkdownHeading } from "astro";
import { IHowto, IStep, asset_local_rel } from "@/model/howto/howto.js";
import { translate } from "@polymech/astro-base/base/i18n.js";
import Translate from "@polymech/astro-base/components/i18n.astro";
@ -9,13 +13,11 @@ import Sidebar from "@polymech/astro-base/components/sidebar/Sidebar.astro";
import MobileToggle from "@polymech/astro-base/components/sidebar/MobileToggle.astro";
import Breadcrumb from "@polymech/astro-base/components/Breadcrumb.astro";
import { getSidebarConfig } from "@polymech/astro-base/config/sidebar";
import type { MarkdownHeading } from "astro";
import Wrapper from "@/components/containers/Wrapper.astro";
import Wrapper from "@polymech/astro-base/components/containers/Wrapper.astro";
import GalleryK from "@polymech/astro-base/components/GalleryK.astro";
import { files, forward_slash } from "@polymech/commons";
import pMap from "p-map";
import { sync as exists } from "@polymech/fs/exists";
import { sync as read } from "@polymech/fs/read";
import { createHTMLComponent, createMarkdownComponent } from "@/base/index.js";
import { applyFilters, shortenUrl } from "@/base/filters.js";

View File

@ -8,6 +8,7 @@ import { loadConfig } from '@polymech/astro-base/app/config-loader.js'
const config = loadConfig()
const LIBARY_BRANCH = config.retail.library_branch
const library = defineCollection({

View File

@ -2,7 +2,8 @@
import BaseHead from "../components/BaseHead.astro";
import Navigation from "@polymech/astro-base/components/global/Navigation.astro";
import Footer from "@polymech/astro-base/components/global/Footer.astro";
import { isRTL } from "config/config.js";
import { isRTL } from "../app/config.js";
const { item, additionalKeywords, ...rest } = Astro.props;
---

View File

@ -1,15 +1,17 @@
---
import BaseLayout from "@/layouts/BaseLayout.astro";
import BaseLayout from "../layouts/BaseLayout.astro";
Astro.redirect("/en/home");
---
<BaseLayout>
<section>
<div
class="flex flex-col gap-12 h-full justify-between p-4 text-center py-20">
class="flex flex-col gap-12 h-full justify-between p-4 text-center py-20"
>
<div class="max-w-xl mx-auto">
<h1
class="text-lg text-neutral-600 font-mono tracking-tight text-balance">
class="text-lg text-neutral-600 font-mono tracking-tight text-balance"
>
404 Page not found
</h1>
<p class="text-sm text-balance text-neutral-500">
@ -21,13 +23,15 @@ Astro.redirect("/en/home");
href="/"
title="link to your page"
aria-label="your label"
class="relative group overflow-hidden pl-4 font-mono h-14 flex space-x-6 items-center bg-white hover:bg-neutral-200 duration-300 rounded-xl w-full justify-between">
class="relative group overflow-hidden pl-4 font-mono h-14 flex space-x-6 items-center bg-white hover:bg-neutral-200 duration-300 rounded-xl w-full justify-between"
>
<span class="relative uppercase text-xs text-orange-600"
>Go home</span
>
<div
aria-hidden="true"
class="w-12 text-orange-600 transition duration-300 -translate-y-7 group-hover:translate-y-7">
class="w-12 text-orange-600 transition duration-300 -translate-y-7 group-hover:translate-y-7"
>
<div class="h-14 flex">
<svg
xmlns="http://www.w3.org/2000/svg"
@ -35,12 +39,12 @@ Astro.redirect("/en/home");
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
class="size-6 m-auto fill-white">
class="size-6 m-auto fill-white"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M17.25 8.25 21 12m0 0-3.75 3.75M21 12H3"
></path>
d="M17.25 8.25 21 12m0 0-3.75 3.75M21 12H3"></path>
</svg>
</div>
<div class="h-14 flex">
@ -50,12 +54,12 @@ Astro.redirect("/en/home");
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
class="size-6 m-auto fill-white">
class="size-6 m-auto fill-white"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M17.25 8.25 21 12m0 0-3.75 3.75M21 12H3"
></path>
d="M17.25 8.25 21 12m0 0-3.75 3.75M21 12H3"></path>
</svg>
</div>
</div>
@ -64,13 +68,14 @@ Astro.redirect("/en/home");
href="/forms/contact"
title="link to your page"
aria-label="your label"
class="relative group overflow-hidden pl-4 font-mono h-14 flex space-x-6 items-center bg-orange-500 hover:bg-black duration-300 rounded-xl w-full justify-between">
<span class="relative uppercase text-xs text-white"
>Contact us</span
class="relative group overflow-hidden pl-4 font-mono h-14 flex space-x-6 items-center bg-orange-500 hover:bg-black duration-300 rounded-xl w-full justify-between"
>
<span class="relative uppercase text-xs text-white">Contact us</span
>
<div
aria-hidden="true"
class="w-12 text-white transition duration-300 -translate-y-7 group-hover:translate-y-7">
class="w-12 text-white transition duration-300 -translate-y-7 group-hover:translate-y-7"
>
<div class="h-14 flex">
<svg
xmlns="http://www.w3.org/2000/svg"
@ -78,12 +83,12 @@ Astro.redirect("/en/home");
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
class="size-6 m-auto fill-white">
class="size-6 m-auto fill-white"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M17.25 8.25 21 12m0 0-3.75 3.75M21 12H3"
></path>
d="M17.25 8.25 21 12m0 0-3.75 3.75M21 12H3"></path>
</svg>
</div>
<div class="h-14 flex">
@ -93,12 +98,12 @@ Astro.redirect("/en/home");
viewBox="0 0 24 24"
stroke-width="1.5"
stroke="currentColor"
class="size-6 m-auto fill-white">
class="size-6 m-auto fill-white"
>
<path
stroke-linecap="round"
stroke-linejoin="round"
d="M17.25 8.25 21 12m0 0-3.75 3.75M21 12H3"
></path>
d="M17.25 8.25 21 12m0 0-3.75 3.75M21 12H3"></path>
</svg>
</div>
</div>

View File

@ -15,14 +15,29 @@
"esModuleInterop": true,
"skipLibCheck": true,
"baseUrl": ".",
"lib": ["DOM", "ES2015"],
"lib": [
"DOM",
"ES2015"
],
"resolveJsonModule": true,
"inlineSourceMap": true,
"sourceMap": true,
"inlineSources": true,
"paths": {
"@/*": ["src/*"],
"site/*": ["src/*"],
"config/*": ["src/config/*"]
"@/*": [
"src/*"
],
"site/*": [
"src/*"
],
"config/*": [
"src/config/*"
]
}
},
"include": [".astro/types.d.ts", "**/*.ts", "**/*.tsx", "**/*.astro"],
"include": [
".astro/types.d.ts",
"**/*.ts",
"**/*.tsx",
"**/*.astro"
],
}