Skip to content

Commit

Permalink
working version pull
Browse files Browse the repository at this point in the history
  • Loading branch information
aexol committed Aug 26, 2024
1 parent 9ffd88c commit 2793d3e
Show file tree
Hide file tree
Showing 6 changed files with 187 additions and 11 deletions.
14 changes: 10 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"eslint": "^8.23.1",
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-prettier": "^4.2.1",
"graphql-editor-cli": "^0.9.3",
"graphql-editor-cli": "^0.9.4",
"impuddle": "0.0.2",
"prettier": "^2.7.1",
"ttypescript": "^1.5.13",
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "graphql-editor-cli",
"version": "0.9.3",
"version": "0.9.4",
"description": "GraphQL -> anything. Use GraphQL as your source of truth. GraphQL Editor Official CLI.",
"main": "lib/api.js",
"author": "Artur Czemiel",
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/src/gshared/constants/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export const FAKER_DEPLOY_FILE = "faker.json";
export const ENDPOINT_CONFIGURATION_FILE = "cloudConfig.json";
export const JAMSTACK_CONFIG_FILE = "jamstack.json";

export const IS_VERSION_FILE_REGEX = /^schema-(.*)\.json$/;
export const IS_VERSION_FILE_REGEX = /^schema-(.*)\.graphql$/;

export const SLACK_JOIN = `https://discord.gg/wVcZdmd`;

Expand Down
9 changes: 5 additions & 4 deletions packages/sandbox/package.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
{
"name": "sandbox",
"private": true,
"version": "0.8.8",
"version": "0.8.9",
"description": "GraphQL -> anything. Use GraphQL as your source of truth. GraphQL Editor Official CLI.",
"author": "Artur Czemiel",
"license": "MIT",
"type": "module",
"scripts": {
"cli": "node ../cli/lib/index.js",
"cli": "npx gecli schema pull",
"integrate": "npm run cli -- gei integrate"
},
"devDependencies": {},
"dependencies": {}
"dependencies": {
"graphql-editor-cli": "^0.9.4"
}
}
169 changes: 169 additions & 0 deletions packages/sandbox/s.graphql
Original file line number Diff line number Diff line change
@@ -0,0 +1,169 @@
interface Nameable{
name: String!
}

enum SpecialSkills{
"""
Lower enemy defense -5<br>
"""
THUNDER
"""
Attack multiple Cards at once<br>
"""
RAIN
"""
50% chance to avoid any attack<br>
"""
FIRE
}

type Query{
cardById(
cardId: String
): Card
"""
Draw a card<br>
"""
drawCard: Card!
drawChangeCard: ChangeCard!
"""
list All Cards availble<br>
"""
listCards: [Card!]!
myStacks: [CardStack!]
nameables: [Nameable!]!
public: Public
}

"""
create card inputs<br>
"""
input createCard{
"""
The name of a card<br>
"""
name: String!
"""
Description of a card<br>
"""
description: String!
"""
<div>How many children the greek god had</div>
"""
Children: Int
"""
The attack power<br>
"""
Attack: Int!
"""
The defense power<br>
"""
Defense: Int!
"""
input skills
"""
skills: [SpecialSkills!]
}

"""
Stack of cards
"""
type CardStack implements Nameable{
cards: [Card!]
name: String!
}

"""
Card used in card game<br>
"""
type Card implements Nameable{
"""
The attack power<br>
"""
Attack: Int!
"""
<div>How many children the greek god had</div>
"""
Children: Int
"""
The defense power<br>
"""
Defense: Int!
"""
Attack other cards on the table , returns Cards after attack<br>
"""
attack(
"""
Attacked card/card ids<br>
"""
cardID: [String!]!
): [Card!]
"""
Put your description here
"""
cardImage: S3Object
"""
Description of a card<br>
"""
description: String!
id: ID!
image: String!
info: JSON!
"""
The name of a card<br>
"""
name: String!
skills: [SpecialSkills!]
}

type SpecialCard implements Nameable{
effect: String!
name: String!
}

type EffectCard implements Nameable{
effectSize: Float!
name: String!
}

type Mutation{
"""
add Card to Cards database<br>
"""
addCard(
card: createCard!
): Card!
}

scalar JSON

"""
Aws S3 File
"""
type S3Object{
bucket: String!
key: String!
region: String!
}

type Public{
powerups(
filter: String!
): [Powerup!]
}

type Powerup{
name: String
}

union ChangeCard = SpecialCard | EffectCard

type Subscription{
deck: [Card!]
}

schema{
query: Query
mutation: Mutation
subscription: Subscription
}

0 comments on commit 2793d3e

Please sign in to comment.