Coder Social home page Coder Social logo

akeneo-purge-media-files's Introduction

Akeneo Purge Media Files Bundle

IMPORTANT: Do not use this bundle in the Akeneo PIM Enterprise Edition (why?)

This bundle comes with a new command to remove unused media files.

Requirements

Version Akeneo PIM Community Edition Akeneo PIM Enterprise Edition
2.* 3.0.* Do not use
1.* 2.3.* Do not use

Installation

    composer require eikona-media/akeneo-purge-media-files:~2.0

Enable the bundle in the app/AppKernel.php file in the registerProjectBundles() method:

protected function registerProjectBundles()
{
    return [
        // ...
        new EikonaMedia\Akeneo\PurgeMediaFilesBundle\EikonaMediaAkeneoPurgeMediaFilesBundle(),
    ];
}

Usage

To remove unused media files execute the command eikona-media:media:purge-files.
The command has one option: --force. If you omit the option the command runs in safe mode (no files will be deleted).

The command searches for media files in the catalog storage directory (Akeneo parameter: catalog_storage_dir) for files, which:

  • do not have an entry in akeneo_file_storage_file_info
  • do have an entry in akeneo_file_storage_file_info but are not used in any product or product model (in this case the command also removes the entity)

Why not to use in the Akeneo PIM Enterprise Edition

  • The Akeneo PIM Enterprise Edition has the asset management (so we probably dont want to delete unsued files)
  • The Akeneo PIM Enterprise Edition has proposals (which the command does not search through)
  • The Akeneo PIM Enterprise Edition can restore old product versions (which the command does not search through)

akeneo-purge-media-files's People

Contributors

rafelder avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

alexdkaminski

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.