Orbit is a flat-file driver for Laravel Eloquent

Related tags

Laravel orbit
Overview

Orbit

Laravel v8.x PHP 7.4

Orbit is a flat-file driver for Laravel Eloquent. It allows you to replace your generic database with real files that you can manipulate using the methods you're familiar with.

Installation

To install Orbit, run the following command in your project:

composer require ryangjchandler/orbit

Usage

To begin using Orbit, create a Laravel model and use the Orbit\Concerns\Orbital trait.

class Post extends Model
{
    use \Orbit\Concerns\Orbital;
}

The Orbital trait is responsible for hooking into the Eloquent lifecycle and ensuring all of your interactions are handled correctly.

Defining the Schema

Just like a database migration, you need to define the different pieces of data that your Orbit model can have. Add a public static function schema(Blueprint $table) method to your model.

This method will need to accept an instance of Illuminate\Database\Schema\Blueprint, just like a migration.

use Illuminate\Database\Schema\Blueprint;

class Post extends Model
{
    use \Orbit\Concerns\Orbital;

    public static function schema(Blueprint $table)
    {
        $table->string('title');
        $table->string('slug');
        $table->timestamp('published_at');
    }
}

If some of your data is optional, make sure the corresponding column is nullable.

Storing content

By default, all content is stored inside of a content folder in the root of your application. If you wish to change this, publish the orbit.php configuration file and change the orbit.paths.content option.

Orbit will transform the base name of your model into a pluralized snake-cased string and use that as the main folder name, e.g. Post -> content/posts, PostCategory => content/post_categories.

🚨 Changing the name of a model will prevent Orbit from finding any existing records in the old folder. If you wish to change the name of the folder, overwrite the public static function getOrbitalName method on your model class and return the old name instead.

Any time you call Model::create(), Model::update or Model::delete, Orbit will intercept those calls and forward to the necessary driver method. The driver is then responsible for performing the necessary file system calls.

Changing the primary key

Just like a normal Eloquent model, you can change the primary key of your Orbit model. Overwrite the Model::getKeyName method and return the name of your new model.

class Post extends Model
{
    use Orbital;

    public function getKeyName()
    {
        return 'slug';
    }
    
    public function getIncrementing()
    {
        return false;
    }
}

If your model's primary key (the key you defined in getKeyName) doesn't need to automatically increment, you should either define public $incrementing = false on the model or overwrite the getIncrementing method.

Standard Orbit drivers will respect the new key name and use that when creating, updating and deleting files on disk, e.g. a Post with the slug hello-world will write to the content/posts/hello-world.md file.

🚨 Changing the key for a model after records already exist can cause damage. Be sure to rename your files afterwards so that Orbit doesn't create duplicate content.

Soft Deletes

Since Orbit needs to update files on disk when your model is updated, the standard Eloquent SoftDeletes trait doesn't quite work. If you want to add soft delete support to your Orbit model, you can instead use the Orbit\Concerns\SoftDeletes trait.

This trait uses the Eloquent one under-the-hood, so you can still access all of your normal SoftDeletes methods, including isForceDeleting() and forceDelete().

The Orbit version adds in the necessary hooks to perform file system operations as well as ensure you don't completely delete your content.

Validation Rules

When dealing with validation rules that check against a database like exists and unique, you should use the fully-qualified namespace (FQN) of the model instead of the table name.

This is because Orbit runs on a separate database connection - using the FQN will allow Laravel to correctly resolve the qualified table name.

class StorePostRequest extends FormRequest
{
    public function authorize(): bool
    {
        return true;
    }

    public function rules(): array
    {
        return [
            'slug' => 'required|alpha_dash|unique:App\Post,id',
            // 'slug' => ['required', 'alpha_dash', Rule::unique(Post::class)],
            'title' => 'required',
            'description' => 'required',
        ];
    }
  }

Testing

As previously mentioned in the Validation Rules section, Orbit operates on a custom connection called orbit. This means that Laravel's database testing utilities will work, as long as you specify the connection name.

$this->assertDatabaseCount('posts', 5, 'orbit');

$this->assertDatabaseHas('posts', [
    'title' => 'Hello, world',
    'slug' => 'hello-world',
], 'orbit');

