Skip to content

Commit

Permalink
Update references
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitrytrager committed Jan 17, 2022
1 parent bcaaaab commit 09c2e54
Show file tree
Hide file tree
Showing 125 changed files with 185 additions and 175 deletions.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
#### expecting it in the form of
#### /go/src/github.com/circleci/go-tool
#### /go/src/bitbucket.org/circleci/go-tool
working_directory: /go/src/github.com/kritzware/google-ads-go
working_directory: /go/src/github.com/revealbot/google-ads-go
steps:
- checkout

Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2018 kritzware
Copyright (c) 2018 revealbot

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
ADS_VERSION=v0
ADS_VERSION=v9
PROTO_ROOT_DIR=googleapis/
PROTO_SRC_DIR=/google/ads/googleads/$(ADS_VERSION)/**/*.proto
PROTO_OUT_DIR=$$GOPATH/src/github.com/kritzware/google-ads-go/
PROTO_OUT_DIR=$$GOPATH/src/github.com/revealbot/google-ads-go/
PKG_PATH=paths=source_relative
PROTOC_GO_ARGS=--go_out=plugins=grpc,$(PKG_PATH):$(PROTO_OUT_DIR)

Expand Down
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

| Google Ads API version | [`v0_7_0`](https://developers.google.com/google-ads/api/docs/release-notes#070_2019-01-30) |
|-|:-:|
| Build | [![CircleCI](https://circleci.com/gh/kritzware/google-ads-go.svg?style=shield)](https://circleci.com/gh/kritzware/google-ads-go) |
| Release | ![Release](https://img.shields.io/github/release/kritzware/google-ads-go.svg) |
| Build | [![CircleCI](https://circleci.com/gh/revealbot/google-ads-go.svg?style=shield)](https://circleci.com/gh/revealbot/google-ads-go) |
| Release | ![Release](https://img.shields.io/github/release/revealbot/google-ads-go.svg) |

## Features
- Fully matches the latest [Google Ads API Reference](https://developers.google.com/google-ads/api/reference/rpc/)
Expand All @@ -13,9 +13,9 @@
## Installation
To install, simply run:
```bash
$ go get -d github.com/kritzware/google-ads-go
$ go get -d github.com/revealbot/google-ads-go
```
Make sure your PATH includes the $GOPATH/bin directory if you want to use the [CLI utils](https://github.com/kritzware/google-ads-go#cli):
Make sure your PATH includes the $GOPATH/bin directory if you want to use the [CLI utils](https://github.com/revealbot/google-ads-go#cli):
```bash
export PATH=$PATH:$GOPATH/bin
````
Expand All @@ -27,8 +27,8 @@ package main
import (
"fmt"
"github.com/kritzware/google-ads-go/ads"
"github.com/kritzware/google-ads-go/services"
"github.com/revealbot/google-ads-go/ads"
"github.com/revealbot/google-ads-go/services"
)
func main() {
Expand Down
2 changes: 1 addition & 1 deletion ads/ads.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"encoding/json"
"io/ioutil"

"github.com/kritzware/google-ads-go/auth"
"github.com/revealbot/google-ads-go/auth"
"golang.org/x/net/context"
"golang.org/x/oauth2"
"google.golang.org/grpc"
Expand Down
2 changes: 1 addition & 1 deletion common/ad_type_infos.pb.go

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

2 changes: 1 addition & 1 deletion common/bidding.pb.go

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

2 changes: 1 addition & 1 deletion common/criteria.pb.go

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

2 changes: 1 addition & 1 deletion common/criterion_category_availability.pb.go

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

2 changes: 1 addition & 1 deletion common/frequency_cap.pb.go

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

2 changes: 1 addition & 1 deletion common/keyword_plan_common.pb.go

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

2 changes: 1 addition & 1 deletion common/metrics.pb.go

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

5 changes: 3 additions & 2 deletions common/policy.pb.go

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

2 changes: 1 addition & 1 deletion common/segments.pb.go

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

2 changes: 1 addition & 1 deletion common/tag_snippet.pb.go

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

2 changes: 1 addition & 1 deletion common/targeting_setting.pb.go

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

2 changes: 1 addition & 1 deletion common/user_lists.pb.go

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

2 changes: 1 addition & 1 deletion errors/errors.pb.go

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

10 changes: 5 additions & 5 deletions fix-package-paths.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,23 @@ PACKAGES=('common' 'enums' 'errors' 'resources' 'services')
function fix_package_path() {
FILE=$1
PACKAGE=$2
MATCH="google.golang.org\/genproto\/googleapis\/ads\/googleads\/v0\/"
REPLACE="github.com\/kritzware\/google-ads-go\/"
MATCH="google.golang.org\/genproto\/googleapis\/ads\/googleads\/v9\/"
REPLACE="github.com\/revealbot\/google-ads-go\/"
sed -i "" "s/$MATCH$PACKAGE/$REPLACE$PACKAGE/g" $FILE
}

function fix_package_name() {
FILE=$1
PACKAGE=$2
sed -i "" "s/google_ads_googleads_v0_$PACKAGE/$PACKAGE/g" $FILE
sed -i "" "s/google_ads_googleads_v9_$PACKAGE/$PACKAGE/g" $FILE
}

echo "fixing packages"
for file in ./google/ads/googleads/v0/**/*.pb.go; do
for file in ./google/ads/googleads/v9/**/*.pb.go; do
for p in "${PACKAGES[@]}"; do
fix_package_path $file $p
fix_package_name $file $p
done
done
mv ./google/ads/googleads/v0/* ./
mv ./google/ads/googleads/v9/* ./
echo "finished fixing packages"
12 changes: 6 additions & 6 deletions gen-protos.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@ PROTO_SRC_DIR=$2
PROTOC_GO_ARGS=$3

# Protos in order to compile
PROTOS_ENUMS=googleapis/google/ads/googleads/v0/enums/*.proto
PROTOS_ERRORS=googleapis/google/ads/googleads/v0/errors/*.proto
PROTOS_COMMON=googleapis/google/ads/googleads/v0/common/*.proto
PROTOS_RESOURCES=googleapis/google/ads/googleads/v0/resources/*.proto
PROTOS_SERVICES=googleapis/google/ads/googleads/v0/services/*.proto
PROTOS_ENUMS=googleapis/google/ads/googleads/v9/enums/*.proto
PROTOS_ERRORS=googleapis/google/ads/googleads/v9/errors/*.proto
PROTOS_COMMON=googleapis/google/ads/googleads/v9/common/*.proto
PROTOS_RESOURCES=googleapis/google/ads/googleads/v9/resources/*.proto
PROTOS_SERVICES=googleapis/google/ads/googleads/v9/services/*.proto

function compile_protos() {
PROTOS=$*
for file in $PROTOS; do
echo "converting proto $(basename $file)"
FOLDER_PATH=$(dirname $file)
PACKAGE=$(basename $FOLDER_PATH)
# GO_PACKAGE="\"github.com/kritzware/google-ads-go/protos/google/ads/googleads/v0/$PACKAGE\""
# GO_PACKAGE="\"github.com/revealbot/google-ads-go/protos/google/ads/googleads/v9/$PACKAGE\""
# echo "option go_package = $GO_PACKAGE;" >> $file
protoc -I=$PROTO_ROOT_DIR $PROTOC_GO_ARGS $file
done
Expand Down
4 changes: 2 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"fmt"
"os"

"github.com/kritzware/google-ads-go/ads"
"github.com/kritzware/google-ads-go/auth"
"github.com/revealbot/google-ads-go/ads"
"github.com/revealbot/google-ads-go/auth"
)

var (
Expand Down
2 changes: 1 addition & 1 deletion resources/account_budget.pb.go

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

2 changes: 1 addition & 1 deletion resources/account_budget_proposal.pb.go

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

4 changes: 2 additions & 2 deletions resources/ad.pb.go

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

4 changes: 2 additions & 2 deletions resources/ad_group.pb.go

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

4 changes: 2 additions & 2 deletions resources/ad_group_ad.pb.go

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

4 changes: 2 additions & 2 deletions resources/ad_group_bid_modifier.pb.go

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

4 changes: 2 additions & 2 deletions resources/ad_group_criterion.pb.go

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

4 changes: 2 additions & 2 deletions resources/ad_group_feed.pb.go

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

4 changes: 2 additions & 2 deletions resources/bidding_strategy.pb.go

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

2 changes: 1 addition & 1 deletion resources/billing_setup.pb.go

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

4 changes: 2 additions & 2 deletions resources/campaign.pb.go

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

2 changes: 1 addition & 1 deletion resources/campaign_bid_modifier.pb.go

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

2 changes: 1 addition & 1 deletion resources/campaign_budget.pb.go

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

Loading

0 comments on commit 09c2e54

Please sign in to comment.