stigg-api-client 0.3.0 → 0.429.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3d1d05cb491e5fbc8302149a9d694cd4dd6cb8ce1d98ab0e2f64ec932308ecc3
4
- data.tar.gz: 8e71bdf8e5b4a0223f89bde227b38b3775f67eb82bb20a7cfee4c6069ef9c7c6
3
+ metadata.gz: a68fdfcb5cf2512178aa31949398bc84089f27d750b808ad4eac47e4e69dbcc1
4
+ data.tar.gz: 757c7847f534396751905638a603e645ac079538a8a07b4dcbb2827782ba20b1
5
5
  SHA512:
6
- metadata.gz: 712f2d419658e57b3224c90e6334df8a9b22ae89d498383fa14f1abf99b266b3da7d218c7f5cd7a53391bbedf6823bc0e2bb1a82c20ef3d426cb93d89b4d7533
7
- data.tar.gz: a8b50713a93f2fac5267c017534de63975c4ae60ed0b5a2d95ab00784ece8f1b96039006f64fe967e0d3b407032d4afc98149c78c09dea899dc689a2d3f2f5f3
6
+ metadata.gz: 4bda259341f564c03f2f862e163de6734af732da08e6797336cdef05409d97a4a3dd0aeb1de306fab2a949e4023f493946f5f22025e92c5f81f87b13318a9aa8
7
+ data.tar.gz: 836eb4457604b5510ee691da454059765c7bbe1bdb49d177b961b956f568442bdc0f82259509e93788b150a5d0e400db42c6ab9a2e8f39b77885d7d33315ad3f
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- stigg-api-client (0.3.0)
4
+ stigg-api-client (0.429.0)
5
5
  graphlient (~> 0.7.0)
6
6
 
7
7
  GEM
@@ -70,7 +70,9 @@ GEM
70
70
  unicode-display_width (2.3.0)
71
71
 
72
72
  PLATFORMS
73
+ arm64-darwin-22
73
74
  x86_64-darwin-21
75
+ x86_64-linux
74
76
 
75
77
  DEPENDENCIES
76
78
  bump (~> 0.10)
data/lib/stigg/client.rb CHANGED
@@ -19,7 +19,7 @@ module Stigg
19
19
  # @param [String api_url
20
20
  # @return [Client]
21
21
  def create_client(api_key, api_url = "https://api.stigg.io/graphql", request_timeout=30)
22
- schema_path = File.join(__dir__, '../../schema.json').to_s
22
+ schema_path = File.join(__dir__, 'generated/schema.json').to_s
23
23
 
24
24
  client = Graphlient::Client.new(
25
25
  api_url,
data/lib/stigg/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Stigg
4
- VERSION = "0.3.0"
4
+ VERSION = "0.429.0"
5
5
  end
data/project.json CHANGED
@@ -14,9 +14,22 @@
14
14
  "publish": {
15
15
  "executor": "@nrwl/workspace:run-commands",
16
16
  "options": {
17
- "command": "./scripts/publish.sh",
17
+ "command": "./scripts/publish.sh {args.ver}",
18
18
  "cwd": "packages/api-client-ruby"
19
19
  }
20
+ },
21
+ "test": {
22
+ "executor": "@nrwl/workspace:run-commands",
23
+ "options": {
24
+ "command": "bundle exec rake spec",
25
+ "cwd": "packages/api-client-ruby"
26
+ },
27
+ "dependsOn": [
28
+ {
29
+ "projects": "self",
30
+ "target": "generate"
31
+ }
32
+ ]
20
33
  }
21
34
  },
22
35
  "tags": []
data/scripts/generate.sh CHANGED
@@ -1,17 +1,17 @@
1
+ #!/bin/bash -e
2
+
1
3
  # stitch the operation files together
2
- cat ../api-client-schema/src/operations/fragments.graphql > operations.graphql
3
- cat ../api-client-schema/src/operations/queries.graphql >> operations.graphql
4
- cat ../api-client-schema/src/operations/mutations.graphql >> operations.graphql
5
- cat ../api-client-schema/src/operations/subscriptions.graphql >> operations.graphql
4
+ cat ../api-client-schema/src/operations/*.graphql > operations.graphql
6
5
 
7
- cp ../api-client-schema/src/generated/schema.json schema.json
6
+ mkdir -p lib/stigg/generated/
8
7
 
9
- cat <<-EOF > schema.json
10
- $(echo { \"data\": ) $(cat schema.json) $(echo })
8
+ cat <<-EOF > lib/stigg/generated/schema.json
9
+ $(echo { \"data\": ) $(cat ../api-client-schema/src/generated/schema.json) $(echo })
11
10
  EOF
12
11
 
13
12
  node scripts/generate-operations.mjs
13
+ rm operations.graphql
14
14
 
15
- rubocop -a lib/stigg/generated/operations.rb
15
+ bundle exec rubocop -a lib/stigg/generated/operations.rb
16
16
 
17
17
  printf "api-client-ruby generated!\n"
data/scripts/publish.sh CHANGED
@@ -1,7 +1,31 @@
1
- bump minor --no-commit --no-bundle
1
+ #!/bin/bash -e
2
2
 
3
- rake build
3
+ VERSION=$1
4
4
 
5
- rake release
5
+ if [ -z "$VERSION" ]; then
6
+ echo "Usage: ./scripts/publish.sh <version>"
7
+ exit 1
8
+ fi
6
9
 
7
- printf "api-client-ruby published!\n"
10
+ bundle config unset deployment
11
+
12
+ bundle exec bump set "${VERSION}" --no-commit --no-bundle
13
+ git diff
14
+
15
+ echo "Building..."
16
+ bundle exec rake build
17
+
18
+ # create a temporary commit, since it's not possible to
19
+ # release with a dirty working directory
20
+ TAG="v${VERSION}"
21
+ echo "Creating temporary commit and tag (${TAG})..."
22
+ git add .
23
+ git commit --no-verify -m "tmp commit for ruby release"
24
+ git tag "${TAG}"
25
+
26
+ echo "Releasing..."
27
+ bundle exec rake release -v || (git tag -d "${TAG}" ; git reset --soft HEAD~1 ; exit 1)
28
+ git tag -d "${TAG}"
29
+ git reset --soft HEAD~1
30
+
31
+ echo "api-client-ruby published!"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stigg-api-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.429.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stigg
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-04-02 00:00:00.000000000 Z
11
+ date: 2023-05-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: graphlient
@@ -40,11 +40,8 @@ files:
40
40
  - Rakefile
41
41
  - lib/stigg.rb
42
42
  - lib/stigg/client.rb
43
- - lib/stigg/generated/operations.rb
44
43
  - lib/stigg/version.rb
45
- - package.json
46
44
  - project.json
47
- - schema.json
48
45
  - scripts/generate-operations.mjs
49
46
  - scripts/generate.sh
50
47
  - scripts/publish.sh
@@ -54,7 +51,7 @@ licenses:
54
51
  - MIT
55
52
  metadata:
56
53
  homepage_uri: https://stigg.io
57
- post_install_message:
54
+ post_install_message:
58
55
  rdoc_options: []
59
56
  require_paths:
60
57
  - lib
@@ -69,8 +66,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
69
66
  - !ruby/object:Gem::Version
70
67
  version: '0'
71
68
  requirements: []
72
- rubygems_version: 3.2.3
73
- signing_key:
69
+ rubygems_version: 3.4.10
70
+ signing_key:
74
71
  specification_version: 4
75
72
  summary: Stigg API Client
76
73
  test_files: []