How tom4711/easyredminetool works
Purpose and runtime
EasyRedmineTool is a cross-platform .NET 10 desktop client for Redmine/Easy Redmine. It manages tickets, creates time entries, stores favorites, plans recurring bookings, and summarizes weekly hours. Avalonia 12 provides the macOS, Windows, and Linux UI; Redmine’s REST API is the only stated external service.
Entry point and composition
The application starts in src/EasyRedmineTool.Desktop/Program.cs, initializes Avalonia through src/EasyRedmineTool.Desktop/App.axaml, and registers the object graph in src/EasyRedmineTool.Desktop/DependencyInjection/ServiceCollectionExtensions.cs. Desktop-specific composition owns shell navigation and platform presentation; reusable business/UI state lives in Core.
Desktop shell and presentation boundary
src/EasyRedmineTool.Desktop/Views/MainWindow.axaml hosts the feature views, coordinated by src/EasyRedmineTool.Desktop/ViewModels/MainWindowViewModel.cs. Feature screens bind Core view models for ticket list, time entries, weekly summary, settings, and series booking. Avalonia views should remain presentation adapters, rather than owning API or persistence behavior.
Core MVVM application layer
Core view models orchestrate user actions and expose bindable state: src/EasyRedmineTool.Core/ViewModels/TicketListViewModel.cs, src/EasyRedmineTool.Core/ViewModels/TimeEntriesViewModel.cs, and src/EasyRedmineTool.Core/ViewModels/WeeklySummaryViewModel.cs. They depend on service interfaces, translate service results into rows/form state, and connect flows such as selecting a ticket from the summary to time entry creation.
Redmine integration and service boundary
src/EasyRedmineTool.Core/Api/EasyRedmineApiClient.cs is the HTTP/JSON boundary to Redmine, behind src/EasyRedmineTool.Core/Api/IEasyRedmineApiClient.cs; API failures are represented by src/EasyRedmineTool.Core/Api/RedmineApiException.cs. Domain services encapsulate workflows: src/EasyRedmineTool.Core/Services/TicketService.cs loads and merges ticket data, while src/EasyRedmineTool.Core/Services/TimeEntryService.cs loads activities/entries and submits creates or updates. API DTOs and request/response models isolate Redmine payload shape from UI state.
Local settings, cache, and connection flow
src/EasyRedmineTool.Core/Services/AppSettingsService.cs persists base URL, API key, theme, cached tickets, favorites, and last-entry defaults in the per-user settings file. src/EasyRedmineTool.Core/Services/ConnectionTestService.cs validates configured credentials through the API boundary. Credentials are intentionally local but unencrypted; no secrets belong in repository state.
Planning and reporting transformations
Recurring booking intent is expanded into dated preview/actions by src/EasyRedmineTool.Core/SeriesBookingPlanner.cs, consumed through src/EasyRedmineTool.Core/ViewModels/SeriesBookingViewModel.cs. Loaded time entries are aggregated into quarterly calendar-week and ticket totals by src/EasyRedmineTool.Core/WeeklySummaryBuilder.cs. These are deterministic domain transformations separate from HTTP and Avalonia rendering.
Delivery
The solution is EasyRedmineTool.slnx; GitHub Actions in .github/workflows/release.yml produces self-contained platform artifacts and GitHub Releases. The app targets Windows x64, macOS x64/ARM64, and Linux x64/ARM64.
Main entry points: MainWindow.axaml Main window · WeeklySummaryViewModel.cs Weekly summary VM · TimeEntriesViewModel.cs Time entries VM · TimeEntryService.cs Time entry service
Components 19
Desktop host
Avalonia startup, composition, and shell presentation.
- Program
src/EasyRedmineTool.Desktop/Program.cs - Avalonia app
src/EasyRedmineTool.Desktop/App.axaml - Service registration · Connects desktop presentation to Core services and view models.
src/EasyRedmineTool.Desktop/DependencyInjection/ServiceCollectionExtensions.cs - Main window · Hosts feature views.
src/EasyRedmineTool.Desktop/Views/MainWindow.axaml - Main window VM
src/EasyRedmineTool.Desktop/ViewModels/MainWindowViewModel.cs
Core application
MVVM state and user-facing workflows.
- Ticket list VM
src/EasyRedmineTool.Core/ViewModels/TicketListViewModel.cs - Time entries VM
src/EasyRedmineTool.Core/ViewModels/TimeEntriesViewModel.cs - Weekly summary VM · Can route a selected ticket into time-entry creation.
src/EasyRedmineTool.Core/ViewModels/WeeklySummaryViewModel.cs - Series booking VM
src/EasyRedmineTool.Core/ViewModels/SeriesBookingViewModel.cs
Domain workflows
Service orchestration and deterministic transformations.
- Ticket service · Loads and merges ticket data.
src/EasyRedmineTool.Core/Services/TicketService.cs - Time entry service · Loads activities and entries; submits creates and updates.
src/EasyRedmineTool.Core/Services/TimeEntryService.cs - Series booking planner · Expands recurring intent into dated previews and actions.
src/EasyRedmineTool.Core/SeriesBookingPlanner.cs - Weekly summary builder · Aggregates entries into calendar-week and ticket totals.
src/EasyRedmineTool.Core/WeeklySummaryBuilder.cs - Connection test service · Validates configured credentials through the API boundary.
src/EasyRedmineTool.Core/Services/ConnectionTestService.cs
Integration and storage
Redmine HTTP boundary and per-user settings.
- Redmine API contract · Abstraction used by Core services.
src/EasyRedmineTool.Core/Api/IEasyRedmineApiClient.cs - Redmine API client · Isolates Redmine payloads and API failures from UI state.
src/EasyRedmineTool.Core/Api/EasyRedmineApiClient.cs - App settings service · Persists connection settings, cache, favorites, theme, and entry defaults per user.
src/EasyRedmineTool.Core/Services/AppSettingsService.cs
Delivery
Cross-platform release packaging.
- Release workflow · Builds self-contained artifacts and GitHub Releases for five target platforms.
.github/workflows/release.yml
Other components
- Redmine REST API
Connections 23
- Program → Avalonia app: initializes
- Avalonia app → Service registration: builds services
- Service registration → Main window: composes
- Main window → Main window VM: binds shell
- Main window → Ticket list VM: hosts feature
- Main window → Time entries VM: hosts feature
- Main window → Weekly summary VM: hosts feature
- Main window → Series booking VM: hosts feature
- Ticket list VM → Ticket service: loads tickets
- Time entries VM → Time entry service: manages entries
- Weekly summary VM → Time entry service: loads entries
- Weekly summary VM → Weekly summary builder: builds totals
- Weekly summary VM → Time entries VM: selects ticket for entry
- Series booking VM → Series booking planner: creates dated plan
- Series booking VM → Time entry service: submits planned entries
- Ticket service → Redmine API contract: uses
- Time entry service → Redmine API contract: uses
- Connection test service → Redmine API contract: tests credentials
- Redmine API client → Redmine API contract: implements
- Redmine API client → Redmine REST API: HTTP/JSON
- Ticket service → App settings service: reads cache and favorites
- Time entries VM → App settings service: uses entry defaults
- Connection test service → App settings service: reads connection settings