Hướng dẫn cài đặt Drupal 8 bằng Console globally năm 2015

Hướng dẫn cài đặt Drupal 8 bằng Console globally năm 2015

As I mentioned on a previous post, one of the most recurring questions (the 2nd most to be precise) since project started is why is the installation process modifying the composer.json & composer.lock file, or why is the installer adding new libraries to "core/vendor" directory, because you know that is considered hacking the core.

And as you may know that is no longer an issue, since we release an installer you can read about on the Try the new Drupal Console installer and executable phar file

This new installer generates a new issue and question, why this executable must live inside the Drupal installation, why not accessing the console.phar from anywhere on your system, why not having a global instalation as composer or drush does.

After some code refactoring, I am happy to announce we have a new release v0.5.0 with several improvements and fixes and starting on this version we can provide this global execution feature on the Drupal Console project.

How does this change the current installation process?. I will describe it here: 

Executing the installer:

​//Run this in your terminal to get the latest Console version:​

$ curl -LSs http://drupalconsole.com/installer | php​

​// Or if you don't have curl:​

$ php -r "readfile('http://drupalconsole.com/installer');" | php

Accessing console from anywhere on your system:

To access console globally move the executable 'console.phar' to a directory that is already in your PATH.

​// Run this in your terminal to get the latest Console version:​

$ mv console.phar /usr/local/bin/drupal

​// Depends of the rights of your user you have to user sudo command to execute the mv​

​// use the project​

drupal generate:module

You can see how easy is to run the installation process and execute the console globally on the following animated gif:

Repeating the same exercise and putting all the pieces together as in the previous installer post. I will to show how to create a Drupal 8 module in 3 easy steps:

How to create a module

1 curl -LSs http://drupalconsole.com/installer  | php

2 mv console.phar /usr/local/bin/drupal

3 drupal generate:module

Are you interested and what was changed, you can also take a look at the Pull Request

What is next ?, why having this global executable is important ?

I will list a few points why this new global executable is important for the lifecycle and roadmap of the Drupal Console project:

* Add a new self-update command to make easy update to new releases * Work on the documentation, since installation process will probably not change * Add a new set of command like site:install * Take advantage of site aliases * Work on this issue Integrate console with drush * Add console commands to wrap drush commands

Feel free to try the project new installer instructions and global executable file, and as usual feel free to ask any questions commenting on this page, or adding a new issue on the drupal project page or the github repository.

Bạn thấy bài viết này như thế nào?: 
No votes yet
Ảnh của Tommy Tran

Tommy owner Express Magazine

Drupal Developer having 9+ year experience, implementation and having strong knowledge of technical specifications, workflow development. Ability to perform effectively and efficiently in team and individually. Always enthusiastic and interseted to study new technologies

  • Skype ID: tthanhthuy

Tìm kiếm bất động sản

 

Advertisement

 

jobsora

Dich vu khu trung tphcm

Dich vu diet chuot tphcm

Dich vu diet con trung

Quảng Cáo Bài Viết

 
Google và Facebook đang đánh nhau ở đâu?

Google và Facebook đang đánh nhau ở đâu?

Dấu hiệu cho thấy cuộc chiến Google – Facebook sẽ ngày càng khốc liệt: tranh giành người dùng, quảng cáo trực tuyến, mạng xã hội..

Chia sẻ 6 loại console giúp việc debugging của bạn dễ dàng hơn

Chia sẻ 6 loại console giúp việc debugging của bạn dễ dàng hơn

Trong quá trình coding ắt hẳn chúng ta không ít lần cần đến sự hỗ trợ của console để debugging. Một trong những lệnh hữu ích nhất và phổ biết nhất mà bất kì một lập trình viên nào cũng biết đến

Hướng dẫn xây dựng SaaS business with Drupal

Hướng dẫn xây dựng SaaS business with Drupal

Have you ever thought about building your own Software-as-a-Service (SaaS) business based on Drupal

Công ty diệt chuột T&C

 

Diet con trung