To store your credentials in cache and avoid logging in every time you perform a git action, follow these steps:

  1. Navigate to your local repository folder.
  2. In the current folder’s terminal: git config --global --replace-all credential.helper cache
  3. Perform git push or git pull.
  4. Login with username and access token (access token is your password). The token can be setup in GitHub and have access to repo, workflow, write:packages and delete:packages.
  5. Repeat git push or any git action and you'll find that it doesn't ask for login credentials from now on.



You can check if the current route is active just with


Or even sub-routes (like editing, creating, or whatever with


If you prefer to use the route facade, you still can do that with


By using the * character, you can apply the active class to submenus easily:

routeIs('admin.cities*') ? 'active' : '' }}"> Cities
routeIs('admin.cities.index') ? 'active' : '' }}><a>List</a>
routeIs('admin.cities.create') ? 'active' : '' }}><a>Create</a>



  • Create a .gitignore if you have not one already
  • Edit .gitignore and add the path/to/file
  • Execute git -rm --cached path/to/file . All the removed files will be listed. The --cached file specifies that you want to remove it from repository but keep the local copy. Also you can use -r flag to remove files recursively.c
  • Run git-status to verify the changes.
  • Push the code to repository using git push.

Note: while you ignored those files from repository, they can still be viewed from history. Thus if you want them to be excluded from history as well, make sure you remove them from Git History.



Pull the package via composer:

composer require laravel/telescope --dev

Publish its assets:

php artisan telescope:install

Run database migration:

php artisan migrate

In /config/app.php remove the following line from Application Service Providers array list:


No add the following in your app/Providers/AppServiceProvider.php:

use App\Providers\TelescopeServiceProvider;

And in the register() method:

if ($this->app->isLocal()) {

That’s all and you are good to go!!



James Bhatta

James Bhatta

Manoj Bhatta. PHP developer often working in Laravel. Loved PHP just because I cant wait until compiler processes my code.