PHPackages                             colybri/business-day - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. colybri/business-day

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

colybri/business-day
====================

This library allows you to set a calendar of holidays in your Laravel application in a simple way.

2.0.0(4y ago)3223MITPHPPHP ^7.1.3

Since Nov 19Pushed 4y ago1 watchersCompare

[ Source](https://github.com/colybri/business-day)[ Packagist](https://packagist.org/packages/colybri/business-day)[ Docs](https://www.colibriwebwork.com)[ RSS](/packages/colybri-business-day/feed)WikiDiscussions master Synced 3d ago

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

Business Day
============

[](#business-day)

This date library extends [Date](https://github.com/jenssegers/date) which in turn extends [Carbon](https://github.com/briannesbitt/Carbon) library. So all functionality of these libraries is also avaible. This library allows you to set a calendar of holidays in your Laravel application in a simple way.

Install using composer:

```
composer require colybri/business-day
```

Laravel 5
---------

[](#laravel-5)

For Laravel 5.5 or lower you must use version 1 of this library.

### Laravel version Compatibility

[](#laravel-version-compatibility)

LaravelPackage5.0.x1.0.x5.1.x1.0.x5.2.x1.0.x5.3.x1.0.x5.4.x1.0.x5.5.x1.0.x5.6.x2.0.x5.7.x2.0.xIn Laravel 5.6 or higher, this package will be automatically discovered and you can safely skip the following two steps. Add the following to the providers array in `config/app.php`:

```
Colybri\BusinessDay\BusinessDayServiceProvider::class,
```

You can also add it as a Facade in `config/app.php`:

```
'BusinessDay' => Colybri\BusinessDay\BusinessDay::class,
```

Configuration
-------------

[](#configuration)

First of all you must configure the options of your holidays calendar in `config/business-day.php` file. In order to edit the default configuration for this package you may execute:

```
php artisan vendor:publish --provider="Colybri\BusinessDay\BusinessDayServiceProvider"

```

```
use Colybri\BusinessDay\BusinessDay;

$date = BusinessDay::now();

return [
 /*
  |--------------------------------------------------------------------------
  | Holidays calendar
  |--------------------------------------------------------------------------
  |
  */
  'restDay' => 0, //Sunday
  'saturdayIsBusinessDay' => "false",
  'holidays' => [
      "01-01",
      $date->easterSunday()->addDay()->config(),
      $date->goodFriday()->config(),
      "06-01",
      //vacational periods
      [
          "01-08", "31-08"
      ],
      [
          "24-12", "27-12"
      ],
      ...
  ],
];
```

The option `restDay` set to 0 establish Sunday as holiday. If you don't want this behavior by default set the field to "false". All literal dates must be indicate whit format "d-m". If you want to use available methods of this library for mobile holidays you must to call after to config method. You can also indicates vacational periods with start and end date.

Usage
-----

[](#usage)

List of methods of the BusinessDay class:

```
use Colybri\BusinessDay\BusinessDay;

$date = BusinessDay::now();
$date->isBusinessDay(); //return true or false
$date->nextBusinessDay();
$date->previousBusinessDay();
```

Methods such as `nextBusinessDay` and `previousBusinessDay` return a BusinessDay object with all functionality of Date and Carbon libraries.

### Catholic holidays

[](#catholic-holidays)

Available methods for Catholic mobile holidays:

```
$date = new BusinessDay('2000-01-31', 'Europe/Brussels');
$date->ashWednesday();
$date->palmSunday();
$date->maundyThursday();
$date->goodFriday();
$date->easterSunday();
$date->easterMonday();
$date->ascensionDay();
$date->pentecostSunday();
$date->pentecostMonday();
```

All this methods return a BusinessDay object with all functionality of Date and Carbon libraries.

**NOTE!** In Next versions i will try to include other religious mobile holidays.

License
-------

[](#license)

Laravel BusinessDay is licensed under [The MIT License (MIT)](LICENSE).

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community9

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

Total

2

Last Release

1619d ago

Major Versions

1.0.0 → 2.0.02021-12-07

PHP version history (2 changes)1.0.0PHP &gt;=5.4

2.0.0PHP ^7.1.3

### Community

Maintainers

![](https://www.gravatar.com/avatar/f48f350d519f1516d3dc04fe68ff3873e7d1a5d7285c5364d45298ffee1a87bd?d=identicon)[Colybri](/maintainers/Colybri)

---

Top Contributors

[![forkrefactor](https://avatars.githubusercontent.com/u/95745947?v=4)](https://github.com/forkrefactor "forkrefactor (5 commits)")

---

Tags

laraveldatetimetimedateholidaysBusiness Day

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/colybri-business-day/health.svg)

```
[![Health](https://phpackages.com/badges/colybri-business-day/health.svg)](https://phpackages.com/packages/colybri-business-day)
```

###  Alternatives

[zjkal/time-helper

一个简单快捷的PHP日期时间助手类库。 a smart PHP datetime helper library.

21128.6k1](/packages/zjkal-time-helper)[danielstjules/php-pretty-datetime

Generates human-readable strings for PHP DateTime objects

5791.9k](/packages/danielstjules-php-pretty-datetime)[p3ym4n/jdate

Date converter from Jalali to Georgian and vice versa. It has Carbon instance inside and it's Laravel friendly.

101.8k2](/packages/p3ym4n-jdate)[maherelgamil/arabicdatetime

Easy and useful tool to generate arabic or hijri date with multi-language support for laravel

414.5k](/packages/maherelgamil-arabicdatetime)[aloko/nova-persian-datepicker

Persian Datepicker for Laravel Nova.

203.5k](/packages/aloko-nova-persian-datepicker)

PHPackages © 2026

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