Nasrul Hazim Bin Mohamad

Software Development with Git


Number of practices that i’ve been doing from time to time. All theses are the basic user cases based on doing personal project.

I will add more about working in team with Git.

It’s a bit confusing at the beginning. You just need practices to master the flow of software development with Git.

Laravel: How to Create Custom Artisan Command


There’s only 3 steps required to setting up new Artisan command.

1. Step 1 – Create a new console file

php artisan make:console CommandName

2. Step 2 – Open up `app/Console/Commands/CommandName.php` and update the signature and the description property.

     * The name and signature of the console command.
     * @var string
    protected $signature = 'env:db';

     * The console command description.
     * @var string
    protected $description = 'Configure database settings';

3. Step 3 – Register your new Artisan command in `app/Console/Kernel.php`

     * The Artisan commands provided by your application.
     * @var array
    protected $commands = [
        // Commands\Inspire::class,

Now you’re ready with your new artisan command. Check your command with `php artisan`. It should have something like this one.

Screen Shot 2016-08-16 at 6.05.26 PM

Here the a sample code.



Live: Laravel 101



It’s been a while since the last time I post in my blog.

Now just to share a bit of Laravel, 101 on my Facebook Live.