Drivers

Orbit is a driver-based package, making it very easy to change the storage format of your data.

Out of the box, Orbit provides the following drivers:

  • md -> Orbit\Drivers\Markdown
  • json => Orbit\Drivers\Json
  • yaml => Orbit\Drivers\Yaml
  • md_json => Orbit\Drivers\MarkdownJson

md

This is a Markdown that is capable of parsing Markdown files, as well as YAML front-matter.

When Orbit loads files using this driver, it will map each front-matter key into a column in your models schema.

By default, the Markdown driver will also add a TEXT content column to your schema. This is used to store the Markdown body from the file.

💡 If you wish to customise the name of the content column, you can use the Markdown::contentColumn() method and provide a new column name. This is applied to all models that use the Markdown driver.

json

This is a JSON driver that is capable of parsing .json files. Each key in the file is mapped to a column in your schema.

yaml

This is a YAML driver that is capable of parsing .yml files. Each key in the file is mapped to a column in your schema.

md_json

This driver is very similar to the Markdown / md driver, but it supports JSON-based front-matter as opposed to the default YAML format.

💡 If you wish to customise the name of the content column, you can use the MarkdownJson::contentColumn() method and provide a new column name. This is applied to all models that use the MarkdownJson driver.

Registering drivers

You can register custom Orbit drivers by using the Orbit::extend method. You should call this method from the boot method in a ServiceProvider.

\Orbit\Facades\Orbit::extend('json', function ($app) {
    return new \App\Drivers\JsonDriver($app);
})

All drivers must implement the Orbit\Contracts\Driver contract, or extend the Orbit\Drivers\FileDriver class. This enforces drivers to have at least 4 methods:

interface Driver
{
    public function shouldRestoreCache(string $directory): bool;

    public function save(Model $model, string $directory): bool;

    public function delete(Model $model, string $directory): bool;

    public function all(string $directory): Collection;
}

Here is what each method is used for:

  • shouldRestoreCache - used to determine if the file cache should be updated.
  • save - used to persist model changes to a file on disk, or create a new file.
  • delete - used to delete an existing file on disk
  • all - used to retrieve all records from disk and cache.

Extending FileDriver

Extending the Orbit\Drivers\FileDriver class is useful when you want some of the heavy lifting done for you. To work with this base class, you should do the following:

  1. Implement an extension(): string method that returns the file extension as a string, i.e. return 'md' for Markdown.
  2. Implement a dumpContent(Model $model): string method. This method should return the updated content for the file.
  3. Implement a parseContent(SplFileInfo $file): array method. This method should return an array of key => value pairs, where each key is a column in the schema.

Changing drivers

If you wish to use a different driver for one of your models, you can add a public static $driver property to your model and set the value to the name of a driver.

class Post extends Model
{
    use Orbital;

    public static $driver = 'json';
}

Driver names are determined when they are registered with Orbit. You should always use the string name of the driver instead of the fully-qualified class name.

Git Integration (experimental)

Orbit comes with convenient Git integration out of the box. This means that any changes made to your content can be automatically persisted back to your Git repository, keeping everything up-to-date.

To enable Git integration, define a new ORBIT_GIT_ENABLED environment variable in your .env file and set the value to true.

Events

When Git integration is enabled, Orbit will add event listeners to the OrbitalCreated, OrbitalUpdated and OrbitalDeleted events and commit any changed files back to your repository.

This is extremely powerful and can greatly improve your local - production workflows.

Customising the repository root

By default, Orbit uses the base_path as your repositories root directory. If this is not applicable to your application, you can change the path by defining an ORBIT_GIT_ROOT environment variable and setting it's value to the root of your Git repository.

Customising the author name and email

By default, Orbit will use the system's name and email address when making commits to your repository. If you wish to change the name, use the ORBIT_GIT_NAME and ORBIT_GIT_EMAIL environment variables.

If you would like to use a more dynamic name and email address, you can use the Orbit::resolveGitNameUsing and Orbit::resolveGitEmailUsing methods instead:

