chinmoym2004/laravel-dotenv-editor 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

chinmoym2004/laravel-dotenv-editor

最新稳定版本:v2.1.0

Composer 安装命令:

composer require chinmoym2004/laravel-dotenv-editor

包简介

A package for editing the .env file in your Laravel root. This copy has the support for Laravel 6,7 & bootstrap 4 UI

README 文档

README

Codacy Badge Latest Stable Version Total Downloads Latest Unstable Version License

Edit your Laravel .env file

This package offers you the possibility to edit your .env dynamically through a controller or model.

The current version (2.x) ships with a graphical user interface based on VueJS to offer you a very simple implementation of all features.

List of available functions:

  • check, if a given key exists
  • get the value of a key
  • get the complete content of your .env
  • get the content as JSON
  • change existing values
  • add new key-value-pairs
  • delete existing key-value-pairs
  • create/restore/delete backups
  • list all backups
  • get the content of a backup
  • enable auto-backups
  • check, if auto-backups are enabled or not
  • get and set a backup-path

Here are some images showing the gui which ships with the current version:

Overview Overview with loaded content Edit an entry Adding a new key-value-pair Backups Showing the content of a backup More options for backups Uploading Backups

Installation

Visit the Wiki-page to get more Information.

Examples

The following example shows an controller with a method, in which we change some values from the .env. Make sure, the entries you want to change, really exist in your .env.

namespace App\Http\Controllers;

use Brotzka\DotenvEditor\DotenvEditor;

class EnvController extends Controller
{
    public function test(){
        $env = new DotenvEditor();

        $env->changeEnv([
            'TEST_ENTRY1'   => 'one_new_value',
            'TEST_ENTRY2'   => $anotherValue,
        ]);
    }
}

For more exmaples visit the Wiki.

统计信息

  • 总下载量: 154
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 79
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-06-20