marianvlad/nova-env-card

A Laravel Nova card for editing .env file .

v1.0.0 2018-08-24 22:04 UTC

This package is not auto-updated.

Last update: 2024-04-15 05:00:23 UTC


README

Latest Version on Packagist Total Downloads

Edit Environment file inside a modal.

68747470733a2f2f692e696d6775722e636f6d2f714275334361452e706e67 68747470733a2f2f692e696d6775722e636f6d2f735039595478462e706e67

Installation

You can install the package in to a Laravel app that uses Nova via composer:

composer require marianvlad/nova-env-card

Next up, you must register the card Nova. This is typically done in the cards method of the NovaServiceProvider.

// in app/Providers/NovaServiceProvider.php

// ...

public function cards()
{
    return [
        // ...
        (new \Marianvlad\NovaEnvCard\NovaEnvCard)->canSee(function ($request) {
        	return $request->user()->role == 'admin';
        })
    ];
}

License

The MIT License (MIT). Please see License File for more information.