PHPackages                             gregkos/greek-strings - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. gregkos/greek-strings

ActiveLibrary

gregkos/greek-strings
=====================

A manipulation library for Greek strings

v1.1.0(5y ago)2145MITPHPPHP ^7.4|^8.0CI failing

Since Jan 5Pushed 3y ago1 watchersCompare

[ Source](https://github.com/gregkos/greek-strings)[ Packagist](https://packagist.org/packages/gregkos/greek-strings)[ Docs](https://github.com/gregkos/greek-strings)[ GitHub Sponsors](https://github.com/sponsors/gregkos)[ RSS](/packages/gregkos-greek-strings/feed)WikiDiscussions master Synced 6d ago

READMEChangelog (3)Dependencies (3)Versions (4)Used By (0)

A manipulation library for Greek strings
========================================

[](#a-manipulation-library-for-greek-strings)

[![Latest Version on Packagist](https://camo.githubusercontent.com/77249850e7b9cf60da7f6d6d6ab6585e1a31808ef04b5c58bbb9b5b761d5d6e2/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f677265676b6f732f677265656b2d737472696e67732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/gregkos/greek-strings)[![GitHub Tests Action Status](https://camo.githubusercontent.com/f7c099956e85cfd92177c889eeee0279a02f9b15f8556fe890a96ae96a835aa1/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f677265676b6f732f677265656b2d737472696e67732f72756e2d74657374732e796d6c3f6272616e63683d6d6173746572266c6162656c3d7465737473)](https://github.com/gregkos/greek-strings/actions?query=workflow%3ATests+branch%3Amaster)[![Total Downloads](https://camo.githubusercontent.com/d6b4bc9e802a3d33d1d574952612d044e29a7d1ebe16dfba4b9dcdcd88ad991a/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f677265676b6f732f677265656b2d737472696e67732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/gregkos/greek-strings)

A library to cover all your Greek string conversion needs.

Currently:

- Transliteration of Greek strings
- Uppercase / lowercase conversions

Planned:

- Open to feature requests! :)

Wishlist:

- Reverse transliteration
- Accent guesstimates

Installation
------------

[](#installation)

You can install the package via composer:

```
composer require gregkos/greek-strings
```

Usage
-----

[](#usage)

You can create a new string by calling the constructor:

```
$greek_string = new GregKos\GreekString('Καλημέρα!');
```

You can transliterate any greek letters in the string like so:

```
echo $greek_string->transliterate();

// Kalimera!
```

You can convert the string to `UPPERCASE`...

```
echo $greek_string->toUpper();

// ΚΑΛΗΜΕΡΑ!
```

...or convert it to `lowercase`

```
echo $greek_string->toLower();

// καλημερα!
```

Keep in mind that conversions remove the accent unless you explicitly pass a parameter:

```
echo $greek_string->toUpper(false);

// ΚΑΛΗΜΈΡΑ!
```

However, there is no efficient way to add an accent that was not there before:

```
$greek_string = new GregKos\GreekString('ΚΑΛΗΜΕΡΑ!');

echo $greek_string->toLower();

// καλημερα!
```

Method Reference
----------------

[](#method-reference)

The following methods are available on any GreekString instance:

```
// Returns the string as is
getString(): string

// Set a new string for the instance
// $str = a valid string
setString(string $str): self

// Return a transliterated version of the string
transliterate(): string

// Return an uppercase version of the string
// $removeAccent = a bool to determine whether or not
// to remove accent from the string (default: true)
toUpper($removeAccent = true): string

// Return an lowercase version of the string
// $removeAccent = a bool to determine whether or not
// to remove accent from the string (default: true)
toLower($removeAccent = true): string
```

Testing
-------

[](#testing)

```
composer test
```

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](.github/CONTRIBUTING.md) for details.

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](../../security/policy) on how to report security vulnerabilities.

Credits
-------

[](#credits)

- [Spatie](https://spatie.be) for the [package skeleton](https://github.com/spatie/package-skeleton-php)
- [multipetros](https://github.com/multipetros) for the [inspiration and parts of the code](https://github.com/multipetros/ElStr.class.php)
- [GregKos](https://github.com/gregkos)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~6 days

Total

3

Last Release

1946d ago

Major Versions

v0.1.0 → v1.0.02021-01-06

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/6676236?v=4)[Greg Kosmidis](/maintainers/gregkos)[@gregkos](https://github.com/gregkos)

---

Top Contributors

[![gregkos](https://avatars.githubusercontent.com/u/6676236?v=4)](https://github.com/gregkos "gregkos (32 commits)")

---

Tags

gregkosgreek-strings

###  Code Quality

TestsPHPUnit

Static AnalysisPsalm

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/gregkos-greek-strings/health.svg)

```
[![Health](https://phpackages.com/badges/gregkos-greek-strings/health.svg)](https://phpackages.com/packages/gregkos-greek-strings)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
