Skip to content

Commit

Permalink
Merge pull request #27 from ElForastero/release-v7
Browse files Browse the repository at this point in the history
chore(deps): prepare v7 release
  • Loading branch information
ElForastero authored May 1, 2023
2 parents 23bd123 + 535be00 commit ef4f2d4
Show file tree
Hide file tree
Showing 5 changed files with 769 additions and 1,026 deletions.
61 changes: 31 additions & 30 deletions .github/workflows/php.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,40 +4,41 @@ on: [push, pull_request]

jobs:
run:

runs-on: ${{ matrix.operating-system }}
strategy:
matrix:
operating-system: [ubuntu-latest, macOS-latest]
php-versions: ['8.0', '8.1']
php-versions: ["8.1", "8.2"]
name: PHP ${{ matrix.php-versions }} Test on ${{ matrix.operating-system }}

steps:
- name: Checkout
uses: actions/checkout@v2

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
extensions: mbstring, intl

- name: Get composer cache directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"

- name: Cache dependencies
uses: actions/cache@v2
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-

- name: Install dependencies
run: composer install --prefer-dist

- name: Run test suite
run: composer run-script test

- name: Run style-checking
run: composer run-script check-style
- name: Checkout
uses: actions/checkout@v2

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-versions }}
extensions: mbstring, intl

- name: Get composer cache directory
id: composer-cache
run: echo "::set-output name=dir::$(composer config cache-files-dir)"

- name: Cache dependencies
uses: actions/cache@v2
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-

- name: Install dependencies
run: composer install --prefer-dist

- name: Run test suite
run: composer run-script test

- name: Run style-checking
env:
PHP_CS_FIXER_IGNORE_ENV: true
run: composer run-script check-style
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM php:8.0
FROM php:8.2

RUN apt-get update && \
apt-get install -y git zip unzip libicu-dev && \
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ Transliterate::slugify('Съешь еще этих мягких французс
Карта создается в виде отдельного файла с возвращаемым массивом:

```php
// /resources/maps/uk/ukraine.php
// /resources/maps/ua/ukraine.php

return [
'ї' => 'i',
Expand All @@ -109,15 +109,15 @@ return [
Добавьте путь к созданной карте в массив `maps`, конфига `transliterate.php`:

```php
'uk' => [
'ukraine' => dirname(__DIR__) . '/resources/maps/uk/ukraine.php',
'ua' => [
'ukraine' => dirname(__DIR__) . '/resources/maps/ua/ukraine.php',
]
```

После этого карту можно использовать.

```php
$transliterator = new Transliterator('uk', 'ukraine');
$transliterator = new Transliterator('ua', 'ukraine');
$transliterator->make('Ваша транслітерація');
```

Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "elforastero/transliterate",
"description": "Transliteration package for laravel",
"version": "6.0.0",
"version": "7.0.0",
"type": "library",
"license": "MIT",
"authors": [
Expand All @@ -23,7 +23,7 @@
}
},
"require": {
"php": ">=8.0",
"php": ">=8.1",
"ext-intl": "*",
"illuminate/support": "^6.0|^7.0|^8.0|^9.0|^10.0"
},
Expand Down
Loading

0 comments on commit ef4f2d4

Please sign in to comment.