Coder Social home page Coder Social logo

joomla-console's Introduction

Joomla Command Line Tools

This is a script developed by Joomlatools to ease the management of Joomla sites.

It is designed to work on Linux and MacOS. Windows users can use it in Joomlatools Vagrant box

For available options, try running:

joomla --list

Create Sites

To create a site with the latest Joomla version, run:

joomla site:create testsite

The newly installed site will be available at /var/www/testsite and testsite.dev after that. You can login into your fresh Joomla installation using these credentials: admin / admin.

By default the web server root is set to /var/www. You can pass --www=/my/server/path to commands for custom values.

You can choose the Joomla version or the sample data to be installed:

joomla site:create testsite --joomla=2.5 --sample-data=blog

You can pick any branch from the Git repository (e.g. master, staging) or any version from 2.5.0 and up using this command.

You can also add your projects into the new site by symlinking. See the Symlinking section below for detailed information.

joomla site:create testsite --symlink=project1,project2

For more information and available options, try running:

joomla site:create --help

Delete Sites

You can delete the sites you have created by running:

joomla site:delete testsite

Symlink your code into a Joomla installation

Let's say you are working on your own Joomla component called Awesome and want to develop it with the latest Joomla version.

By default your code is assumed to be in ~/Projects. You can pass --projects-dir=/my/code/is/here to commands for custom values.

Please note that your source code should resemble the Joomla folder structure for symlinking to work well. For example your administrator section should reside in ~/Projects/awesome/administrator/components/com_awesome.

Now to create a new site, execute the site:create command and add a symlink option:

  joomla site:create testsite --symlink=awesome

Or to symlink your code into an existing site:

joomla extension:symlink testsite awesome

This will symlink all the folders from the awesome folder into testsite.dev.

Run discover install to make your component available to Joomla and you are good to go!

For more information on the symlinker, run:

  joomla extension:symlink  --help

Install Joomla extensions

You can use discover install on command line to install extensions.

joomla extension:install testsite com_awesome

You need to use the element name in your extension manifest.

For more information, run:

  joomla extension:install --help

Alternatively, you can install extensions using their installation packages using the extension:installfile command. Example:

joomla extension:installfile testsite /home/vagrant/com_component.v1.x.zip /home/vagrant/plg_plugin.v2.x.tar.gz

This will install both the com_component.v1.x.zip and plg_plugin.v2.x.tar.gz packages.

Installation instructions

  1. Download or clone this repository.

  2. Make the joomla command executable:

    $ chmod u+x /path/to/joomla-console/bin/joomla

  3. Configure your system to recognize where the executable resides. There are 3 options:

    1. Create a symbolic link in a directory that is already in your PATH, e.g.:

      $ ln -s /path/to/joomla-console/bin/joomla /usr/bin/joomla

    2. Explicitly add the executable to the PATH variable which is defined in the the shell configuration file called .profile, .bash_profile, .bash_aliases, or .bashrc that is located in your home folder, i.e.:

      export PATH="$PATH:/path/to/joomla-console/bin:/usr/local/bin"

    3. Add an alias for the executable by adding this to you shell configuration file (see list in previous option):

      $ alias joomla=/path/to/joomla-console/bin/joomla

    For options 2 and 3 above, you should log out and then back in to apply your changes to your current session.

  4. Test that joomla executable is found by your system:

    $ which joomla

  5. From joomla-console root (/path/to/joomla-console), run Composer to fetch dependencies.

    $ composer install

joomla-console's People

Contributors

ercanozkaya avatar securez avatar florianv avatar

Watchers

James Cloos avatar Kyle Hoang 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.