PHPackages                             biblibre/omeka-cli - 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. [CLI &amp; Console](/categories/cli)
4. /
5. biblibre/omeka-cli

ActiveProject[CLI &amp; Console](/categories/cli)

biblibre/omeka-cli
==================

Omeka CLI

v2.0.0(6y ago)11562[2 PRs](https://github.com/biblibre/omeka-cli/pulls)GPL-3.0-or-laterPHPCI passing

Since Dec 9Pushed 1mo ago7 watchersCompare

[ Source](https://github.com/biblibre/omeka-cli)[ Packagist](https://packagist.org/packages/biblibre/omeka-cli)[ Docs](https://github.com/biblibre/omeka-cli)[ RSS](/packages/biblibre-omeka-cli/feed)WikiDiscussions master Synced 4w ago

READMEChangelog (10)Dependencies (8)Versions (38)Used By (0)

Omeka CLI
=========

[](#omeka-cli)

Command line tool for [Omeka](https://omeka.org/)

This tool allows to interact with Omeka by using a command line interface. It also provides everything needed for Omeka plugins to create custom commands.

[![Build status](https://camo.githubusercontent.com/5c761341dd1d6ed40add99b6903058e72773d73c96510d372bc23bdcf3845e8a/68747470733a2f2f7472617669732d63692e6f72672f6269626c696272652f6f6d656b612d636c692e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/biblibre/omeka-cli "biblibre/omeka-cli - Travis CI")

Usage
-----

[](#usage)

```
omeka-cli [-h | --help]
omeka-cli [-V | --version]
omeka-cli  [options] [arguments]

```

Available commands
------------------

[](#available-commands)

```
check-updates     check for updates
help              print help for a specific command
status            print status of current Omeka installation
install           install Omeka
list              list available commands
options           list, get and set Omeka options
plugin-disable    disable a plugin
plugin-download   downloads a plugin
plugin-enable     enable a plugin (install & activate)
plugin-list       list all plugins
plugin-search     search a plugin
plugin-uninstall  uninstall a plugin
plugin-update     update a plugin
snapshot          create a snapshot
snapshot-restore  restore a snapshot
upgrade           upgrade Omeka

```

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

[](#requirements)

- PHP (&gt;= 7.2) with the following extensions:
    - Zip
    - PDO and the PDO\_MYSQL driver
- git

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

[](#installation)

### Using composer

[](#using-composer)

```
# For the latest released version
composer global require biblibre/omeka-cli

# For the latest dev version
composer global require biblibre/omeka-cli:@dev
```

Then add `~/.config/composer/vendor/bin` to your `PATH`

```
export PATH=~/.config/composer/vendor/bin:$PATH
```

### Using the phar

[](#using-the-phar)

Download the latest ̀`omeka-cli.phar` from [Releases](https://github.com/biblibre/omeka-cli/releases) page.

```
wget https://github.com/biblibre/omeka-cli/releases/download/$VERSION/omeka-cli.phar
chmod +x omeka-cli.phar
sudo mv omeka-cli.phar /usr/local/bin/omeka-cli
```

### Using the sources

[](#using-the-sources)

```
git clone https://github.com/biblibre/omeka-cli.git
cd omeka-cli
composer install --no-dev
bin/omeka-cli --version
```

Creating custom commands
------------------------

[](#creating-custom-commands)

To create a custom command named `foo:bar` with the Foo plugin, put the following code in the `initialize` hook of your plugin's main class:

```
$events = Zend_EventManager_StaticEventManager::getInstance();
$events->attach('OmekaCli', 'commands', function() {
    return array(
        'Foo_Bar',
    );
});
```

and define a class `Foo_Bar` which extends [OmekaCli\\Command\\AbstractCommand](src/Command/AbstractCommand.php)

You will have to implements at least `configure` and `execute` methods.

For instance:

```
use OmekaCli\Command\AbstractCommand;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;

class Foo_Bar extends AbstractCommand
{
    protected function configure()
    {
        $this->setName('foo:bar');
        $this->setDescription('print something to stdout');
        $this->setAliases(array('bar'));
    }

    protected function execute(InputInterface $input, OutputInterface $output)
    {
        $output->writeln('Hello, omeka-cli!');

        return 0;
    }
}
```

Then you will be able to run the command either this way:

```
omeka-cli foo:bar [OPTION...] [ARG...]
```

or using the alias:

```
omeka-cli bar [OPTION...] [ARG...]
```

To see how to create a custom command from a plugin in practice, see plugin [Foo](https://github.com/biblibre/omeka-plugin-Foo).

Running tests
-------------

[](#running-tests)

If you want to test `omeka-cli`, copy `phpunit.xml.dist` into `phpunit.xml` and change environment variables `OMEKA_DB_*` as needed. If you want to avoid downloading Omeka before every run, you can download the ZIP file manually, and put its local path in `OMEKA_ZIP_PATH`.

After you've done that, run

```
composer install
vendor/bin/phpunit
```

License
-------

[](#license)

GPL 3.0+

###  Health Score

45

—

FairBetter than 91% of packages

Maintenance61

Regular maintenance activity

Popularity16

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity75

Established project with proven stability

 Bus Factor1

Top contributor holds 99% 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 ~40 days

Recently: every ~235 days

Total

33

Last Release

2207d ago

Major Versions

v0.18.0 → v1.0.0-alpha.12017-09-05

v1.1.0 → v2.0.02020-06-15

### Community

Maintainers

![](https://www.gravatar.com/avatar/1d9cc4e07cf1be3cee0394a08d19024c90ebcefb085e7a2c6bb999612f927b25?d=identicon)[jajm](/maintainers/jajm)

---

Top Contributors

[![jajm](https://avatars.githubusercontent.com/u/306836?v=4)](https://github.com/jajm "jajm (95 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (1 commits)")

---

Tags

omekaomeka

###  Code Quality

TestsPHPUnit

Code StylePHP CS Fixer

### Embed Badge

![Health badge](/badges/biblibre-omeka-cli/health.svg)

```
[![Health](https://phpackages.com/badges/biblibre-omeka-cli/health.svg)](https://phpackages.com/packages/biblibre-omeka-cli)
```

###  Alternatives

[laravel/framework

The Laravel Framework.

34.8k543.8M19.7k](/packages/laravel-framework)[drupal/core

Drupal is an open source content management platform powering millions of websites and applications.

21866.0M1.7k](/packages/drupal-core)[drupal/core-recommended

Locked core dependencies; require this project INSTEAD OF drupal/core.

6942.5M407](/packages/drupal-core-recommended)[spatie/laravel-export

Create a static site bundle from a Laravel app

674146.0k6](/packages/spatie-laravel-export)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

585.6M555](/packages/shopware-core)[aeliot/todo-registrar

Register TODOs from source code in issue tracker

153.0k](/packages/aeliot-todo-registrar)

PHPackages © 2026

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