Update module name

This commit is contained in:
Andrew Scott 2022-09-01 23:43:01 -04:00
parent daff7e7cef
commit f304672317
Signed by: a
GPG key ID: 3EB62D0BBB8DB381
12 changed files with 15 additions and 15 deletions

2
go.mod
View file

@ -1,4 +1,4 @@
module codeberg.org/andcscott/OpenWeatherMap-gRPC-API module codeberg.org/andcscott/OpenWeather-gRPC-API
go 1.19 go 1.19

View file

@ -2,7 +2,7 @@ syntax = "proto3";
package weather; package weather;
option go_package = "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto"; option go_package = "codeberg.org/andcscott/OpenWeather-gRPC-API/proto";
// Sub-message for Coordinates // Sub-message for Coordinates
message Coordinates { message Coordinates {

View file

@ -2,7 +2,7 @@ syntax = "proto3";
package weather; package weather;
option go_package = "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto"; option go_package = "codeberg.org/andcscott/OpenWeather-gRPC-API/proto";
import "weather.proto"; import "weather.proto";
import "location.proto"; import "location.proto";

View file

@ -2,7 +2,7 @@ syntax = "proto3";
package weather; package weather;
option go_package = "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto"; option go_package = "codeberg.org/andcscott/OpenWeather-gRPC-API/proto";
import "location.proto"; import "location.proto";

View file

@ -7,7 +7,7 @@ import (
"log" "log"
"net/http" "net/http"
pb "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto" pb "codeberg.org/andcscott/OpenWeather-gRPC-API/proto"
) )
// Receives a gRPC request for the current forecast // Receives a gRPC request for the current forecast

View file

@ -7,7 +7,7 @@ import (
"log" "log"
"net/http" "net/http"
pb "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto" pb "codeberg.org/andcscott/OpenWeather-gRPC-API/proto"
"google.golang.org/grpc/codes" "google.golang.org/grpc/codes"
"google.golang.org/grpc/status" "google.golang.org/grpc/status"
) )

View file

@ -8,7 +8,7 @@ import (
"log" "log"
"net/http" "net/http"
pb "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto" pb "codeberg.org/andcscott/OpenWeather-gRPC-API/proto"
"google.golang.org/grpc/codes" "google.golang.org/grpc/codes"
"google.golang.org/grpc/status" "google.golang.org/grpc/status"
) )

View file

@ -7,7 +7,7 @@ import (
"os" "os"
"strconv" "strconv"
pb "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto" pb "codeberg.org/andcscott/OpenWeather-gRPC-API/proto"
"github.com/joho/godotenv" "github.com/joho/godotenv"
"google.golang.org/grpc" "google.golang.org/grpc"
) )

View file

@ -4,17 +4,17 @@ import (
"context" "context"
"log" "log"
pb "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto" pb "codeberg.org/andcscott/OpenWeather-gRPC-API/proto"
) )
func doCurrent(c pb.WeatherServiceClient) { func doCurrent(c pb.WeatherServiceClient) {
res, err := c.Current(context.Background(), &pb.RequestCurrent{ res, err := c.Current(context.Background(), &pb.RequestCurrent{
LocationType: pb.LocationType_LOCATION_TYPE_ZIP_CODE, LocationType: pb.LocationType_LOCATION_TYPE_CITY,
Units: pb.Units_UNITS_METRIC, Units: pb.Units_UNITS_METRIC,
Location: &pb.OneOfLocation{ Location: &pb.OneOfLocation{
LocationId: &pb.OneOfLocation_ZipCode{ LocationId: &pb.OneOfLocation_City{
ZipCode: "97330", City: "Corvallis",
}, },
}, },
}) })

View file

@ -4,7 +4,7 @@ import (
"context" "context"
"log" "log"
pb "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto" pb "codeberg.org/andcscott/OpenWeather-gRPC-API/proto"
) )
func doFiveDay(c pb.WeatherServiceClient) { func doFiveDay(c pb.WeatherServiceClient) {

View file

@ -4,7 +4,7 @@ import (
"context" "context"
"log" "log"
pb "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto" pb "codeberg.org/andcscott/OpenWeather-gRPC-API/proto"
) )
func doLocation(c pb.WeatherServiceClient) { func doLocation(c pb.WeatherServiceClient) {

View file

@ -3,7 +3,7 @@ package main
import ( import (
"log" "log"
pb "codeberg.org/andcscott/OpenWeatherMap-gRPC-API/proto" pb "codeberg.org/andcscott/OpenWeather-gRPC-API/proto"
"google.golang.org/grpc" "google.golang.org/grpc"
"google.golang.org/grpc/credentials/insecure" "google.golang.org/grpc/credentials/insecure"
) )