Skip to content

Releases: Plazide/fauna-gql-upload

v2.5.0 - Concatenate schema files, init command and JSON schema

18 Jun 12:49
Compare
Choose a tag to compare

2.5.0 - June 18th, 2022

Added

  • Support for concatenating multiple schema files before uploading to Fauna. This means that you can define queries, mutations, inputs and collections in separate files. These files will then merged together into a single file before uploading it to Fauna. This requires the schemaDir option to be specified in .fauna.json.

  • Init command. This makes it easier to get started with FGU. You simply run npx fgu init, answer the questions, and you're all set.

  • JSON schema to make config writing easier. Add "$schema": "node_modules/fauna-gql-upload/config.schema.json" as the top property in your .fauna.json file to use it, or initialize the project with the init command mentioned above.

  • Support for specifying custom refs when uploading data. Thanks to @employee451 for suggesting this.

v2.3.0 - new `--mode` option and documentation site

07 Jun 16:37
Compare
Choose a tag to compare

2.3.0 - June 7th, 2021

Added

  • Documentation site. Keeping all documentation inside the README.md was getting overwhelming. Everything was on contained in one single file, and it took a while to scroll through it all. The documentation is now split up into separate pages for better browsing. Visit the new documentation site.
  • CLI option to specify schema upload mode. You could previously use the --override option to, well... override the schema. This has been deprecated in favor of a new --mode option which allows you to specify one of merge, replace, or override.

Deprecated

  • The --override option. See above for more info.

v2.2.0 - Automatically updating indexes and credentials for data

03 Jun 13:06
Compare
Choose a tag to compare

2.2.0 - June 3rd, 2021

Added

  • Automatic updating of mutated indexes. Previously, if you changed an index's terms or values you would not be able to update it. Fauna simply doesn't allow you to change an index in that way. To circumvent this, you would have to delete the index, wait 60 seconds, and create the index again. Fauna GQL Upload does this automatically now.
  • Support for adding credentials to data resources. See Adding credentials to your data

Fixed

  • Error when using { "type": "module" } in package.json. Thanks to @ry5n for reporting this in issue #30.

v2.1.0 - Custom config path, command-line options

05 Apr 10:32
Compare
Choose a tag to compare

2.1.0 - April 5th, 2021

Added

  • Custom config path. You can now specify a custom config path using the --config command-line option.
  • Support for command-line options. You can now use every option available in the config file as command-line options.

v2.0.2 - Fixed typo in readme

19 Mar 17:40
Compare
Choose a tag to compare

Fixed a small typo in README.md that suggested the default schema path was models/schema.gql, it is actually fauna/schema.gql or fauna/schema.graphql.

This required a new npm release since you can't just update the readme file.

v2.0.1 - Fix incorrect RoleResource interface

15 Mar 21:30
Compare
Choose a tag to compare

Small fix that changes the membership property in the RoleResource type to be optional.

v2.0.0 - Access providers, codegen, custom endpoints

15 Mar 14:00
Compare
Choose a tag to compare

Version 2.0.0 is out on npm and it brings a few new features and improvements. But before we get to those, I'll detail some of the breaking changes that were introduced.

Breaking changes

No more global installs

Fauna GQL Upload previously supported global installation to be used as a CLI. Support for global installations has been removed. If you have a previous global installation, I suggest removing that from your system. To continue using the package, you'll simply have to follow the installation and configuration sections below.

You need a local installation of faunadb

It was previously possible to use Fauna GQL Upload without a local faunadb installation. This is no longer possible, the package now relies solely on the faunadb version that you install.

You might need faunadb@>=4.0.0

It is still possible to upload resources with versions before 4.0.0, but if you are configuring access providers in your project, you will have to use faunadb@>=4.0.0 since that's when the AccessProvider and CreateAccessProvider functions were added.

The version of faunadb specified in peerDependencies is >=4.0.0, but if you won't be using access providers you should still be able to install older versions. You'll just have to ignore the "incorrect peer depencency" warnings.

Changing the secret environment variable

The default environment variable for your FaunaDB admin key used to be FAUNADB_SECRET. This has now changed to FGU_SECRET.

If you have previously used the default environment variable you now need to either:

  • Rename FAUNADB_SECRET to FGU_SECRET in your environment file
  • Or set the secretEnv property in .fauna.json to FAUNADB_SECRET

Changelog

Now, let's see what's changed!

Added

Changed

  • Converted project to Typescript
  • Look of logging output
  • The default environment variable for the secret key to FGU_SECRET

Removed

  • Support for global installations. You must now install the package locally and add an npm script.

Fixed

  • A few bugs

1.9.3 - Fix Typescript uploads

22 Dec 09:57
Compare
Choose a tag to compare

1.9.3 - December 22nd, 2020

Fixed

  • Error that prevented Typescript resources from being uploaded. Thanks to @seanconnollydev for fixing this in PR #16.

1.9.2 - Fixes

06 Dec 11:28
Compare
Choose a tag to compare

1.9.2 - December 6th, 2020

Fixed

  • Error when not having Typescript installed in the project directory.
  • Error when having non .js or .ts files in resource directory. Thanks to @naotone for fixing this in PR #15.

1.9.0 - Typescript support & fixes

23 Nov 11:12
Compare
Choose a tag to compare

1.9.0 - November 23rd, 2020

Added

  • Changelog.

  • GitHub releases. As per request by @cheap-glitch in issue #11, all new NPM releases will be accompanied by a GitHub release.

  • Support for typescript resource files. All files with a .ts extension are typechecked and compiled using the closest tsconfig.json file. More info under typescript in readme.

  • Support for asynchronous resources. Thanks to @cheap-glitch.

  • fgu as alias to fauna-gql.

Fixed

  • Optional config file. Previously, the command would fail when no .fauna.json file existed in the project. This was not the intended behaviour. Again, thanks to @cheap-glitch.

  • Error message is now shown when the a schema doesn't exist at the provided path.

  • Default schema path is now the same as specified in readme. Previously, the default schema path was models/schema.gql while the readme specified fauna/schema.gql. Since users were previously required to use a .fauna.json file to set the schema path, the actual default path was never used. Therefore, I do not consider this a breaking change.

  • Invalid reference error when uploading function that uses custom role. If you created a custom role which was refrenced in a UDF, fauna would throw a invalid reference error because that role did not exist at the time it was referenced. This has been fixed by first creating functions with an empty role property, and then updating the functions after the roles have been created.