PHPackages                             cherry-project/logger - 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. [Logging &amp; Monitoring](/categories/logging)
4. /
5. cherry-project/logger

ActiveLibrary[Logging &amp; Monitoring](/categories/logging)

cherry-project/logger
=====================

Cherry-project logger

v1.0.0(7y ago)113[1 issues](https://github.com/cherry-framework/logger/issues)MITPHPPHP &gt;=5.6.0

Since Feb 26Pushed 7y ago1 watchersCompare

[ Source](https://github.com/cherry-framework/logger)[ Packagist](https://packagist.org/packages/cherry-project/logger)[ Docs](https://github.com/ABGEO07/cherry-logger)[ RSS](/packages/cherry-project-logger/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (3)Dependencies (1)Versions (5)Used By (0)

cherry-logger
=============

[](#cherry-logger)

The Cherry-project logger

[![GitHub license](https://camo.githubusercontent.com/558300b634006bdb01a48e70ab8a195891bdb6124564c71471a03062fabf1737/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f616267656f30372f6368657272792d6c6f676765722e737667)](https://github.com/ABGEO07/cherry-logger/blob/master/LICENSE)

[![GitHub release](https://camo.githubusercontent.com/bc9369efe61aa4fe489200549d2a66228d9048c295700ab2125e01f3f49b8d74/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f616267656f30372f6368657272792d6c6f676765722e737667)](https://github.com/ABGEO07/cherry-logger/releases)

[![Packagist Version](https://camo.githubusercontent.com/f236af15dca7028a68c7e918226fecd48f5f77f528dbdfda54754dfde4f25367/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6368657272792d70726f6a6563742f6c6f676765722e737667 "Packagist Version")](https://packagist.org/packages/cherry-project/logger "Packagist Version")

---

Including
---------

[](#including)

**Install from composer** `composer require cherry-project/logger`

**Include Autoloader in your main file** (Ex.: index.php)

```
require_once __DIR__ . '/vendor/autoload.php';
```

**Import class**

```
use Cherry\Logger;
```

**Set logs directory**

```
define('LOGS_DIR', __DIR__ . '/var/log');
```

**Crete class new object**

Logger class takes two arguments:

- Log Name, the logs filename **{LogName}.log** (Default **'app'**).
- Logs Directory(Default **'/var/log'**).

```
$logger = new Logger('app-logs', LOGS_DIR);
```

Logger methods
--------------

[](#logger-methods)

The logger has 4 Log types:

- **info()**;
- **warning()**;
- **error()**;
- **debug()**

and additional methods:

- **clear()** clear logs in current instance;
- **count()** get logs count in current instance;

### Call methods

[](#call-methods)

```
$logger->info('Info Message');
$logger->warning('Warning Message');
$logger->error('Error Message');
$logger->debug('Debug Message');
```

Also you can call more then one method from one object:

```
$logger->info('Info Message 2')
    ->warning('Warning Message 2')
    ->error('Error Message 2')
    ->debug('Debug Message 2');
```

If you need logs count in current instance, you might use **count()** method:

```
echo $logger->count();
```

You can clear all the logs in the current instance using the **clear()** method:

```
$logger->clear();
```

**2019 © Cherry-project**

###  Health Score

21

—

LowBetter than 19% of packages

Maintenance0

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 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 ~1 days

Total

3

Last Release

2632d ago

Major Versions

v0.9.5 → v1.0.02019-02-28

### Community

Maintainers

![](https://www.gravatar.com/avatar/003cac08dd47c34ad3a5ed454c2968ed6afea9e26d57033867d4166fa08b3555?d=identicon)[ABGEO](/maintainers/ABGEO)

---

Top Contributors

[![ABGEO](https://avatars.githubusercontent.com/u/19558543?v=4)](https://github.com/ABGEO "ABGEO (23 commits)")

---

Tags

cherrycomposerloggingloggingcherry

### Embed Badge

![Health badge](/badges/cherry-project-logger/health.svg)

```
[![Health](https://phpackages.com/badges/cherry-project-logger/health.svg)](https://phpackages.com/packages/cherry-project-logger)
```

###  Alternatives

[monolog/monolog

Sends your logs to files, sockets, inboxes, databases and various web services

21.4k964.9M7.0k](/packages/monolog-monolog)[symfony/monolog-bundle

Symfony MonologBundle

2.9k249.1M1.6k](/packages/symfony-monolog-bundle)[itsgoingd/clockwork

php dev tools in your browser

5.9k27.6M94](/packages/itsgoingd-clockwork)[sentry/sentry

PHP SDK for Sentry (http://sentry.io)

1.9k227.1M273](/packages/sentry-sentry)[sentry/sentry-laravel

Laravel SDK for Sentry (https://sentry.io)

1.3k114.3M154](/packages/sentry-sentry-laravel)[sentry/sentry-symfony

Symfony integration for Sentry (http://getsentry.com)

73761.4M66](/packages/sentry-sentry-symfony)

PHPackages © 2026

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