public function boot()
{
    Orbit::resolveGitNameUsing(function () {
        return Auth::user()->name;
    });

    Orbit::resolveGitEmailUsing(function () {
        return Auth::user()->email;
    });
}

Customising the Git binary

If your Git binary is not found in the usual place (/usr/bin/git on most UNIX machines), you can customise the location using the ORBIT_GIT_BINARY environment variable.

Comments
  • Error on orbit:cache command

    Error on orbit:cache command

    When I launched the command, I have this error :

    Symfony\Component\ErrorHandler\Error\FatalError
    
    Cannot declare class HappyToDev\Typhoon\App\Providers\RepositoryServiceProvider, because the name is already in use
    

    image

    opened by happytodev 9
  • fix: only null out nullable columns in content files

    fix: only null out nullable columns in content files

    Closes #107.

    This was throwing an exception because Orbit was defaulting any missing columns/data to null, which would only work if a field was nullable.

    I'm surprised this hasn't come up sooner.

    bug 
    opened by ryangjchandler 9
  • Manipulating markdown files directly breaks functionality

    Manipulating markdown files directly breaks functionality

    I just played around with the markdown driver and it seems a bit fragile. When I modify a file directly or add another file to the folder I get an empty collection when running Model::all(). Neither reverting the changed nor deleting the sqlite database or the new file helps. Only when I removed all files and start over the driver starts working again.

    No issues with the YAML and JSON driver.

    bug 
    opened by pxlrbt 9
  • Suggestion: When row isn't defined in file, fallback to default instead of null.

    Suggestion: When row isn't defined in file, fallback to default instead of null.

    Right now, the behavior for an undefined row is to just insert null, wich gives an error if the field isn't nullable. I think it would be better to fallback to default if it is undefined, just how the Model::create() method would do.

    enhancement 
    opened by alexanderhorner 8
  • migration returning that the table already exists

    migration returning that the table already exists

    Added to my project today as was looking for a flat-file version of a db since I really only have one table that I would be creating. Can you please help on getting the migration working, and how exactly I'd be seeding it?

    Additionally, since running migrations was still trying to connect to "mysql", I updated the config > databases > 'default' => 'orbit' // correct or no?

    For the migration up() I have: Schema::create('products', function (Blueprint $table) { $table->string('identifier')->unique(); $table->string('name'); $table->string('decryption_key'); $table->string('api_key'); $table->string('api_end_point'); $table->json('api_data_config'); $table->json('api_registration_config'); });

    Running it I get (did a remove of the previous run when I saw that it stating "exists"):

    $ rm -rf content/products/ $ php artisan migrate Migrating: 2021_04_23_000000_create_products_table

    Illuminate\Database\QueryException

    SQLSTATE[HY000]: General error: 1 table "products" already exists (SQL: create table "products" ("identifier" varchar not null, "name" varchar not null, "decryption_key" varchar not null, "api_key" varchar not null, "api_end_point" varchar not null, "api_data_config" text not null, "api_registration_config" text not null))

    at vendor/laravel/framework/src/Illuminate/Database/Connection.php:678 674▕ // If an exception occurs when attempting to run a query, we'll format the error 675▕ // message to include the bindings with SQL, which will make this exception a 676▕ // lot more helpful to the developer instead of just the database's errors. 677▕ catch (Exception $e) { ➜ 678▕ throw new QueryException( 679▕ $query, $this->prepareBindings($bindings), $e 680▕ ); 681▕ } 682▕

      +9 vendor frames
    

    10 database/migrations/2021_04_23_000000_create_products_table.php:49 Illuminate\Support\Facades\Facade::__callStatic("create")

      +21 vendor frames
    

    32 artisan:37 Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

    opened by GlennBags 5
  • Fix exception from autoloading when running `orbit:cache`

    Fix exception from autoloading when running `orbit:cache`

    When running php artisan orbit:cache with a simple model on a fresh install, the following error occurred:

    Cannot declare class App\Console\Kernel, because the name is already in use

    Digging into the code a bit, I found out that the second argument to class_exists determines whether or not to autoload the class you're testing. And, the default value is true.

    Marking this false fixed the issue for me.

    opened by theutz 4
  • Can't install - OrbitServiceProvider.php syntax error

    Can't install - OrbitServiceProvider.php syntax error

    I thought I'd give this a try as it looks useful (to me!). Trying to add it to an existing Laravel project with:

    composer require ryangjchandler/orbit

    but it fails with:

    > Illuminate\Foundation\ComposerScripts::postAutoloadDump
    > @php artisan package:discover --ansi
    
    In OrbitServiceProvider.php line 31:
    
     syntax error, unexpected '=>' (T_DOUBLE_ARROW), expecting ')'
    
    Script @php artisan package:discover --ansi handling the post-autoload-dump event returned with error code 1
    
    Installation failed, reverting ./composer.json and ./composer.lock to their original content.
    

    This is on Windows 10, PHP8.1

    opened by toby1kenobi 4
  • Add orbit:cache command

    Add orbit:cache command

    This PR adds an orbit:cache command which finds all non-abstract Model classes anywhere within your app_path() that use the Orbital trait and calls migrate() on them.

    The only drawback I can see is that if you were including Orbital Models from Composer dependencies in vendor they would not be migrated by this command, but I don't know if you want to go to that level with this command.

    Example output:

    No models found: Screen Shot 2022-03-11 at 9 17 59 pm Models found: Screen Shot 2022-03-11 at 9 17 35 pm

    Closes #102

    opened by jwpage 4
  • Call to undefined method App\Models\Test::getOrbitOptions()

    Call to undefined method App\Models\Test::getOrbitOptions()

    Call to undefined method App\Models\Test::getOrbitOptions()

    Replicate:

    1. Create fresh Laravel Project
    2. Install Orbit
    3. Make new Model with Orbital
    4. Try to run Model::all() via php artisan tinker

    Idk if this maybe an issue with my machine, or if I forgot to configure something?

    opened by alexanderhorner 4
  • mkdir(): Read-only file system

    mkdir(): Read-only file system

    Getting this console error whenever I try to call "Model::create()".

       ErrorException 
    
      mkdir(): Read-only file system
    
      at vendor/illuminate/filesystem/Filesystem.php:616
        612▕         if ($force) {
        613▕             return @mkdir($path, $mode, $recursive);
        614▕         }
        615▕ 
      ➜ 616▕         return mkdir($path, $mode, $recursive);
        617▕     }
        618▕ 
        619▕     /**
        620▕      * Move a directory.
    
          +4 vendor frames 
      5   [internal]:0
          App\Models\Todo::bootOrbital()
    
          +5 vendor frames 
      11  app/Commands/Todo/Make.php:32
          Illuminate\Database\Eloquent\Model::__callStatic("create", [])
    
    
    wontfix 
    opened by danielh-official 3
  • Feature Request: Include subdirectories

    Feature Request: Include subdirectories

    Currently only files with the right suffix and inside the content/ directory (or whatever set in the config) are accessible. For large projects it would be great if you could sort your database files into subdirectories.

    opened by alexanderhorner 3
  • Not consistent behaviour with column mutator and accessor

    Not consistent behaviour with column mutator and accessor

    Found this possible issue while trying to use together Spatie's Laravel Translatable and Orbit but I think it's extensive to any stored column with mutator/accessor. (maybe related to this comment? https://github.com/ryangjchandler/orbit/pull/56#issuecomment-819048606)

    I'm not sure if the behaviour for mutator/accessor is the expected for simple cases, but it doesn't work with Laravel Translatable.

    Steps to reproduce

    To keep this example simple, I'll use a simple attribute. Create a Test model with this schema and attribute:

    class Test extends Model
    {
        use Orbital;
    
        protected $fillable = [
            'title',
            'amount',
        ];
    
        public static function schema(Blueprint $table)
        {
            $table->id();
            $table->integer('amount');
        }
    
        protected function amount(): Attribute
        {
            return Attribute::make(
                get: fn($value) => $value / 100,
                set: fn($value) => $value * 100,
            );
        }
    }
    

    When you create a new model like this:

    $model = Test::create([
      'amount' => 12.34,
    ]);
    

    If you retrieve the model later, it'll work and pass the tests, because it's stored correctly on the SQLite as 1234 but not in the Markdown, stored as amount: 12.34.

    Even if you remove the cache after creating and before retrieving it still works because the code uses the setter to create the SQLite.

    If this is the expected behaviour, it won't work with packages like Laravel Translatable because they're managing JSON columns with multiple languages but assigning a default locale on the getter, so you lose other translations on every save. I can expand this issue with a replicable example for Laravel Translate if the previous behaviour for attributes is the expected one.

    Proposed solution

    Don't use the getter during the file store and the setter during the get from the file to create the SQLite in order to store the same original content on SQLite and files.

    1. Don't use the Model getter to store the file. That would keep the 1234 value on the file and also the JSON string for translations. That happens on this line of the FileDriver: https://github.com/ryangjchandler/orbit/blob/2a812a57ce295283e3fe7840bf51e7c08990bc11/src/Drivers/FileDriver.php#L88
    2. Don't use the setter to retrieve values from files to create the SQLite: https://github.com/ryangjchandler/orbit/blob/2a812a57ce295283e3fe7840bf51e7c08990bc11/src/Concerns/Orbital.php#L185

    With these changes, SQLite and files should store the data the same way. I've found some collateral benefits of this, like datetimes that would be stored in the same format as the database, but that would be a breaking change for existing installations.

    I've tried to find a non-breaking solution to make it compatible with Spatie's Laravel Translatable but didn't find it.

    I can work on a PR if you confirm which should be the expected behaviour for accessors and mutators on Orbit. Thanks!

    opened by dtorras 2
  • Add tests for `eloquent.created` event

    Add tests for `eloquent.created` event

    Not strictly that useful because eloquent creation / update methods are being used already.

    I am going to add these tests to my upsert PR and see if I can get them working. Thought they might be worth adding to the package anyway 🤷‍♂️

    opened by johncarter- 0
  • Refactor: Seed using chunked upserts

    Refactor: Seed using chunked upserts

    First of all, I got a bit carried away with this PR and I fully appreciate that it might not be the direction that you want to take the package, so if you don't want to merge it, I'm happy to maintain my own fork.

    Disclaimer: This is by far the biggest PR I have ever written so I apologise for any best practices / etiquette I haven't adhered to. I know it would have been better as smaller PRs but it felt like they would be too interdependent.

    Key changes

    Performance

    The main impetus for the original PR was to fix the speed of rebuilding the database in v2 compared to v1. For reference, a full clear and rebuild of the DB for my test site ( with 20 models and ~17,000 files ) in v2 took ~140s locally, after this PR it takes ~4s.

    The performance degradation was due to switching from a chunked upsert statement in v1, to updateOrCreate() for models that needed seeding. I reverted the update/create method back to upsert for the obvious performance benefits.

    Eloquent events

    I understand using upsert stops Laravel model events being dispatched when manually editing files. Model events are still dispatched when using standard Model::create(), update() and delete() methods.

    When manually editing files I have added a new OrbitSeeded event, which is dispatched on every model that was seeded. This will allow users to optionally listen to that event which is the manual editing version of both saved and updated Eloquent events. Possibly fixes #136

    Removal of Meta

    I am not sure how important the previous Meta was, but I have removed it in favour of dynamically adding the orbit_file_path column to the DB schema. The reason I removed the model and table, was that it added overhead to the performance to have to upsert and retrieve two tables, essentially duplicating queries that could have been done in one.

    I understand that adding the column to the model table could be considered to be polluting the user's data, but IMO the files are the one source of truth and so what happens in the database is up to this package.

    Handling manually deleting files

    Previously, unless I missed it, when you deleted a file from the source directory, the DB would not be aware of this, so the manually deleted record would still be in the database.

    I have added a method that handles deleted files, handleDeletedFiles() which diffs the full directory of files compared to the orbit_file_paths that are stored in the DB. If there are any files in the DB not in the files then the DB record is deleted.

    This is an expensive operation which would happen on every model boot. I'm sure it would be fine on ~50 files, but on my site it added ~400ms to the request. As a result I added a config option orbit.manual_mode which will disable checking for manually removed files. This will almost definitely want to be false in production, especially on bigger sites.

    Note: Model::delete() will always delete the file, regardless of orbit.manual_mode.

    Many to many table migration

    Fixes #116.

    When the Orbital migrate() is run in model boot, we now discover any many-to-many relationships on that model that use a ->withPivot() and new up the pivot model to perform any migrations / seeding.

    Tests

    I have added some tests for:

    • Many to many pivot models
    • Custom casts
    • Seeder events
    • Manual events

    I also was experiencing inconsistent test runs when using the tearDown Model::all()->each->delete() so I replaced it on all tests with a manual deletion of the content directory using the File facade.

    Todo

    • [x] Deleting a many to many relationship should delete the pivot model.
    • [ ] Update README
    opened by johncarter- 0
Releases(v1.1.4)
  • v1.1.4(Aug 19, 2022)

    What's Changed

    • Typo in CacheCommand.php by @happytodev in https://github.com/ryangjchandler/orbit/pull/140
    • Fix exception from autoloading when running orbit:cache by @theutz in https://github.com/ryangjchandler/orbit/pull/139

    New Contributors

    • @happytodev made their first contribution in https://github.com/ryangjchandler/orbit/pull/140
    • @theutz made their first contribution in https://github.com/ryangjchandler/orbit/pull/139

    Full Changelog: https://github.com/ryangjchandler/orbit/compare/v1.1.3...v1.1.4

    Source code(tar.gz)
    Source code(zip)
  • v2.0.0-beta1(May 9, 2022)

    What's Changed

    • getLaravel directly from CacheCommand by @jwpage in https://github.com/ryangjchandler/orbit/pull/104
    • Run phpstan workflow on pull_request by @jwpage in https://github.com/ryangjchandler/orbit/pull/108
    • tests: scout support by @ryangjchandler in https://github.com/ryangjchandler/orbit/pull/106
    • Keep snake-casing for backwards compatibility by @johncarter- in https://github.com/ryangjchandler/orbit/pull/128
    • Use Finder::date() to limit files to iterate over by @johncarter- in https://github.com/ryangjchandler/orbit/pull/132

    Full Changelog: https://github.com/ryangjchandler/orbit/compare/v1.1.2...v2.0.0-beta1

    Source code(tar.gz)
    Source code(zip)
  • v1.1.3(Mar 22, 2022)

    What's Changed

    • getLaravel directly from CacheCommand by @jwpage in https://github.com/ryangjchandler/orbit/pull/104
    • Run phpstan workflow on pull_request by @jwpage in https://github.com/ryangjchandler/orbit/pull/108
    • tests: scout support by @ryangjchandler in https://github.com/ryangjchandler/orbit/pull/106
    • fix: only null out nullable columns in content files by @ryangjchandler in https://github.com/ryangjchandler/orbit/pull/111

    Full Changelog: https://github.com/ryangjchandler/orbit/compare/v1.1.2...v1.1.3

    Source code(tar.gz)
    Source code(zip)
  • v1.1.2(Mar 15, 2022)

    What's Changed

    • Add orbit:cache command by @jwpage in https://github.com/ryangjchandler/orbit/pull/103

    New Contributors

    • @jwpage made their first contribution in https://github.com/ryangjchandler/orbit/pull/103

    Full Changelog: https://github.com/ryangjchandler/orbit/compare/v1.1.1...v1.1.2

    Source code(tar.gz)
    Source code(zip)
  • v1.1.1(Mar 6, 2022)

    What's Changed

    • fix: store orbit meta in separate db by @ryangjchandler in https://github.com/ryangjchandler/orbit/pull/100

    Full Changelog: https://github.com/ryangjchandler/orbit/compare/v1.1.0...v1.1.1

    Source code(tar.gz)
    Source code(zip)
  • v1.1.0(Feb 27, 2022)

    What's Changed

    • feature: support nested files (using patterns) by @ryangjchandler in https://github.com/ryangjchandler/orbit/pull/95

    Full Changelog: https://github.com/ryangjchandler/orbit/compare/v1.0.2...v1.1.0

    Source code(tar.gz)
    Source code(zip)
  • v1.0.2(Feb 12, 2022)

    What's Changed

    • Use larastan v2.0 for laravel 9 by @leonardocustodio in https://github.com/ryangjchandler/orbit/pull/92
    • Update versions in Readme by @Jubeki in https://github.com/ryangjchandler/orbit/pull/94
    • Move dev dependencies into right section by @Jubeki in https://github.com/ryangjchandler/orbit/pull/93

    New Contributors

    • @leonardocustodio made their first contribution in https://github.com/ryangjchandler/orbit/pull/92
    • @Jubeki made their first contribution in https://github.com/ryangjchandler/orbit/pull/94

    Full Changelog: https://github.com/ryangjchandler/orbit/compare/v1.0.1...v1.0.2

    Source code(tar.gz)
    Source code(zip)
  • v1.0.1(Jan 17, 2022)

    What's Changed

    • feature: conditionally disable orbit by @ryangjchandler in https://github.com/ryangjchandler/orbit/pull/87
    • fix: don't filter falsy values from json driver by @ryangjchandler in https://github.com/ryangjchandler/orbit/pull/88

    Full Changelog: https://github.com/ryangjchandler/orbit/compare/v1.0.0...v1.0.1

    Source code(tar.gz)
    Source code(zip)
  • v1.0.0(Jan 17, 2022)

    What's Changed

    • feature: Laravel 9.x support by @ryangjchandler in https://github.com/ryangjchandler/orbit/pull/85

    Upgrading

    Please consult the UPGRADE.md file for more information on upgrading from v0.x to v1.x.

    Full Changelog: https://github.com/ryangjchandler/orbit/compare/v0.9.1...v1.0.0

    Source code(tar.gz)
    Source code(zip)
  • v0.9.1(Sep 14, 2021)

  • v0.9.0(Jul 2, 2021)

  • v0.8.0(Jun 2, 2021)

    Added

    • Added a new orbit:pull command. (#67)
    • Added a new orbit:commit command. (#67)
    • Added a better set of Git tools, such as custom commit messages and better path targeting. (#67)
    Source code(tar.gz)
    Source code(zip)
  • v0.7.4(Apr 4, 2021)

  • v0.7.3(Apr 3, 2021)

  • v0.7.2(Mar 29, 2021)

  • v0.7.1(Mar 26, 2021)

  • v0.7.0(Mar 25, 2021)

  • v0.6.4(Mar 24, 2021)

  • v0.6.3(Mar 23, 2021)

  • v0.6.2(Mar 23, 2021)

  • v0.6.1(Mar 22, 2021)

    Fixed

    • Fixed Markdown driver relying on content column. (#31)

    Added

    • Added support for driver specific schema. (#31)
    • Added support for customising the content column on Markdown driver. (#32)
    Source code(tar.gz)
    Source code(zip)
  • v0.6.0(Mar 22, 2021)

    Added

    • Added new Yaml file driver. (#19 - @Gummibeer)

    Changes

    • Changed from dynamic connection to registered connection in database.connections.orbit to improve Laravel-interop. (#24)
    Source code(tar.gz)
    Source code(zip)
  • v0.5.2(Mar 22, 2021)

  • v0.5.1(Mar 22, 2021)

  • v0.5.0(Mar 22, 2021)

    Added

    • Added new Json driver. (#8)
    • Added new test suite. (#12)

    Fixed

    • Fixed issue with multi-word directory names. (#15)
    • Fixed issue where $driver wasn't possible. (#16)
    Source code(tar.gz)
    Source code(zip)
  • v0.4.1(Mar 22, 2021)

  • v0.4.0(Mar 22, 2021)

  • v0.3.1(Mar 21, 2021)

  • v0.3.0(Mar 21, 2021)

  • v0.2.0(Mar 21, 2021)

Owner
Ryan Chandler
Ryan Chandler
Renamify is a package for Laravel used to rename a file before uploaded to prevent replacing exists file which has the same name to this new uploaded file.

Renamify Laravel package for renaming file before uploaded on server. Renamify is a package for Laravel used to rename a file before uploaded to preve

MB'DUSENGE Callixte 2 Oct 11, 2022
Sebuah aplikasi file hosting sederhana yang berguna untuk menyimpan berbagai file

About Laravel Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experie

Willy Ferry 2 Nov 25, 2021
Google Cloud Storage filesystem driver for Laravel

Google Cloud Storage filesystem driver for Laravel Google Cloud Storage filesystem driver for Laravel. This started as a fork from Superbalist/laravel

Spatie 88 Dec 16, 2022
A Laravel Broadcast Driver for Centrifugo

Laravel Centrifugo Features Compatible with latest Centrifugo 3.0.3 Contains instructions and configuration file for setting up with Laravel Sail Requ

null 7 Jun 29, 2022
Driver for Laravel Scout search package based on tntsearch

Driver for Laravel Scout search package based on https://github.com/teamtnt/tntsearch

TNT Studio 1k Dec 27, 2022
SingleStore DB Driver for Laravel

SingleStore DB Driver for Laravel This package provides SingleStore specific schema options, currently supporting keys & shard keys, alongside setting

Charlie Joseph 16 Oct 18, 2022
Driver for managing cash payments in the Cashier Provider ecosystem

Cash Driver Provider Installation To get the latest version of Cash Driver Provider, simply require the project using Composer: $ composer require cas

Cashier Provider 4 Aug 30, 2022
Laravel comments - This package enables to easily associate comments to any Eloquent model in your Laravel application

Laravel comments - This package enables to easily associate comments to any Eloquent model in your Laravel application

Rubik 4 May 12, 2022
This Laravel package merges staudenmeir/eloquent-param-limit-fix and staudenmeir/laravel-adjacency-list to allow them being used in the same model.

This Laravel package merges staudenmeir/eloquent-param-limit-fix and staudenmeir/laravel-adjacency-list to allow them being used in the same model.

Jonas Staudenmeir 5 Jan 6, 2023
An Eloquent Way To Filter Laravel Models And Their Relationships

Eloquent Filter An Eloquent way to filter Eloquent Models and their relationships Introduction Lets say we want to return a list of users filtered by

Eric Tucker 1.5k Jan 7, 2023
Easy creation of slugs for your Eloquent models in Laravel

Eloquent-Sluggable Easy creation of slugs for your Eloquent models in Laravel. NOTE: These instructions are for the latest version of Laravel. If you

Colin Viebrock 3.6k Dec 30, 2022
Automatically validating Eloquent models for Laravel

Validating, a validation trait for Laravel Validating is a trait for Laravel Eloquent models which ensures that models meet their validation criteria

Dwight Watson 955 Dec 25, 2022
Laravel Ban simplify blocking and banning Eloquent models.

Laravel Ban Introduction Laravel Ban simplify management of Eloquent model's ban. Make any model bannable in a minutes! Use case is not limited to Use

cybercog 879 Dec 30, 2022
cybercog 996 Dec 28, 2022
Collection of the Laravel/Eloquent Model classes that allows you to get data directly from a Magento 2 database.

Laragento LAravel MAgento Micro services Magento 2 has legacy code based on abandoned Zend Framework 1 with really ugly ORM on top of outdated Zend_DB

Egor Shitikov 87 Nov 26, 2022
The missing laravel helper that allows you to inspect your eloquent queries with it's bind parameters

Laravel Query Inspector The missing laravel helper that allows you to ispect your eloquent queries with it's bind parameters Motivations Let's say you

Mouad ZIANI 59 Sep 25, 2022
Laravel Quran is static Eloquent model for Quran.

Laravel Quran بِسْمِ ٱللّٰهِ الرَّحْمٰنِ الرَّحِيْمِ Laravel Quran is static Eloquent model for Quran. The Quran has never changed and never will, bec

Devtical 13 Aug 17, 2022
A package for Laravel One Time Password (OTP) generator and validation without Eloquent Model, since it done by Cache.

Laravel OTP Introduction A package for Laravel One Time Password (OTP) generator and validation without Eloquent Model, since it done by Cache. The ca

Lim Teck Wei 52 Sep 6, 2022
Provides a Eloquent query builder for Laravel or Lumen

This package provides an advanced filter for Laravel or Lumen model based on incoming requets.

M.Fouladgar 484 Jan 4, 2023