generated from spatie/package-skeleton-laravel
-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
initial commit for snowflake, added snowflake singleton and HasSnowfl…
…ake primary trait
- Loading branch information
1 parent
2f132e4
commit 29bc4f5
Showing
23 changed files
with
147 additions
and
254 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 |
---|---|---|
@@ -1 +1 @@ | ||
github: :vendor_name | ||
github: pixwell-dev |
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 |
---|---|---|
@@ -1,11 +1,11 @@ | ||
blank_issues_enabled: false | ||
contact_links: | ||
- name: Ask a question | ||
url: https://github.com/:vendor_name/:package_name/discussions/new?category=q-a | ||
url: https://github.com/pixwell-dev/laravel-snowflake/discussions/new?category=q-a | ||
about: Ask the community for help | ||
- name: Request a feature | ||
url: https://github.com/:vendor_name/:package_name/discussions/new?category=ideas | ||
url: https://github.com/pixwell-dev/laravel-snowflake/discussions/new?category=ideas | ||
about: Share ideas for new features | ||
- name: Report a bug | ||
url: https://github.com/:vendor_name/:package_name/issues/new | ||
url: https://github.com/pixwell-dev/laravel-snowflake/issues/new | ||
about: Report a reproducable bug |
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 |
---|---|---|
@@ -1,3 +1,3 @@ | ||
# Security Policy | ||
|
||
If you discover any security related issues, please email :author_email instead of using the issue tracker. | ||
If you discover any security related issues, please email [email protected] instead of using the issue tracker. |
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 |
---|---|---|
@@ -1,6 +1,6 @@ | ||
The MIT License (MIT) | ||
|
||
Copyright (c) :vendor_name <:author_email> | ||
Copyright (c) pixwell-dev <[email protected]> | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
|
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 |
---|---|---|
@@ -1,23 +1,24 @@ | ||
{ | ||
"name": ":vendor_name/:package_name", | ||
"description": ":package_description", | ||
"name": "pixwell-dev/laravel-snowflake", | ||
"description": "laravel-snowflake", | ||
"keywords": [ | ||
":vendor_name", | ||
":package_name" | ||
"pixwell-dev", | ||
"laravel-snowflake" | ||
], | ||
"homepage": "https://github.com/:vendor_name/:package_name", | ||
"homepage": "https://github.com/pixwell-dev/laravel-snowflake", | ||
"license": "MIT", | ||
"authors": [ | ||
{ | ||
"name": ":author_name", | ||
"email": ":author_email", | ||
"name": "Daniel Janiga", | ||
"email": "[email protected]", | ||
"role": "Developer" | ||
} | ||
], | ||
"require": { | ||
"php": "^7.4|^8.0", | ||
"spatie/laravel-package-tools": "^1.1", | ||
"illuminate/contracts": "^8.0" | ||
"godruoyi/php-snowflake": "^1.0", | ||
"illuminate/contracts": "^8.0", | ||
"spatie/laravel-package-tools": "^1.1" | ||
}, | ||
"require-dev": { | ||
"orchestra/testbench": "^6.0", | ||
|
@@ -27,13 +28,13 @@ | |
}, | ||
"autoload": { | ||
"psr-4": { | ||
"Spatie\\Skeleton\\": "src", | ||
"Spatie\\Skeleton\\Database\\Factories\\": "database/factories" | ||
"PixwellDev\\LaravelSnowflake\\": "src", | ||
"PixwellDev\\LaravelSnowflake\\Database\\Factories\\": "database/factories" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"Spatie\\Skeleton\\Tests\\": "tests" | ||
"PixwellDev\\LaravelSnowflake\\Tests\\": "tests" | ||
} | ||
}, | ||
"scripts": { | ||
|
@@ -47,10 +48,10 @@ | |
"extra": { | ||
"laravel": { | ||
"providers": [ | ||
"Spatie\\Skeleton\\SkeletonServiceProvider" | ||
"PixwellDev\\LaravelSnowflake\\LaravelSnowflakeServiceProvider" | ||
], | ||
"aliases": { | ||
"Skeleton": "Spatie\\Skeleton\\SkeletonFacade" | ||
"LaravelSnowflake": "PixwellDev\\LaravelSnowflake\\LaravelSnowflakeFacade" | ||
} | ||
} | ||
}, | ||
|
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,33 @@ | ||
<?php | ||
|
||
return [ | ||
/* | ||
|-------------------------------------------------------------------------- | ||
| Snowflake Epoch | ||
|-------------------------------------------------------------------------- | ||
| | ||
| Here you may configure the log settings for snowflake. Set the date | ||
| the application was develop started. Don't set the date of the future. | ||
| If service starts to move, don't change. | ||
| | ||
| Available Settings: Y-m-d H:i:s | ||
| | ||
*/ | ||
'epoch' => env('SNOWFLAKE_EPOCH', '2021-02-01 00:00:00'), | ||
|
||
/* | ||
|-------------------------------------------------------------------------- | ||
| Snowflake Configuration | ||
|-------------------------------------------------------------------------- | ||
| | ||
| Here you may configure the log settings for snowflake. | ||
| If you are using multiple servers, please assign unique | ||
| ID(1-31) for Snowflake. | ||
| | ||
| Available Settings: 1-31 | ||
| | ||
*/ | ||
'worker_id' => env('SNOWFLAKE_WORKER_ID', 1), | ||
|
||
'datacenter_id' => env('SNOWFLAKE_DATACENTER_ID', 1), | ||
]; |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
Empty file.
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,16 @@ | ||
<?php | ||
|
||
namespace PixwellDev\LaravelSnowflake; | ||
|
||
use Illuminate\Support\Facades\Facade; | ||
|
||
/** | ||
* @see \PixwellDev\LaravelSnowflake\LaravelSnowflake | ||
*/ | ||
class LaravelSnowflakeFacade extends Facade | ||
{ | ||
protected static function getFacadeAccessor() | ||
{ | ||
return 'snowflake'; | ||
} | ||
} |
Oops, something went wrong.