Code Monkey home page Code Monkey logo

bragento-composer-installer's Introduction

Magento Composer Installer

![Gitter](https://badges.gitter.im/Join Chat.svg)

Build Status Code Climate Scrutinizer Code Quality

License License

Supported Types:

magento-module
magento-core
magento-theme (currently just the same as magento-module)

Core Installer

Installation

to Install the Magento Core require magento/core in your composer.json.
Magento will be copied to the Magento root dir (Default: 'magento')

{
    "require": {  
        "bragento/magento-composer-installer": "~1",  
        "magento/core": "~1.9"  
    },  
    "extra": {  
        "magento-root-dir": "magento"  
    }  
}

Persistent Files

There are several persistent files and directories, that will be backed up and restored after core deployment:

var
media
app/etc/local.xml

You can also define additional Files to be persistent such as local Modules

{
    "require": {  
        "bragento/magento-composer-installer": "~1",  
        "magento/core": "~1.9"  
    },  
    "extra": {  
        "magento-root-dir": "magento",
        "persistent-files": [
            "somefile",
            "app/code/local/Vendor/SomeModule",
            "app/etc/modules/Vendor_SomeModule.xml"
        ]
    }  
}

Module Installer

Install a Module

Just require the Modules in your composer.json.

Many composer installable Magento extensions are listed under packages.firegento.com
There is also an example of how to add a composer package directly from a github (or any git) Repository

{
    "repositories": [
        {
            "type": "composer",
            "url": "packages.firegento.com"
        },
        {
            "type": "git",
            "url": "https://github.com/danslo/ApiImport.git"
        }
    ],
    "require": {  
        "bragento/magento-composer-installer": "~1",  
        "magento/core": "~1.9",
        "firegento/magesetup": "~2",
        "danslo/api-import": "~1"
    },  
    "extra": {  
        "magento-root-dir": "magento"  
    }  
}

Change Deploy Strategy

By default, all Modules are deployed by symlink. You can change this behaviour with the config key 'magento-deploystrategy'

Possible values are:
symlink
copy
none (will just install the Module but not deploy it to magento root)

{ 
    "extra": {  
        "magento-deploystrategy": "copy"  
    }  
}

Overwrite Deploy Strategy per Module

You can also overwrite the Deploy Strategy for specific Modules under the config key magento-deploystrategy-overwrite

{ 
    "repositories": [
        {
            "type": "composer",
            "url": "packages.firegento.com"
        }
    ],
    "require": {  
        "bragento/magento-composer-installer": "~1",  
        "magento/core": "~1.9",
        "firegento/magesetup": "~2"
    },  
    "extra": {  
        "magento-deploystrategy": "symlink",
        "magento-deploystrategy-overwrite": {
            "firegento/magesetup": "copy"
        }
    }  
}

Auto Append Gitignore

You can define that deployed files will be automatically added to .gitignore in magento root

{
    "extra": {  
        "auto-append-gitignore": true
    }  
}

Contributing

make pull requests solely from the develop Branch.
run the tests before making a pull request

bragento-composer-installer's People

Contributors

brosenberger avatar davidverholen avatar gitter-badger avatar

Watchers

 avatar  avatar

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.