forked from dotansimha/graphql-yoga
-
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.
* chore: remove old infra * setup yarn 3 * style: run prettier * update readme * build: setup bob-the-bundler * Setup initial core package and agnostic handler packages (dotansimha#693) * added alpha releases and ci * use node 16 * fixes for workspaces structure * build: update deps * temporarily allow no tests in CI to pass * update contribs * init changeset * feat: add cors option (dotansimha#699) * build: add fastify-cors * fix: logging level * temp fix for cors * use cors option from user * feat: file uploads (dotansimha#696) * replace helix with ardas fork * feat: allow config option for pino logger (dotansimha#700) * feat: allow config option for pino logger * remove process.exit * test: basic tests setup (dotansimha#701) * test: basic tests setup * test: use fastif inject * feat: testing util to simplify setup (dotansimha#703) * Bump GraphQL Helix and use fastify's way to handle response (dotansimha#705) * feat: remove uploads option * Use File interface in resolvers, Blob as scalar name and Response as a return type of inject * chore: downgrade versions will have changeset manage this * ci: setup releases with changesets Co-authored-by: Arda TANRIKULU <[email protected]> Co-authored-by: Dotan Simha <[email protected]> Co-authored-by: Laurin Quast <[email protected]> Co-authored-by: Saihajpreet Singh <[email protected]>
- Loading branch information
1 parent
61edc43
commit 6620c77
Showing
56 changed files
with
10,518 additions
and
6,268 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 |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Changesets | ||
|
||
Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works | ||
with multi-package repos, or single-package repos to help you version and publish your code. You can | ||
find the full documentation for it [in our repository](https://github.com/changesets/changesets) | ||
|
||
We have a quick list of common questions to get you started engaging with this project in | ||
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md) |
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,10 @@ | ||
{ | ||
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json", | ||
"changelog": "@changesets/cli/changelog", | ||
"commit": false, | ||
"linked": [], | ||
"access": "restricted", | ||
"baseBranch": "master", | ||
"updateInternalDependencies": "patch", | ||
"ignore": [] | ||
} |
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,10 @@ | ||
root = true | ||
|
||
[*] | ||
end_of_line = lf | ||
insert_final_newline = true | ||
|
||
[*.{js,json,yml}] | ||
charset = utf-8 | ||
indent_style = space | ||
indent_size = 2 |
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,2 @@ | ||
/.yarn/releases/** binary | ||
/.yarn/plugins/** binary |
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,60 @@ | ||
name: Canary Release | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- next | ||
|
||
jobs: | ||
publish-canary: | ||
name: Publish Canary | ||
runs-on: ubuntu-latest | ||
if: github.event.pull_request.head.repo.full_name == github.repository | ||
steps: | ||
- name: Checkout next | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Use Node | ||
uses: actions/setup-node@v2 | ||
with: | ||
node-version: '16.x' | ||
- uses: bahmutov/npm-install@v1 | ||
- name: Setup NPM credentials | ||
run: echo "//registry.npmjs.org/:_authToken=$NODE_AUTH_TOKEN" >> ~/.npmrc | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} | ||
- name: Release Canary | ||
id: canary | ||
uses: 'kamilkisiela/release-canary@master' | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
NPM_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} | ||
with: | ||
npm-token: ${{ secrets.NODE_AUTH_TOKEN }} | ||
npm-script: 'yarn release:canary' | ||
changesets: true | ||
- name: Publish a message | ||
if: steps.canary.outputs.released == 'true' | ||
uses: 'kamilkisiela/pr-comment@master' | ||
with: | ||
commentKey: canary | ||
message: | | ||
The latest changes of this PR are available as canary in npm (based on the declared `changesets`): | ||
``` | ||
${{ steps.canary.outputs.changesetsPublishedPackages}} | ||
``` | ||
bot-token: ${{ secrets.GITHUB_TOKEN }} | ||
bot: 'github-actions[bot]' | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Publish a empty message | ||
if: steps.canary.outputs.released == 'false' | ||
uses: 'kamilkisiela/pr-comment@master' | ||
with: | ||
commentKey: canary | ||
message: | | ||
The latest changes of this PR are not available as canary, since there are no linked `changesets` for this PR. | ||
bot-token: ${{ secrets.GITHUB_TOKEN }} | ||
bot: 'github-actions[bot]' | ||
github-token: ${{ secrets.GITHUB_TOKEN }} |
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,35 @@ | ||
name: Tests | ||
on: | ||
push: | ||
branches: | ||
- next | ||
pull_request: | ||
branches: | ||
- next | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [12, 16] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Use Node ${{ matrix.node-version }} | ||
uses: actions/setup-node@master | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- name: Get yarn cache | ||
id: yarn-cache | ||
run: echo "::set-output name=dir::$(yarn cache dir)" | ||
- name: Cache Yarn | ||
uses: actions/cache@v2 | ||
with: | ||
path: ${{ steps.yarn-cache.outputs.dir }} | ||
key: ${{ runner.os }}-17-yarn-${{ hashFiles('yarn.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-17-yarn- | ||
- name: Install Dependencies using Yarn | ||
run: yarn | ||
- run: yarn build | ||
- run: yarn test |
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,36 @@ | ||
name: Release | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
release: | ||
name: Release | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repo | ||
uses: actions/checkout@master | ||
with: | ||
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits | ||
fetch-depth: 0 | ||
|
||
- name: Setup Node.js 16.x | ||
uses: actions/setup-node@master | ||
with: | ||
node-version: 16.x | ||
|
||
- name: Install Dependencies | ||
run: npm install | ||
|
||
- name: Create Release Pull Request or Publish to npm | ||
id: changesets | ||
uses: changesets/action@master | ||
with: | ||
publish: npm run release | ||
commit: 'chore(release): update monorepo packages versions' | ||
title: 'Upcoming Release Changes' | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} |
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,10 @@ | ||
yarn.lock | ||
.yarn/* | ||
.pnp.* | ||
!.yarn/patches | ||
!.yarn/sdks | ||
!.yarn/versions | ||
# TODO: enable once we get the new version working | ||
examples/ | ||
**/dist/** | ||
coverage/ |
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,14 @@ | ||
{ | ||
"printWidth": 80, | ||
"singleQuote": true, | ||
"trailingComma": "all", | ||
"semi": false, | ||
"overrides": [ | ||
{ | ||
"files": ".prettierrc", | ||
"options": { | ||
"parser": "json" | ||
} | ||
} | ||
] | ||
} |
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,3 @@ | ||
{ | ||
"recommendations": ["arcanis.vscode-zipfs", "esbenp.prettier-vscode"] | ||
} |
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 @@ | ||
{ | ||
"files.autoSave": "onFocusChange", | ||
"eslint.format.enable": true, | ||
"editor.formatOnSave": true, | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"search.exclude": { | ||
"**/.yarn": true, | ||
"**/.pnp.*": true | ||
}, | ||
"prettier.prettierPath": ".yarn/sdks/prettier/index.js", | ||
"typescript.tsdk": ".yarn/sdks/typescript/lib", | ||
"typescript.enablePromptUseWorkspaceTsdk": true | ||
} |
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
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,5 @@ | ||
# This file is automatically generated by @yarnpkg/sdks. | ||
# Manual changes might be lost! | ||
|
||
integrations: | ||
- vscode |
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,20 @@ | ||
#!/usr/bin/env node | ||
|
||
const { existsSync } = require(`fs`) | ||
const { createRequire, createRequireFromPath } = require(`module`) | ||
const { resolve } = require(`path`) | ||
|
||
const relPnpApiPath = '../../../.pnp.cjs' | ||
|
||
const absPnpApiPath = resolve(__dirname, relPnpApiPath) | ||
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath) | ||
|
||
if (existsSync(absPnpApiPath)) { | ||
if (!process.versions.pnp) { | ||
// Setup the environment to be able to require prettier/index.js | ||
require(absPnpApiPath).setup() | ||
} | ||
} | ||
|
||
// Defer to the real prettier/index.js your application uses | ||
module.exports = absRequire(`prettier/index.js`) |
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,6 @@ | ||
{ | ||
"name": "prettier", | ||
"version": "2.4.1-sdk", | ||
"main": "./index.js", | ||
"type": "commonjs" | ||
} |
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,20 @@ | ||
#!/usr/bin/env node | ||
|
||
const {existsSync} = require(`fs`); | ||
const {createRequire, createRequireFromPath} = require(`module`); | ||
const {resolve} = require(`path`); | ||
|
||
const relPnpApiPath = "../../../../.pnp.cjs"; | ||
|
||
const absPnpApiPath = resolve(__dirname, relPnpApiPath); | ||
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath); | ||
|
||
if (existsSync(absPnpApiPath)) { | ||
if (!process.versions.pnp) { | ||
// Setup the environment to be able to require typescript/bin/tsc | ||
require(absPnpApiPath).setup(); | ||
} | ||
} | ||
|
||
// Defer to the real typescript/bin/tsc your application uses | ||
module.exports = absRequire(`typescript/bin/tsc`); |
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,20 @@ | ||
#!/usr/bin/env node | ||
|
||
const {existsSync} = require(`fs`); | ||
const {createRequire, createRequireFromPath} = require(`module`); | ||
const {resolve} = require(`path`); | ||
|
||
const relPnpApiPath = "../../../../.pnp.cjs"; | ||
|
||
const absPnpApiPath = resolve(__dirname, relPnpApiPath); | ||
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath); | ||
|
||
if (existsSync(absPnpApiPath)) { | ||
if (!process.versions.pnp) { | ||
// Setup the environment to be able to require typescript/bin/tsserver | ||
require(absPnpApiPath).setup(); | ||
} | ||
} | ||
|
||
// Defer to the real typescript/bin/tsserver your application uses | ||
module.exports = absRequire(`typescript/bin/tsserver`); |
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,20 @@ | ||
#!/usr/bin/env node | ||
|
||
const { existsSync } = require(`fs`) | ||
const { createRequire, createRequireFromPath } = require(`module`) | ||
const { resolve } = require(`path`) | ||
|
||
const relPnpApiPath = '../../../../.pnp.cjs' | ||
|
||
const absPnpApiPath = resolve(__dirname, relPnpApiPath) | ||
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath) | ||
|
||
if (existsSync(absPnpApiPath)) { | ||
if (!process.versions.pnp) { | ||
// Setup the environment to be able to require typescript/lib/tsc.js | ||
require(absPnpApiPath).setup() | ||
} | ||
} | ||
|
||
// Defer to the real typescript/lib/tsc.js your application uses | ||
module.exports = absRequire(`typescript/lib/tsc.js`) |
Oops, something went wrong.