Ever wondered if you've edited or committed anything in your project before pushing it to your repository, do this:
git status
Ever wondered if you've edited or committed anything in your project before pushing it to your repository, do this:
git status
Want to know the current version of your Ubuntu distro? Type this:
lsb_release -r
ESC keygg and it will take you to first line of the file.dG and it will clear all the lines from start to the end of the file.This can be useful when you're writing stuff, just do the following:
:set spellcheck=[lang]
Before you integrate Excel into your application, make sure your project meets the following requirements:
Download the maatwebsite/excel package using Composer:
composer require maatwebsite/excel
By default, this will be done automatically when you're installing the package but if you want to do it yourself, add this in your config/app.php file:
<?php
// ...
'providers' => [
// ...
Maatwebsite\Excel\ExcelServiceProvider::class,
],
// ...
'aliases' => [
// ...
'Excel' => 'Maatwebsite\Excel\Facades\Excel::class',
],
?>;
Last but not the least, run the vendor:publish command using artisan to publish your configuration:
php artisan vendor:publish -provider="Maatwebsite\Excel\ExcelServiceProvider"
Upon publishing, the config/excel.php configuration file will be created where you can make your changes.
Hope this helps you out!
This helped me a lot whenever I'm in a remote server trying to find a keyword or specific text amongst a bunch of files.
This command will save you a lot of time:
grep -rwn [path] -e 'pattern'
r stands for recursionn displays the line numberw matches the whole wordRefer to man find pages for more info.
This comes in handy whenever I want to look for files that exists with a specific extension in a computer or server:
find . -name "*.ext"
In addition, sometimes, you might want to look for a bunch of files with a specific extension but with matching keywords:
find .name "*.ext" | grep "keyword"
Hope you found this helpful!
When zipping a directory or a bunch of files, there'll be a lot of stuff that you want to include and exclude.
To exclude a file:
zip -r files.zip . -x file_1 file_2
Alternatively, you can choose to include files:
zip -r files.zip . -i file_1 file_2