18d6d98e07
- C#-Plugin "DOSSIER" mit 23 nativen Commands (dWall, dDoor, ..., dSection)
- Native Command-Namen + Autocomplete + saubere History
- Idle-Defer + RhinoCode-API → kein _-RunPythonScript-Echo
- Yak-Paket via build.sh, Install in ~/Library/.../packages/8.0/
- Launcher (Tauri):
- dossier_init Tauri-Command + Setup-Tab in Settings
- Yak-Install + StartupCommands-XML + Window-Layout in einem Schritt
- clean-rhino.sh fuer reproduzierbare Resets
- check_dossier_initialized triggert Auto-Open-Setup beim ersten Start
- Wand-Architektur:
- Chain-Logik DEAKTIVIERT → jede Wand baut eigenes Volume (individuell
anwaehlbar, einzeln loeschbar)
- Polyline-Wand: jedes Segment = eigene Wand
- Smart-Split fuer wand_axis/decke/dach/raum/aussparung/traeger
- Auto-Group axis+volume → kein ChooseOne-Dialog, Delete loescht beides
- Stale-Mitre-Fix: Joint-Cache wird vor jedem Wand-Regen invalidiert
- T-Junction-Tolerance auf 1mm (war 1cm, lieferte falsche T-Mitres)
- Wand-Stile:
- Schema in dossier_project_settings.wand_styles (Material + Prio +
Default-Dicke + Referenz, oder Layered mit Schichten)
- dWall-Command Stil-Picker
- ProjectSettingsDialog: Sidebar-Layout (Pill-Selection) +
Wandstile-Tab mit Liste/Editor
- _wand_chain_compat benutzt style_id
- Prio-Dominanz: hoehere Prio gewinnt Eckverbindung, niedrigere wird
T-mitered (siehe _resolve_corner_miter)
- Cmd+G fuer Group (Geschoss-Up auf Alias 'gu')
- Welcome + Cheatsheet borderless mit X/Back-Buttons
- BeginCommand-Hook fuer Gestaltung-Panel-Auto-Open
- panel_base: Python.NET-Enum-Fix fuer Material-Render
62 lines
1.8 KiB
C#
62 lines
1.8 KiB
C#
// SPDX-License-Identifier: AGPL-3.0-or-later
|
|
// Copyright (C) 2026 Karim Gabriele Varano
|
|
using System;
|
|
using System.IO;
|
|
|
|
namespace DOSSIER;
|
|
|
|
/// <summary>
|
|
/// Locator-Pfade fuer das DOSSIER-Repo. Reihenfolge:
|
|
/// 1. Env-Var DOSSIER_HOME
|
|
/// 2. File ~/.dossier_home (eine Zeile mit dem Pfad)
|
|
/// 3. Hardcoded Fallback /Users/karim/STUDIO/DOSSIER (Dev-Setup)
|
|
/// </summary>
|
|
internal static class DossierPaths
|
|
{
|
|
private const string FallbackRoot = "/Users/karim/STUDIO/DOSSIER";
|
|
private const string MarkerFile = ".dossier_home";
|
|
|
|
private static string? _cachedRoot;
|
|
|
|
public static string? Root
|
|
{
|
|
get
|
|
{
|
|
if (_cachedRoot is not null) return _cachedRoot;
|
|
_cachedRoot = ResolveRoot();
|
|
return _cachedRoot;
|
|
}
|
|
}
|
|
|
|
public static string RhinoDir => Path.Combine(Root ?? FallbackRoot, "rhino");
|
|
|
|
public static string AliasDir => Path.Combine(RhinoDir, "aliases");
|
|
|
|
public static string CmdDir => Path.Combine(AliasDir, "cmd");
|
|
|
|
public static string ViewDir => Path.Combine(AliasDir, "view");
|
|
|
|
public static string StartupPy => Path.Combine(RhinoDir, "startup.py");
|
|
|
|
private static string? ResolveRoot()
|
|
{
|
|
var env = Environment.GetEnvironmentVariable("DOSSIER_HOME");
|
|
if (!string.IsNullOrEmpty(env) && Directory.Exists(env)) return env;
|
|
|
|
var home = Environment.GetFolderPath(Environment.SpecialFolder.UserProfile);
|
|
var marker = Path.Combine(home, MarkerFile);
|
|
if (File.Exists(marker))
|
|
{
|
|
try
|
|
{
|
|
var p = File.ReadAllText(marker).Trim();
|
|
if (!string.IsNullOrEmpty(p) && Directory.Exists(p)) return p;
|
|
}
|
|
catch { /* ignore */ }
|
|
}
|
|
|
|
if (Directory.Exists(FallbackRoot)) return FallbackRoot;
|
|
return null;
|
|
}
|
|
}
|