From cecb8ce45e898e15741da281e2d9dbea4b2b937e Mon Sep 17 00:00:00 2001 From: rfunix Date: Fri, 25 Jun 2021 12:03:03 -0300 Subject: [PATCH 1/2] Apply protolint codestyle in discount.proto --- challenges/pt-br/new-backend-challenge/discount.proto | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/challenges/pt-br/new-backend-challenge/discount.proto b/challenges/pt-br/new-backend-challenge/discount.proto index 274f9fb..e11c9e5 100644 --- a/challenges/pt-br/new-backend-challenge/discount.proto +++ b/challenges/pt-br/new-backend-challenge/discount.proto @@ -1,18 +1,20 @@ syntax = "proto3"; package discount; +option go_package = "/pkg/discountpb"; -// Service that return mocked discount percentage. +// Service that return mocked discount percentage service Discount { rpc GetDiscount(GetDiscountRequest) returns (GetDiscountResponse) {} } -// productID used to represent a product. Ilustrative only. +// product_id used to represent a product. Ilustrative only. message GetDiscountRequest { - int32 productID = 1; + int32 product_id = 1; } // The discount percentage is a fixed value. message GetDiscountResponse { float percentage = 1; } + From 8e9ec6bd1bef2ddfd48598a088e01c06b2691bfc Mon Sep 17 00:00:00 2001 From: rfunix Date: Fri, 25 Jun 2021 12:09:21 -0300 Subject: [PATCH 2/2] Remove go_package option --- challenges/pt-br/new-backend-challenge/discount.proto | 1 - 1 file changed, 1 deletion(-) diff --git a/challenges/pt-br/new-backend-challenge/discount.proto b/challenges/pt-br/new-backend-challenge/discount.proto index e11c9e5..35ed49c 100644 --- a/challenges/pt-br/new-backend-challenge/discount.proto +++ b/challenges/pt-br/new-backend-challenge/discount.proto @@ -1,7 +1,6 @@ syntax = "proto3"; package discount; -option go_package = "/pkg/discountpb"; // Service that return mocked discount percentage service Discount {