-
-
Notifications
You must be signed in to change notification settings - Fork 610
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3bb0038
commit 5c294f0
Showing
266 changed files
with
2,766 additions
and
17,317 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -32,4 +32,3 @@ THEME=default | |
|
||
# php 路径 | ||
PHP_PATH= | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
php: | ||
preset: laravel | ||
disabled: | ||
- unused_use | ||
finder: | ||
not-name: | ||
- index.php | ||
- server.php | ||
js: | ||
finder: | ||
not-name: | ||
- webpack.mix.js | ||
css: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,7 @@ | |
[![GitHub forks](https://img.shields.io/github/forks/WangNingkai/OLAINDEX.svg?style=flat-square)](https://github.com/WangNingkai/OLAINDEX/network) | ||
[![GitHub license](https://img.shields.io/github/license/WangNingkai/OLAINDEX.svg?style=flat-square)](https://github.com/WangNingkai/OLAINDEX/blob/master/LICENSE) | ||
|
||
<div align=center><img alt="OLAINDEX" src="https://i.loli.net/2019/06/15/5d049d72309c376133.png"/></div> | ||
<div align=center><img alt="OLAINDEX" src="https://ojpoc641y.qnssl.com/FoO82Ql-AAn6TPIUa7RtbgWCPihl.png"/></div> | ||
|
||
|
||
> 👋 本项目受 Oneindex 启发,借鉴其部分功能,在这里感谢。 项目持续开发,会加入更多功能,欢迎大家提交 issue. | ||
|
@@ -70,18 +70,7 @@ chown -R www:www * | |
|
||
本次更新进行部分重构,不再兼容老版本,请删除原先代码重新拉取部署更新 | ||
|
||
**2019.06 v4.0** | ||
|
||
1. 搜索功能增强(前台可搜索、后台设置搜索频次) | ||
2. 目录额外功能优化(文件隐藏、加密) | ||
3. 文件排序功能加强 | ||
4. 静态资源CDN更换 | ||
5. 路径优化(可自定义兼容模式) | ||
6. 后台刷新任务执行 | ||
7. 整合部分命令 | ||
8. 上传、搜索频次设置 | ||
9. 更换信息存储为数据库存储 | ||
10. 添加第三方接口 | ||
**2020.04 v5.0** | ||
|
||
### 分支说明 | ||
|
||
|
@@ -121,8 +110,6 @@ Email [[email protected]](mailto:[email protected]) | |
|
||
项目开发纯属个人爱好,如果你喜欢此项目,欢迎赞助。 | ||
|
||
同时赞助可以获得一次安装技术服务。 | ||
|
||
另可根据需求提供付费定制服务。 | ||
|
||
**赞助地址 : [https://pay.ningkai.wang](https://pay.ningkai.wang)** | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
<?php | ||
|
||
namespace App\Console\Commands; | ||
|
||
use Illuminate\Console\Command; | ||
|
||
class InstallCommand extends Command | ||
{ | ||
/** | ||
* The name and signature of the console command. | ||
* | ||
* @var string | ||
*/ | ||
protected $signature = 'install'; | ||
|
||
/** | ||
* The console command description. | ||
* | ||
* @var string | ||
*/ | ||
protected $description = 'Install App'; | ||
|
||
/** | ||
* Execute the console command. | ||
* | ||
* @return mixed | ||
*/ | ||
public function handle(): void | ||
{ | ||
// step 1 | ||
$canWritable = is_writable(storage_path()); | ||
if (!$canWritable) { | ||
$this->warn('Please make sure the [storage] path can write!'); | ||
} | ||
$lockFile = install_path('install.lock'); | ||
if (file_exists($lockFile)) { | ||
$this->warn('Already Installed!'); | ||
exit; | ||
} | ||
|
||
// step 2 | ||
$envSampleFile = base_path('.env.example'); | ||
$envFile = base_path('.env'); | ||
if (!file_exists($envSampleFile)) { | ||
$this->warn('[.env.example] file missing,Please make sure the project complete!'); | ||
exit; | ||
} | ||
$_search = [ | ||
'APP_KEY=', | ||
]; | ||
$_replace = [ | ||
'APP_KEY=' . str_random(32), | ||
]; | ||
$envExample = file_get_contents($envSampleFile); | ||
$env = str_replace($_search, $_replace, $envExample); | ||
if (file_exists($envFile)) { | ||
if ($this->confirm('Already have [.env] ,overwrite?')) { | ||
@unlink($envFile); | ||
file_put_contents($envFile, $env); | ||
} | ||
} else { | ||
file_put_contents($envFile, $env); | ||
} | ||
|
||
// step 3 | ||
$this->call('config:cache'); | ||
|
||
// step 4 | ||
$sqlFile = install_path('data/database.sqlite'); | ||
$sqlSampleFile = install_path('data/database.sample.sqlite'); | ||
if (!file_exists($sqlSampleFile)) { | ||
$this->warn('[database.sample.sqlite] file missing,Please make sure the project complete!'); | ||
exit; | ||
} | ||
if (!file_exists($sqlFile)) { | ||
$this->warn('Database not found,Creating...'); | ||
copy($sqlSampleFile, $sqlFile); | ||
} | ||
$this->call('migrate'); | ||
$this->call('db:seed'); | ||
file_put_contents($lockFile, ''); | ||
$this->call('config:cache'); | ||
$this->info('default name: [ admin ]'); | ||
$this->info('default password: [ 123456 ]'); | ||
$this->info('Install Complete!'); | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.