Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ concurrency:

jobs:
tests:
runs-on: ubuntu-latest
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
php:
- '7.4'
- '8.0'
Expand Down
6 changes: 4 additions & 2 deletions src/TicketSwapErrorFormatter.php
Original file line number Diff line number Diff line change
Expand Up @@ -180,13 +180,15 @@ public static function link(

private static function trimPath(string $path) : string
{
$parts = explode(DIRECTORY_SEPARATOR, $path);
// Normalize to forward slashes for consistent handling across platforms
$normalizedPath = str_replace('\\', '/', $path);
$parts = explode('/', $normalizedPath);
if (count($parts) < 6) {
return $path;
}

return implode(
DIRECTORY_SEPARATOR,
'/',
Comment thread
samsonasik marked this conversation as resolved.
Outdated
[
...array_slice($parts, 0, 3),
'...',
Expand Down