Skip to content

Commit

Permalink
Fix missing intl extension in workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
cracksalad committed Jul 13, 2024
1 parent dd1630d commit bae5ee8
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@
/.phive export-ignore
/psalm.baseline.xml export-ignore
/psalm.xml export-ignore
/stubs export-ignore
1 change: 1 addition & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ jobs:
uses: docker://vimeo/psalm-github-actions
with:
args: --shepherd
composer_ignore_platform_reqs: true
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cracksalad/i18n",
"version": "0.1.1",
"version": "0.1.2",
"type": "library",
"description": "PHP library to properly handle internationalization, but in a stateless fashion - no gettext()!",
"keywords": [
Expand Down
4 changes: 4 additions & 0 deletions psalm.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,8 @@
<projectFiles>
<directory name="src" />
</projectFiles>

<stubs>
<file name="stubs/intl.php"></file>
</stubs>
</psalm>
15 changes: 15 additions & 0 deletions stubs/intl.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php
class MessageFormatter {

public function __construct(string $locale, string $pattern){}
public static function create(string $locale, string $pattern): ?MessageFormatter {}
public static function formatMessage(string $locale, string $pattern, array $values): string|false {}
public function format(array $values): string|false {}
public function getErrorCode(): int {}
public function getErrorMessage(): string {}
public function getLocale(): string {}
public function getPattern(): string|false {}
public static function parseMessage(string $locale, string $pattern, string $message): array|false {}
public function parse(string $string): array|false {}
public function setPattern(string $pattern): bool {}
}

0 comments on commit bae5ee8

Please sign in to comment.