PHPackages                             celemas/log - 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. celemas/log

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

celemas/log
===========

A simple PSR-3 Logger

0.2.0(1mo ago)04MITPHPPHP ^8.5CI passing

Since Jan 31Pushed 3w ago1 watchersCompare

[ Source](https://github.com/celemas/log)[ Packagist](https://packagist.org/packages/celemas/log)[ Docs](https://duon.sh/log)[ RSS](/packages/celemas-log/feed)WikiDiscussions main Synced 1w ago

READMEChangelogDependencies (2)Versions (3)Used By (0)

Celemas Log
===========

[](#celemas-log)

[![ci](https://github.com/celemas/log/actions/workflows/ci.yml/badge.svg)](https://github.com/celemas/log/actions)[![codecov](https://camo.githubusercontent.com/63d7c5d46867d7f613a95f585bdcc8b027cf365704ddab0616182770bb88ba30/68747470733a2f2f636f6465636f762e696f2f6769746875622f63656c656d61732f6c6f672f67726170682f62616467652e7376673f746f6b656e3d32454e3453324c524655)](https://codecov.io/github/celemas/log)[![psalm coverage](https://camo.githubusercontent.com/8a36e810425a168a1b42a174ef909b375cff3e54d002f1d2f4f5cf894c2a31ba/68747470733a2f2f73686570686572642e6465762f6769746875622f63656c656d61732f6c6f672f636f7665726167652e7376673f)](https://shepherd.dev/github/celemas/log)[![psalm level](https://camo.githubusercontent.com/d0c6f99aff8bef35105f9dfb056ab057313fe90bc80ddb31654819546ab59c93/68747470733a2f2f73686570686572642e6465762f6769746875622f63656c656d61732f6c6f672f6c6576656c2e7376673f)](https://shepherd.dev/github/celemas/log)[![Software License](https://camo.githubusercontent.com/074b89bca64d3edc93a1db6c7e3b1636b874540ba91d66367c0e5e354c56d0ea/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e737667)](LICENSE.md)

A simple PSR-3 logger using PHP's `error_log` function.

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

[](#installation)

```
composer require celemas/log
```

Usage
-----

[](#usage)

Create a logger without arguments to write to PHP's default SAPI error logger.

```
use Celemas\Log\Logger;

$logger = new Logger();
$logger->info('Application started');
```

See the [documentation](docs/index.md) for file logging, level filtering, and formatter usage.

Testing
-------

[](#testing)

During testing, PHP's `error_log` ini setting is set to a temporary file. To print the output to the console, prepend a special env variable to the PHPUnit cli command, as follows:

```
ECHO_LOG=1 phpunit
```

### Test Environment Requirements

[](#test-environment-requirements)

Tests require:

- `ini_set()` function enabled (for `error_log` redirection)
- Writable system temp directory (for test log file isolation)
- PHP `error_reporting` must be modifiable

These are standard in development environments but may fail in restricted PHP configurations where `ini_set` is disabled via `disable_functions`.

License
-------

[](#license)

This project is licensed under the [MIT license](LICENSE.md).

###  Health Score

39

—

LowBetter than 84% of packages

Maintenance94

Actively maintained with recent releases

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity43

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

Total

2

Last Release

40d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0c15f1690b643e5cbf205fd28f3b2ebb6c7448d34774bb92b7952150c901a689?d=identicon)[ernstla](/maintainers/ernstla)

---

Top Contributors

[![ernstla](https://avatars.githubusercontent.com/u/683620?v=4)](https://github.com/ernstla "ernstla (134 commits)")

---

Tags

logpsr-3loggingduon

### Embed Badge

![Health badge](/badges/celemas-log/health.svg)

```
[![Health](https://phpackages.com/badges/celemas-log/health.svg)](https://phpackages.com/packages/celemas-log)
```

###  Alternatives

[monolog/monolog

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

21.4k997.8M7.9k](/packages/monolog-monolog)[sentry/sentry

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

1.9k240.0M312](/packages/sentry-sentry)[analog/analog

Fast, flexible, easy PSR-3-compatible PHP logging package with dozens of handlers.

3511.6M24](/packages/analog-analog)[inpsyde/wonolog

Monolog-based logging package for WordPress.

184631.3k7](/packages/inpsyde-wonolog)[apix/log

Minimalist, thin and fast PSR-3 compliant (multi-bucket) logger.

521.1M20](/packages/apix-log)[elastic/ecs-logging

Format and enrich your log files in the elastic common schema

22994.8k3](/packages/elastic-ecs-logging)

PHPackages © 2026

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