PHPackages                             codesleeve/guard - 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. codesleeve/guard

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

codesleeve/guard
================

This is a package which can be called to watch a list of paths.

v0.1(12y ago)23831MITPHPPHP &gt;=5.3.0

Since Jan 4Pushed 12y ago2 watchersCompare

[ Source](https://github.com/CodeSleeve/guard)[ Packagist](https://packagist.org/packages/codesleeve/guard)[ RSS](/packages/codesleeve-guard/feed)WikiDiscussions master Synced 2d ago

READMEChangelogDependencies (2)Versions (2)Used By (1)

Guard
=====

[](#guard)

### No ruby? No node? No problem.

[](#no-ruby-no-node-no-problem)

Guard allows you to run custom and packaged events whenever files are changed with your configurable paths. *Note, this package is meant to be used with Laravel 4.*

To get started update your dependencies in `composer.json`

```
	"require": {
		"codesleeve/guard": "dev-master"
	},
```

The service provider needs to be registered in `app/config/app.php`

```
'providers' => array(
		...
		'Codesleeve\Guard\GuardServiceProvider',
	),
```

And voila! You should now be able to run

```
   php artisan guard:watch
```

This doesn't do much except [print out changes to our assets](https://github.com/CodeSleeve/Guard/blob/master/src/Codesleeve/Guard/Events/LogEvent.php) though. So let's learn how to configure this thing.

### Configuration

[](#configuration)

First you should publish the config

```
   php artisan config:publish codesleeve/guard
```

Next open up `app/config/packages/codessleve/guard/config.php`

#### paths

[](#paths)

These paths are relative to your base laravel project and will be monitored by Guard. There can be both directories and files in this array.

```
	'paths' => array(
		'app/assets',
		'app/models',
		'app/controllers',
		'app/views',
	),
```

#### events

[](#events)

Event classes should implement [Codesleeve\\Guard\\Events\\EventInterface](https://github.com/CodeSleeve/Guard/blob/master/src/Codesleeve/Guard/Events/EventInterface.php) and are called in order whenever a file in your paths above changes.

```
	'events' => array(
		new Codesleeve\Guard\Events\LogEvent
	),
```

FAQ
---

[](#faq)

#### pcntl\_signal disabled\_functions

[](#pcntl_signal-disabled_functions)

In order to capture the ctrl+c event from keyboard we use pcntl\_signal which depending on what package manager/operating system you use could be disabled in your php.ini. Be sure to [remove pcntl\_signal](http://stackoverflow.com/questions/16262854/pcntl-not-working-on-ubuntu-from-security-reasons) from your `disabled_functions`.

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity48

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

Unknown

Total

1

Last Release

4513d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/609298af5265d6fb73ce9f9d9b83aed027150cf14378caffefb8685992284f7e?d=identicon)[kelt](/maintainers/kelt)

---

Top Contributors

[![kdocki](https://avatars.githubusercontent.com/u/772706?v=4)](https://github.com/kdocki "kdocki (16 commits)")

### Embed Badge

![Health badge](/badges/codesleeve-guard/health.svg)

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

###  Alternatives

[barryvdh/laravel-ide-helper

Laravel IDE Helper, generates correct PHPDocs for all Facade classes, to improve auto-completion.

14.9k123.0M687](/packages/barryvdh-laravel-ide-helper)[orchestra/canvas

Code Generators for Laravel Applications and Packages

21017.2M158](/packages/orchestra-canvas)[illuminate/pipeline

The Illuminate Pipeline package.

9446.6M213](/packages/illuminate-pipeline)[illuminate/pagination

The Illuminate Pagination package.

10532.5M862](/packages/illuminate-pagination)[spatie/laravel-pjax

A pjax middleware for Laravel 5

513371.8k11](/packages/spatie-laravel-pjax)[spatie/laravel-mix-preload

Add preload and prefetch links based your Mix manifest

169176.0k2](/packages/spatie-laravel-mix-preload)

PHPackages © 2026

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