PHPackages                             gilleswittenberg/backup-sql - 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. gilleswittenberg/backup-sql

ActiveCakephp-plugin

gilleswittenberg/backup-sql
===========================

CakePHP shell that runs mysqldump on a database.

17PHP

Since Mar 16Pushed 12y agoCompare

[ Source](https://github.com/gilleswittenberg/BackupSql)[ Packagist](https://packagist.org/packages/gilleswittenberg/backup-sql)[ RSS](/packages/gilleswittenberg-backup-sql/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

[![Build Status](https://camo.githubusercontent.com/5f5bac5edb317a4468b9f7401c0411aa87d7ff56f62e3c7ad748d2d000d249ad/68747470733a2f2f7472617669732d63692e6f72672f67696c6c657377697474656e626572672f4261636b757053716c2e706e673f6272616e63683d6d6173746572)](https://travis-ci.org/gilleswittenberg/BackupSql) [![Coverage Status](https://camo.githubusercontent.com/88bfba0de0bf3e74c678fafecb4c3c738601aed435938c4571b054302219c792/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f67696c6c657377697474656e626572672f4261636b757053716c2f62616467652e706e673f6272616e63683d6d6173746572)](https://coveralls.io/r/gilleswittenberg/BackupSql?branch=master) [![Total Downloads](https://camo.githubusercontent.com/b979a85ebe034078628a395357cbfda733e4aab58d4db6d404eb6c1cda19488f/68747470733a2f2f706f7365722e707567782e6f72672f67696c6c657377697474656e626572672f4261636b757053716c2f642f746f74616c2e706e67)](https://packagist.org/packages/gilleswittenberg/BackupSql) [![Latest Stable Version](https://camo.githubusercontent.com/ef14a4a7eec40799bc4a82a71b97cb72a23379f02d61f26baeb6f0d56586835e/68747470733a2f2f706f7365722e707567782e6f72672f67696c6c657377697474656e626572672f4261636b757053716c2f762f737461626c652e706e67)](https://packagist.org/packages/gilleswittenberg/BackupSql)

BackupSqlShell
==============

[](#backupsqlshell)

Runs mysqldump on a database.

Requirements
------------

[](#requirements)

- CakePHP 2.x
- PHP 5.3

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

[](#installation)

*\[Using [Composer](http://getcomposer.org/)\]*

Add the plugin to your project's `composer.json` - something like this:

```
	{
		"require": {
			"gilleswittenberg/backup-sql": "dev-master"
		}
	}

```

Because this plugin has the type `cakephp-plugin` set in its own `composer.json`, Composer will install it inside your `/Plugins` directory, rather than in the usual vendors file. It is recommended that you add `/Plugins/BackupSql` to your .gitignore file. (Why? [read this](http://getcomposer.org/doc/faqs/should-i-commit-the-dependencies-in-my-vendor-directory.md).)

*\[Manual\]*

- Download this:
- Unzip that download.
- Copy the resulting folder to `app/Plugin`
- Rename the folder you just copied to `BackupSql`

*\[GIT Submodule\]*

In your app directory type:

```
	git submodule add -b master git://github.com/gilleswittenberg/BackupSql.git Plugin/BackupSql
	git submodule init
	git submodule update
```

*\[GIT Clone\]*

In your `Plugin` directory type:

```
	git clone -b master git://github.com/gilleswittenberg/BackupSql.git BackupSql

```

### Enable plugin

[](#enable-plugin)

In 2.0 you need to enable the plugin in your `app/Config/bootstrap.php` file:

```
	CakePlugin::load('BackupSql');

```

If you are already using `CakePlugin::loadAll();`, then this is not necessary.

Usage
-----

[](#usage)

Run the shell on your cli:

```
Console/cake BackupSql.backup_sql default backup.sql
```

This will create a backup of the mysql data configured in your `default` database connection in the `app/tmp/backups` directory named `backup.sql`.

License
-------

[](#license)

The MIT License (MIT)

Copyright (c) 2014 Gilles Wittenberg

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity41

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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/41184f56cbe4766c9826303e36afc0639f8b58a9b912ff6a925ed7c8628a532f?d=identicon)[gilleswittenberg](/maintainers/gilleswittenberg)

---

Top Contributors

[![josegonzalez](https://avatars.githubusercontent.com/u/65675?v=4)](https://github.com/josegonzalez "josegonzalez (2 commits)")

### Embed Badge

![Health badge](/badges/gilleswittenberg-backup-sql/health.svg)

```
[![Health](https://phpackages.com/badges/gilleswittenberg-backup-sql/health.svg)](https://phpackages.com/packages/gilleswittenberg-backup-sql)
```

PHPackages © 2026

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