Merge branch 'dev' of bvbej/base-php into master
This commit is contained in:
commit
ac4a56fe6d
@ -1,3 +1,3 @@
|
||||
```shell
|
||||
php artisan vendor:publish --provider=StarPoolCloud\Providers\StarPoolCloudServiceProvider
|
||||
```
|
||||
php artisan vendor:publish --provider=BvBeJ\Providers\BvBeJServiceProvider
|
||||
```
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "starpoolcloud/base-php",
|
||||
"name": "bvbej/base-php",
|
||||
"license": "MIT",
|
||||
"authors": [
|
||||
{
|
||||
@ -19,7 +19,7 @@
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"StarPoolCloud\\": "src/"
|
||||
"BvBeJ\\": "src/"
|
||||
},
|
||||
"files": [
|
||||
"src/Handles/File/helper.php",
|
||||
@ -29,10 +29,10 @@
|
||||
"extra": {
|
||||
"laravel": {
|
||||
"providers": [
|
||||
"StarPoolCloud\\Providers\\StarPoolCloudServiceProvider"
|
||||
"BvBeJ\\Providers\\BvBeJServiceProvider"
|
||||
],
|
||||
"aliases": {
|
||||
"StarPoolCloud": "StarPoolCloud\\Facades\\StarPoolCloudFacade"
|
||||
"BvBeJ": "BvBeJ\\Facades\\BvBeJFacade"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
|
||||
return [
|
||||
'server_addr' => 'https://apollo.config.squrab.com',
|
||||
'server_addr' => 'https://config.bvbej.com',
|
||||
'cluster' => 'dev',
|
||||
'client_ip' => '127.0.0.1',
|
||||
'appid' => env('APP_NAME', ''),
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace StarPoolCloud\Commands;
|
||||
namespace BvBeJ\Commands;
|
||||
|
||||
use Exception;
|
||||
use Illuminate\Console\Command;
|
||||
@ -38,10 +38,10 @@ class ApolloConfigSync extends Command
|
||||
public function handle()
|
||||
{
|
||||
try {
|
||||
app('StarPoolCloudApollo')->updateEnv();
|
||||
app('BvBeJApollo')->updateEnv();
|
||||
$this->info('Success');
|
||||
} catch (Exception $exception) {
|
||||
$this->error("Error:{$exception->getMessage()}");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace StarPoolCloud\Facades;
|
||||
namespace BvBeJ\Facades;
|
||||
|
||||
use Illuminate\Support\Facades\Facade;
|
||||
|
||||
@ -15,10 +15,10 @@ use Illuminate\Support\Facades\Facade;
|
||||
* @method static PostJsonRequest(string $url, array $params, array $header = []): string
|
||||
* @method static YouDaoTextTranslator(string $appID, string $secret, string $text, string $lang): string
|
||||
*/
|
||||
class StarPoolCloudFacade extends Facade
|
||||
class BvBeJFacade extends Facade
|
||||
{
|
||||
protected static function getFacadeAccessor(): string
|
||||
{
|
||||
return 'StarPoolCloud';
|
||||
return 'BvBeJ';
|
||||
}
|
||||
}
|
||||
}
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace StarPoolCloud\Handles\Apollo;
|
||||
namespace BvBeJ\Handles\Apollo;
|
||||
|
||||
use Dotenv\Dotenv;
|
||||
use Exception;
|
||||
@ -457,4 +457,4 @@ class Client
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace StarPoolCloud\Handles\Apollo;
|
||||
namespace BvBeJ\Handles\Apollo;
|
||||
|
||||
class Signature
|
||||
{
|
||||
@ -53,4 +53,4 @@ class Signature
|
||||
$sign = self::generateSignature($timestamp, $pathWithQuery, $secret);
|
||||
return sprintf(self::AUTHORIZATION_FORMAT, $appId, $sign);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace StarPoolCloud\Handles;
|
||||
namespace BvBeJ\Handles;
|
||||
|
||||
use GuzzleHttp\Client;
|
||||
use GuzzleHttp\RequestOptions;
|
||||
@ -10,7 +10,7 @@ use Illuminate\Support\Facades\Log;
|
||||
use Ramsey\Uuid\Rfc4122\UuidV4;
|
||||
use Ramsey\Uuid\Uuid;
|
||||
|
||||
class StarPoolCloudHandle
|
||||
class BvBeJHandle
|
||||
{
|
||||
const DATE_FORMAT = 'Y-m-d H:i:s';
|
||||
|
||||
@ -224,4 +224,4 @@ class StarPoolCloudHandle
|
||||
return "";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
namespace StarPoolCloud\Handles\Trait;
|
||||
namespace BvBeJ\Handles\Trait;
|
||||
|
||||
use Illuminate\Auth\Events\Lockout;
|
||||
use Illuminate\Cache\RateLimiter;
|
||||
|
@ -1,15 +1,15 @@
|
||||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace StarPoolCloud\Providers;
|
||||
namespace BvBeJ\Providers;
|
||||
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
use StarPoolCloud\Commands\ApolloConfigSync;
|
||||
use StarPoolCloud\Handles\Apollo\Client;
|
||||
use StarPoolCloud\Handles\StarPoolCloudHandle;
|
||||
use BvBeJ\Commands\ApolloConfigSync;
|
||||
use BvBeJ\Handles\Apollo\Client;
|
||||
use BvBeJ\Handles\BvBeJHandle;
|
||||
|
||||
|
||||
class StarPoolCloudServiceProvider extends ServiceProvider
|
||||
class BvBeJServiceProvider extends ServiceProvider
|
||||
{
|
||||
/**
|
||||
* Bootstrap the application services.
|
||||
@ -35,11 +35,11 @@ class StarPoolCloudServiceProvider extends ServiceProvider
|
||||
*/
|
||||
public function register()
|
||||
{
|
||||
$this->app->singleton('StarPoolCloud', function () {
|
||||
return new StarPoolCloudHandle();
|
||||
$this->app->singleton('BvBeJ', function () {
|
||||
return new BvBeJHandle();
|
||||
});
|
||||
$this->app->singleton('StarPoolCloudApollo', function () {
|
||||
$this->app->singleton('BvBeJApollo', function () {
|
||||
return new Client(config('apollo'));
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user