Compare commits
11 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 087e91dca1 | |||
| 2de4cbc00f | |||
| 03fc465057 | |||
| b696b47feb | |||
| 6aae565541 | |||
| 214bd218a0 | |||
| 2afeee29ee | |||
| c8dee4c416 | |||
| f49f3c3b08 | |||
| c4bbb06710 | |||
| 4411cc4fff |
@@ -79,8 +79,8 @@ android {
|
|||||||
applicationId "com.ariacockpit"
|
applicationId "com.ariacockpit"
|
||||||
minSdkVersion rootProject.ext.minSdkVersion
|
minSdkVersion rootProject.ext.minSdkVersion
|
||||||
targetSdkVersion rootProject.ext.targetSdkVersion
|
targetSdkVersion rootProject.ext.targetSdkVersion
|
||||||
versionCode 10100
|
versionCode 10102
|
||||||
versionName "0.1.1.0"
|
versionName "0.1.1.2"
|
||||||
// Fallback fuer Libraries mit Product Flavors
|
// Fallback fuer Libraries mit Product Flavors
|
||||||
missingDimensionStrategy 'react-native-camera', 'general'
|
missingDimensionStrategy 'react-native-camera', 'general'
|
||||||
}
|
}
|
||||||
|
|||||||
+18
-17
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "aria-cockpit",
|
"name": "aria-cockpit",
|
||||||
"version": "0.1.1.0",
|
"version": "0.1.1.2",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"android": "react-native run-android",
|
"android": "react-native run-android",
|
||||||
@@ -10,31 +10,32 @@
|
|||||||
"build:apk": "cd android && ./gradlew assembleRelease"
|
"build:apk": "cd android && ./gradlew assembleRelease"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
"@react-native-async-storage/async-storage": "^1.21.0",
|
||||||
|
"@react-native-community/geolocation": "^3.2.1",
|
||||||
|
"@react-navigation/bottom-tabs": "^6.5.11",
|
||||||
|
"@react-navigation/native": "^6.1.9",
|
||||||
"react": "18.2.0",
|
"react": "18.2.0",
|
||||||
"react-native": "0.73.4",
|
"react-native": "0.73.4",
|
||||||
"@react-navigation/native": "^6.1.9",
|
"react-native-audio-recorder-player": "^3.6.7",
|
||||||
"@react-navigation/bottom-tabs": "^6.5.11",
|
"react-native-camera-kit": "^13.0.0",
|
||||||
"react-native-screens": "3.27.0",
|
|
||||||
"react-native-safe-area-context": "^4.8.2",
|
|
||||||
"react-native-document-picker": "^9.1.1",
|
"react-native-document-picker": "^9.1.1",
|
||||||
"react-native-sound": "^0.11.2",
|
"react-native-fs": "^2.20.0",
|
||||||
"@react-native-community/geolocation": "^3.2.1",
|
|
||||||
"react-native-image-picker": "^7.1.0",
|
"react-native-image-picker": "^7.1.0",
|
||||||
"react-native-permissions": "^4.1.4",
|
"react-native-permissions": "^4.1.4",
|
||||||
"react-native-camera-kit": "^13.0.0",
|
"react-native-safe-area-context": "^4.8.2",
|
||||||
"@react-native-async-storage/async-storage": "^1.21.0",
|
"react-native-screens": "3.27.0",
|
||||||
"react-native-fs": "^2.20.0",
|
"react-native-sound": "^0.11.2",
|
||||||
"react-native-audio-recorder-player": "^3.6.7"
|
"react-native-svg": "^14.1.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"typescript": "^5.3.3",
|
"@react-native/eslint-config": "^0.73.2",
|
||||||
|
"@react-native/metro-config": "^0.73.5",
|
||||||
|
"@react-native/typescript-config": "^0.73.1",
|
||||||
|
"@types/jest": "^29.5.11",
|
||||||
"@types/react": "^18.2.48",
|
"@types/react": "^18.2.48",
|
||||||
"@types/react-native": "^0.73.0",
|
"@types/react-native": "^0.73.0",
|
||||||
"@react-native/eslint-config": "^0.73.2",
|
|
||||||
"@react-native/typescript-config": "^0.73.1",
|
|
||||||
"@react-native/metro-config": "^0.73.5",
|
|
||||||
"metro-react-native-babel-preset": "^0.77.0",
|
|
||||||
"jest": "^29.7.0",
|
"jest": "^29.7.0",
|
||||||
"@types/jest": "^29.5.11"
|
"metro-react-native-babel-preset": "^0.77.0",
|
||||||
|
"typescript": "^5.3.3"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,25 +1,87 @@
|
|||||||
/**
|
/**
|
||||||
* MessageText — selektierbarer Chat-Text mit Android-Auto-Linkifizierung.
|
* MessageText — selektierbarer Chat-Text mit Android-Auto-Linkifizierung,
|
||||||
|
* plus Inline-Image-Rendering wenn der Text Bild-URLs enthaelt.
|
||||||
*
|
*
|
||||||
* Wir nutzen Androids dataDetectorType="all" (System macht Phone/URL/Email
|
* - Markdown-Syntax `` und plain `https://...image.png` werden
|
||||||
* automatisch klickbar) und ein einzelnes <Text selectable> ohne nested
|
* erkannt — die URL bleibt im Text sichtbar (klickbar via Linkify),
|
||||||
* <Text> mit eigenem onPress. Nested Text mit onPress fingen die Long-Press-
|
* zusaetzlich wird das Bild als <Image> oder <SvgUri> drunter gerendert.
|
||||||
* Geste ab, damit war Markieren+Kopieren defekt.
|
* - Wir nutzen Androids dataDetectorType="all" (System macht Phone/URL/Email
|
||||||
|
* automatisch klickbar) und ein einzelnes <Text selectable> ohne nested
|
||||||
|
* <Text> mit eigenem onPress — Nested Text mit onPress fing die Long-Press-
|
||||||
|
* Geste ab, damit war Markieren+Kopieren defekt.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import React from 'react';
|
import React, { useEffect, useState } from 'react';
|
||||||
import { Text, TextStyle, StyleProp } from 'react-native';
|
import { View, Text, Image, TextStyle, StyleProp } from 'react-native';
|
||||||
|
import { SvgUri } from 'react-native-svg';
|
||||||
|
|
||||||
interface Props {
|
interface Props {
|
||||||
text: string;
|
text: string;
|
||||||
style?: StyleProp<TextStyle>;
|
style?: StyleProp<TextStyle>;
|
||||||
}
|
}
|
||||||
|
|
||||||
const MessageText: React.FC<Props> = ({ text, style }) => {
|
// Bild-URL-Pattern: http(s)://... endend auf gaengige Bild-Endungen.
|
||||||
|
const IMG_URL_RE = /https?:\/\/[^\s)<"']+\.(?:jpe?g|png|gif|webp|bmp|ico|svg)(?:\?[^\s)<"']*)?/gi;
|
||||||
|
|
||||||
|
function extractImageUrls(text: string): string[] {
|
||||||
|
const urls = new Set<string>();
|
||||||
|
const matches = text.match(IMG_URL_RE);
|
||||||
|
if (matches) matches.forEach(u => urls.add(u));
|
||||||
|
return Array.from(urls);
|
||||||
|
}
|
||||||
|
|
||||||
|
const SVG_RE = /\.svg(?:\?|$)/i;
|
||||||
|
|
||||||
|
/** Image mit dynamischer Aspect-Ratio aus echten Bilddimensionen.
|
||||||
|
* SVGs werden ueber react-native-svg gerendert (kein Image.getSize). */
|
||||||
|
const InlineImage: React.FC<{ uri: string }> = ({ uri }) => {
|
||||||
|
const isSvg = SVG_RE.test(uri);
|
||||||
|
const [aspectRatio, setAspectRatio] = useState<number>(1);
|
||||||
|
const [failed, setFailed] = useState(false);
|
||||||
|
useEffect(() => {
|
||||||
|
if (isSvg) return; // Image.getSize geht fuer SVG nicht
|
||||||
|
let cancelled = false;
|
||||||
|
Image.getSize(
|
||||||
|
uri,
|
||||||
|
(w, h) => { if (!cancelled && w > 0 && h > 0) setAspectRatio(Math.max(0.5, Math.min(2.5, w / h))); },
|
||||||
|
() => { if (!cancelled) setFailed(true); },
|
||||||
|
);
|
||||||
|
return () => { cancelled = true; };
|
||||||
|
}, [uri, isSvg]);
|
||||||
|
if (failed) return null;
|
||||||
|
if (isSvg) {
|
||||||
|
return (
|
||||||
|
<View style={{ marginTop: 8, width: 260, height: 260, backgroundColor: '#0D0D1A', borderRadius: 8, alignItems: 'center', justifyContent: 'center' }}>
|
||||||
|
<SvgUri uri={uri} width="100%" height="100%" onError={() => setFailed(true)} />
|
||||||
|
</View>
|
||||||
|
);
|
||||||
|
}
|
||||||
return (
|
return (
|
||||||
<Text style={style} selectable dataDetectorType="all">
|
<Image
|
||||||
{text}
|
source={{ uri }}
|
||||||
</Text>
|
style={{ width: 260, aspectRatio, borderRadius: 8, marginTop: 8, backgroundColor: '#0D0D1A' }}
|
||||||
|
resizeMode="cover"
|
||||||
|
onError={() => setFailed(true)}
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
const MessageText: React.FC<Props> = ({ text, style }) => {
|
||||||
|
const imageUrls = extractImageUrls(text || '');
|
||||||
|
if (imageUrls.length === 0) {
|
||||||
|
return (
|
||||||
|
<Text style={style} selectable dataDetectorType="all">
|
||||||
|
{text}
|
||||||
|
</Text>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
return (
|
||||||
|
<View>
|
||||||
|
<Text style={style} selectable dataDetectorType="all">
|
||||||
|
{text}
|
||||||
|
</Text>
|
||||||
|
{imageUrls.map(u => <InlineImage key={u} uri={u} />)}
|
||||||
|
</View>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -24,6 +24,7 @@ import {
|
|||||||
} from 'react-native';
|
} from 'react-native';
|
||||||
import AsyncStorage from '@react-native-async-storage/async-storage';
|
import AsyncStorage from '@react-native-async-storage/async-storage';
|
||||||
import RNFS from 'react-native-fs';
|
import RNFS from 'react-native-fs';
|
||||||
|
import { SvgUri } from 'react-native-svg';
|
||||||
import rvs, { RVSMessage, ConnectionState } from '../services/rvs';
|
import rvs, { RVSMessage, ConnectionState } from '../services/rvs';
|
||||||
import audioService from '../services/audio';
|
import audioService from '../services/audio';
|
||||||
import wakeWordService from '../services/wakeword';
|
import wakeWordService from '../services/wakeword';
|
||||||
@@ -113,7 +114,9 @@ const ChatImage: React.FC<{
|
|||||||
onError: () => void;
|
onError: () => void;
|
||||||
}> = ({ uri, onPress, onError }) => {
|
}> = ({ uri, onPress, onError }) => {
|
||||||
const [aspectRatio, setAspectRatio] = useState<number>(4 / 3);
|
const [aspectRatio, setAspectRatio] = useState<number>(4 / 3);
|
||||||
|
const isSvg = /\.svg(?:\?|$)/i.test(uri);
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
|
if (isSvg) return; // SvgUri hat kein getSize
|
||||||
let cancelled = false;
|
let cancelled = false;
|
||||||
Image.getSize(uri, (w, h) => {
|
Image.getSize(uri, (w, h) => {
|
||||||
if (!cancelled && w > 0 && h > 0) {
|
if (!cancelled && w > 0 && h > 0) {
|
||||||
@@ -124,7 +127,16 @@ const ChatImage: React.FC<{
|
|||||||
}
|
}
|
||||||
}, () => {});
|
}, () => {});
|
||||||
return () => { cancelled = true; };
|
return () => { cancelled = true; };
|
||||||
}, [uri]);
|
}, [uri, isSvg]);
|
||||||
|
if (isSvg) {
|
||||||
|
return (
|
||||||
|
<TouchableOpacity onPress={onPress} activeOpacity={0.8}>
|
||||||
|
<View style={[CHAT_IMAGE_STYLE, { height: 260, alignItems: 'center', justifyContent: 'center' }]}>
|
||||||
|
<SvgUri uri={uri} width="100%" height="100%" onError={onError} />
|
||||||
|
</View>
|
||||||
|
</TouchableOpacity>
|
||||||
|
);
|
||||||
|
}
|
||||||
return (
|
return (
|
||||||
<TouchableOpacity onPress={onPress} activeOpacity={0.8}>
|
<TouchableOpacity onPress={onPress} activeOpacity={0.8}>
|
||||||
<Image
|
<Image
|
||||||
|
|||||||
+36
-13
@@ -52,11 +52,21 @@ Fuer Web-Anfragen: **WebFetch** oder **Bash mit curl**. Niemals sagen "ich habe
|
|||||||
4. **Regelmaessig committen** — mit sinnvollen Commit-Messages.
|
4. **Regelmaessig committen** — mit sinnvollen Commit-Messages.
|
||||||
5. **Tageslog fuehren** — was wurde getan, was ist offen.
|
5. **Tageslog fuehren** — was wurde getan, was ist offen.
|
||||||
|
|
||||||
## Dateien an Stefan zurueckgeben
|
## Dateien an Stefan zurueckgeben — KRITISCH
|
||||||
|
|
||||||
Wenn du eine Datei fuer Stefan erstellt hast (PDF, Bild, ausgefuelltes
|
**Das ist die EINZIGE Methode wie Stefan an Dateien rankommt. Ohne
|
||||||
Formular, Markdown, CSV, ZIP, ...), speichere sie unter `/shared/uploads/`
|
diese Schritte sieht und bekommt er die Datei NICHT.**
|
||||||
mit `aria_`-Prefix:
|
|
||||||
|
### Regel 1 — Speicher-Ort
|
||||||
|
|
||||||
|
Dateien fuer Stefan AUSSCHLIESSLICH unter `/shared/uploads/` speichern.
|
||||||
|
|
||||||
|
NIEMALS in:
|
||||||
|
- `/home/node/.openclaw/workspace/...` (das ist NUR dein Arbeitsverzeichnis,
|
||||||
|
Stefan hat keinen Zugriff darauf)
|
||||||
|
- `/tmp/...`, `/root/...`, oder sonst irgendwo
|
||||||
|
|
||||||
|
Dateinamen mit `aria_`-Prefix damit Cleanup-Scripts sie zuordnen koennen:
|
||||||
|
|
||||||
```
|
```
|
||||||
/shared/uploads/aria_<beschreibender_name>.<ext>
|
/shared/uploads/aria_<beschreibender_name>.<ext>
|
||||||
@@ -65,22 +75,35 @@ mit `aria_`-Prefix:
|
|||||||
Beispiele: `aria_termin_zusage.pdf`, `aria_einkaufsliste.md`,
|
Beispiele: `aria_termin_zusage.pdf`, `aria_einkaufsliste.md`,
|
||||||
`aria_logs_2026-05-10.zip`.
|
`aria_logs_2026-05-10.zip`.
|
||||||
|
|
||||||
Haenge dann am Ende deiner Antwort EINMALIG den Marker an:
|
### Regel 2 — Marker im Antworttext
|
||||||
|
|
||||||
|
Am Ende deiner Antwort EINMALIG den Marker setzen:
|
||||||
|
|
||||||
```
|
```
|
||||||
[FILE: /shared/uploads/aria_<name>.<ext>]
|
[FILE: /shared/uploads/aria_<name>.<ext>]
|
||||||
```
|
```
|
||||||
|
|
||||||
Der Marker wird automatisch aus dem sichtbaren Antworttext entfernt
|
OHNE diesen Marker erscheint die Datei NICHT in der App / Diagnostic.
|
||||||
(TTS liest ihn nicht vor) und als Datei-Anhang in der App und im
|
|
||||||
Diagnostic-Chat angezeigt — Stefan kann die Datei mit einem Klick
|
|
||||||
oeffnen (PDF-Viewer, Bildbetrachter, Standard-App per MIME-Type).
|
|
||||||
|
|
||||||
Mehrere Dateien in einer Antwort: einfach mehrere `[FILE: ...]`-Marker
|
Mehrere Dateien: mehrere `[FILE: ...]`-Marker am Ende, jeder in
|
||||||
am Ende, jeder in einer eigenen Zeile.
|
eigener Zeile.
|
||||||
|
|
||||||
Pfad muss zwingend mit `/shared/uploads/` beginnen — andere Pfade
|
### Beispiel — kompletter Workflow
|
||||||
werden ignoriert.
|
|
||||||
|
User: "Schreib mir ein Lasagne-Rezept als md-Datei"
|
||||||
|
|
||||||
|
1. Du schreibst die Datei: `Write` Tool mit Pfad `/shared/uploads/aria_lasagne.md`
|
||||||
|
2. Antwort an Stefan:
|
||||||
|
|
||||||
|
```
|
||||||
|
Hier dein Lasagne-Rezept — Ragu am Vortag, echter Parmesan,
|
||||||
|
Ruhezeit nicht skippen. Beim Schichten Bechamel auf jede Lage.
|
||||||
|
|
||||||
|
[FILE: /shared/uploads/aria_lasagne.md]
|
||||||
|
```
|
||||||
|
|
||||||
|
Der Marker wird automatisch aus dem sichtbaren Text entfernt und
|
||||||
|
als Anhang-Bubble angezeigt. Stefan tippt drauf → oeffnet die Datei.
|
||||||
|
|
||||||
## Stimme
|
## Stimme
|
||||||
|
|
||||||
|
|||||||
@@ -78,6 +78,89 @@ Wenn ein Tool nicht klappt, probiere die Alternative. Niemals sagen "ich habe ke
|
|||||||
- Destruktive Operationen (Dateien loeschen, Datenbanken droppen)
|
- Destruktive Operationen (Dateien loeschen, Datenbanken droppen)
|
||||||
- Push auf main
|
- Push auf main
|
||||||
|
|
||||||
|
## Dateien an Stefan zurueckgeben — KRITISCH
|
||||||
|
|
||||||
|
**Das ist die EINZIGE Methode wie Stefan an Dateien rankommt. Ohne diese
|
||||||
|
Schritte sieht und bekommt er die Datei NICHT.**
|
||||||
|
|
||||||
|
### Regel 1 — Speicher-Ort
|
||||||
|
|
||||||
|
Dateien fuer Stefan AUSSCHLIESSLICH unter `/shared/uploads/` speichern.
|
||||||
|
|
||||||
|
NIEMALS in:
|
||||||
|
- `/home/node/.openclaw/workspace/...` (NUR dein Arbeitsverzeichnis,
|
||||||
|
Stefan hat keinen Zugriff)
|
||||||
|
- `/tmp/...`, `/root/...`, oder sonst irgendwo
|
||||||
|
|
||||||
|
Dateinamen mit `aria_`-Prefix:
|
||||||
|
|
||||||
|
```
|
||||||
|
/shared/uploads/aria_<beschreibender_name>.<ext>
|
||||||
|
```
|
||||||
|
|
||||||
|
Beispiele: `aria_termin_zusage.pdf`, `aria_einkaufsliste.md`,
|
||||||
|
`aria_logs_2026-05-10.zip`.
|
||||||
|
|
||||||
|
### Regel 2 — Marker im Antworttext
|
||||||
|
|
||||||
|
Am Ende deiner Antwort EINMALIG den Marker setzen:
|
||||||
|
|
||||||
|
```
|
||||||
|
[FILE: /shared/uploads/aria_<name>.<ext>]
|
||||||
|
```
|
||||||
|
|
||||||
|
OHNE diesen Marker erscheint die Datei NICHT in der App / Diagnostic.
|
||||||
|
|
||||||
|
Mehrere Dateien: mehrere `[FILE: ...]`-Marker am Ende, jeder in
|
||||||
|
eigener Zeile.
|
||||||
|
|
||||||
|
### Beispiel — kompletter Workflow
|
||||||
|
|
||||||
|
User: "Schreib mir ein Lasagne-Rezept als md-Datei"
|
||||||
|
|
||||||
|
1. Du schreibst: `Write` Tool mit Pfad `/shared/uploads/aria_lasagne.md`
|
||||||
|
2. Antwort an Stefan:
|
||||||
|
|
||||||
|
```
|
||||||
|
Hier dein Lasagne-Rezept — Ragu am Vortag, echter Parmesan,
|
||||||
|
Ruhezeit nicht skippen. Beim Schichten Bechamel auf jede Lage.
|
||||||
|
|
||||||
|
[FILE: /shared/uploads/aria_lasagne.md]
|
||||||
|
```
|
||||||
|
|
||||||
|
Der Marker wird automatisch aus dem sichtbaren Text entfernt und
|
||||||
|
als Anhang-Bubble angezeigt. Stefan tippt drauf → oeffnet die Datei
|
||||||
|
im jeweiligen Standard-Programm.
|
||||||
|
|
||||||
|
### Externe Bilder/Dateien — IMMER runterladen, nicht nur verlinken
|
||||||
|
|
||||||
|
Wenn Stefan ein Bild oder eine Datei aus dem Netz haben will (Wikipedia,
|
||||||
|
Wiki Commons, ein Beispiel-PDF, etc.):
|
||||||
|
|
||||||
|
NICHT NUR die URL in die Antwort schreiben — das Bild ist dann nur
|
||||||
|
solange sichtbar wie der externe Server lebt.
|
||||||
|
|
||||||
|
STATTDESSEN:
|
||||||
|
1. Mit `Bash` + curl/wget herunterladen nach `/shared/uploads/aria_<name>.<ext>`
|
||||||
|
2. Mit `[FILE: ...]`-Marker als Anhang ausspielen
|
||||||
|
|
||||||
|
Beispiel — User: "Zeig mir ein Bild von Micky Maus"
|
||||||
|
|
||||||
|
```bash
|
||||||
|
curl -sL "https://upload.wikimedia.org/wikipedia/commons/7/7f/Mickey_Mouse.svg" \
|
||||||
|
-o /shared/uploads/aria_mickey_mouse.svg
|
||||||
|
```
|
||||||
|
|
||||||
|
Antwort:
|
||||||
|
```
|
||||||
|
Hier Micky Maus — offizielles SVG von Wikimedia Commons (Public Domain).
|
||||||
|
|
||||||
|
[FILE: /shared/uploads/aria_mickey_mouse.svg]
|
||||||
|
```
|
||||||
|
|
||||||
|
So bleibt das Bild permanent im Chat-Verlauf, auch wenn die Wiki-URL
|
||||||
|
spaeter offline geht oder umgezogen wird.
|
||||||
|
|
||||||
## Stimme
|
## Stimme
|
||||||
|
|
||||||
TTS laeuft ueber F5-TTS auf der Gamebox (Voice Cloning). Stefan kann
|
TTS laeuft ueber F5-TTS auf der Gamebox (Voice Cloning). Stefan kann
|
||||||
|
|||||||
@@ -993,7 +993,12 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (msg.type === 'chat_final') {
|
if (msg.type === 'chat_final') {
|
||||||
addChat('received', msg.text, 'chat:final');
|
// [FILE: /shared/uploads/aria_xxx.ext]-Marker aus dem Antworttext
|
||||||
|
// entfernen — die Datei kommt separat via file_from_aria.
|
||||||
|
// (Diagnostic empfaengt chat_final direkt vom Gateway, Bridge
|
||||||
|
// hat darum nicht filtern koennen.)
|
||||||
|
const cleaned = (msg.text || '').replace(/\[FILE:\s*\/shared\/uploads\/[^\]]+\]/gi, '').replace(/\n{3,}/g, '\n\n').trim();
|
||||||
|
addChat('received', cleaned, 'chat:final');
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (msg.type === 'file_from_aria') {
|
if (msg.type === 'file_from_aria') {
|
||||||
@@ -1503,6 +1508,7 @@
|
|||||||
`<a ${linkAttrs} style="color:#0096FF;text-decoration:underline;">${escapeHtml(name)}</a>` +
|
`<a ${linkAttrs} style="color:#0096FF;text-decoration:underline;">${escapeHtml(name)}</a>` +
|
||||||
` <span style="color:#888;font-size:11px;">(${escapeHtml(mimeType)}, ${sizeStr})</span>` +
|
` <span style="color:#888;font-size:11px;">(${escapeHtml(mimeType)}, ${sizeStr})</span>` +
|
||||||
preview +
|
preview +
|
||||||
|
`<div style="margin-top:4px;font-size:10px;color:#666;font-family:monospace;">${escapeHtml(serverPath)}</div>` +
|
||||||
`<div class="meta">ARIA-Datei — ${new Date().toLocaleTimeString('de-DE')}</div>`;
|
`<div class="meta">ARIA-Datei — ${new Date().toLocaleTimeString('de-DE')}</div>`;
|
||||||
for (const box of [chatBox, document.getElementById('chat-box-fs')]) {
|
for (const box of [chatBox, document.getElementById('chat-box-fs')]) {
|
||||||
if (!box) continue;
|
if (!box) continue;
|
||||||
|
|||||||
@@ -0,0 +1,43 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# ════════════════════════════════════════════════════════════
|
||||||
|
# ARIA — Setup-Script
|
||||||
|
#
|
||||||
|
# Materialisiert Config-Dateien aus *.example-Vorlagen wenn
|
||||||
|
# das Original fehlt. Wird einmalig nach git clone und nach
|
||||||
|
# jedem git pull empfohlen — schadet auch sonst nichts (idempotent,
|
||||||
|
# ueberschreibt nichts Bestehendes).
|
||||||
|
#
|
||||||
|
# Beispiele:
|
||||||
|
# aria-data/config/USER.md.example → USER.md (wenn nicht vorhanden)
|
||||||
|
# aria-data/config/aria.env.example → aria.env (wenn nicht vorhanden)
|
||||||
|
#
|
||||||
|
# Diese Files sind via .gitignore vom Repo ausgeschlossen — die
|
||||||
|
# Vorlagen liegen aber im Repo damit ein frisches Setup ohne lange
|
||||||
|
# Anleitung lauffaehig ist.
|
||||||
|
# ════════════════════════════════════════════════════════════
|
||||||
|
|
||||||
|
set -e
|
||||||
|
cd "$(dirname "$0")"
|
||||||
|
|
||||||
|
created=0
|
||||||
|
skipped=0
|
||||||
|
|
||||||
|
for example in aria-data/config/*.example; do
|
||||||
|
[ -f "$example" ] || continue
|
||||||
|
target="${example%.example}"
|
||||||
|
if [ -e "$target" ]; then
|
||||||
|
skipped=$((skipped + 1))
|
||||||
|
else
|
||||||
|
cp "$example" "$target"
|
||||||
|
echo "✓ $target erstellt aus $(basename "$example")"
|
||||||
|
created=$((created + 1))
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
if [ $created -eq 0 ]; then
|
||||||
|
echo "Alle Config-Dateien vorhanden ($skipped uebersprungen)."
|
||||||
|
else
|
||||||
|
echo ""
|
||||||
|
echo "$created Datei(en) angelegt, $skipped uebersprungen."
|
||||||
|
echo "Falls noetig anpassen: aria-data/config/"
|
||||||
|
fi
|
||||||
Reference in New Issue
Block a user