From 05aa003e307be103a9b9ca316f3230aeb9df5cec Mon Sep 17 00:00:00 2001 From: Brian Wigginton Date: Fri, 15 Nov 2024 16:31:43 -0600 Subject: [PATCH] fixes from pre-commit run: typos and graphql formatting (#211) pre-commit run --show-diff-on-failure --color=always --all-files --- docker/docker-compose-riverboat.yml | 2 +- pkg/objects/objects.go | 2 +- pkg/objects/options.go | 2 +- query/feature.graphql | 3 ++- query/internalpolicyhistory.graphql | 2 -- query/organizationhistory.graphql | 2 -- query/standard.graphql | 3 ++- query/usersettinghistory.graphql | 2 -- 8 files changed, 7 insertions(+), 11 deletions(-) diff --git a/docker/docker-compose-riverboat.yml b/docker/docker-compose-riverboat.yml index 19bfcd59..8d5c5c27 100644 --- a/docker/docker-compose-riverboat.yml +++ b/docker/docker-compose-riverboat.yml @@ -6,7 +6,7 @@ services: image: ghcr.io/theopenlane/riverboat:arm64-78-90832455 container_name: riverboat environment: - # this needs to use host.docker.internal since it is a seperate docker-compose file + # this needs to use host.docker.internal since it is a separate docker-compose file - RIVERBOAT_JOBQUEUE_DATABASEHOST=postgres://postgres:password@host.docker.internal:5432/jobs?sslmode=disable - RIVERBOAT_RUNMIGRATIONS=true command: diff --git a/pkg/objects/objects.go b/pkg/objects/objects.go index 84c759d7..3f9e03a6 100644 --- a/pkg/objects/objects.go +++ b/pkg/objects/objects.go @@ -140,7 +140,7 @@ type File struct { ContentType string `json:"content_type,omitempty"` // Size in bytes of the uploaded file Size int64 `json:"size,omitempty"` - // Metdata is a map of key value pairs that can be used to store additional information about the file + // Metadata is a map of key value pairs that can be used to store additional information about the file Metadata map[string]string `json:"metadata,omitempty"` // Bucket is the bucket that the file is stored in Bucket string `json:"bucket,omitempty"` diff --git a/pkg/objects/options.go b/pkg/objects/options.go index 7d68ddd9..21bf676d 100644 --- a/pkg/objects/options.go +++ b/pkg/objects/options.go @@ -95,7 +95,7 @@ func WithDownloadFileOptions(opts *DownloadFileOptions) Option { } } -func WithMetdata(mp map[string]interface{}) Option { +func WithMetadata(mp map[string]interface{}) Option { return func(o *Objects) { if o.UploadFileOptions.Metadata == nil { o.UploadFileOptions.Metadata = map[string]string{} diff --git a/query/feature.graphql b/query/feature.graphql index e99f05d2..9112787c 100644 --- a/query/feature.graphql +++ b/query/feature.graphql @@ -1,4 +1,3 @@ - mutation CreateBulkCSVFeature($input: Upload!) { createBulkCSVFeature(input: $input) { features { @@ -86,6 +85,7 @@ query GetAllFeatures { } } } + query GetFeatureByID($featureId: ID!) { feature(id: $featureId) { createdAt @@ -125,6 +125,7 @@ query GetFeatures($where: FeatureWhereInput) { } } } + mutation UpdateFeature($updateFeatureId: ID!, $input: UpdateFeatureInput!) { updateFeature(id: $updateFeatureId, input: $input) { feature { diff --git a/query/internalpolicyhistory.graphql b/query/internalpolicyhistory.graphql index f17c56d3..4fa2faa4 100644 --- a/query/internalpolicyhistory.graphql +++ b/query/internalpolicyhistory.graphql @@ -1,5 +1,3 @@ - - query GetAllInternalPolicyHistories { internalPolicyHistories { edges { diff --git a/query/organizationhistory.graphql b/query/organizationhistory.graphql index 6593d876..e34598c2 100644 --- a/query/organizationhistory.graphql +++ b/query/organizationhistory.graphql @@ -1,5 +1,3 @@ - - query GetAllOrganizationHistories { organizationHistories { edges { diff --git a/query/standard.graphql b/query/standard.graphql index 052b9aeb..4b34b265 100644 --- a/query/standard.graphql +++ b/query/standard.graphql @@ -1,4 +1,3 @@ - mutation CreateBulkCSVStandard($input: Upload!) { createBulkCSVStandard(input: $input) { standards { @@ -98,6 +97,7 @@ query GetAllStandards { } } } + query GetStandardByID($standardId: ID!) { standard(id: $standardId) { background @@ -143,6 +143,7 @@ query GetStandards($where: StandardWhereInput) { } } } + mutation UpdateStandard($updateStandardId: ID!, $input: UpdateStandardInput!) { updateStandard(id: $updateStandardId, input: $input) { standard { diff --git a/query/usersettinghistory.graphql b/query/usersettinghistory.graphql index 66928c3f..65a3249a 100644 --- a/query/usersettinghistory.graphql +++ b/query/usersettinghistory.graphql @@ -1,5 +1,3 @@ - - query GetAllUserSettingHistories { userSettingHistories { edges {