Skip to content

Commit 796f745

Browse files
authored
Merge pull request googleapis#2428 from dhermes/make-dns-subpackage
Move dns code into a subpackage
2 parents 79a5a78 + d7ccea6 commit 796f745

23 files changed

+209
-0
lines changed

.travis.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ script:
1313
- (cd bigquery && tox -e py27)
1414
- (cd pubsub && tox -e py27)
1515
- (cd logging && tox -e py27)
16+
- (cd dns && tox -e py27)
1617
- tox -e py34
1718
- (cd core && tox -e py34)
1819
- (cd bigtable && tox -e py34)
@@ -21,6 +22,7 @@ script:
2122
- (cd bigquery && tox -e py34)
2223
- (cd pubsub && tox -e py34)
2324
- (cd logging && tox -e py34)
25+
- (cd dns && tox -e py34)
2426
- tox -e lint
2527
- tox -e cover
2628
- (cd core && tox -e cover)
@@ -30,6 +32,7 @@ script:
3032
- (cd bigquery && tox -e cover)
3133
- (cd pubsub && tox -e cover)
3234
- (cd logging && tox -e cover)
35+
- (cd dns && tox -e cover)
3336
- tox -e system-tests
3437
- tox -e system-tests3
3538
- scripts/update_docs.sh

dns/.coveragerc

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
[run]
2+
branch = True
3+
4+
[report]
5+
fail_under = 100
6+
show_missing = True
7+
exclude_lines =
8+
# Re-enable the standard pragma
9+
pragma: NO COVER
10+
# Ignore debug-only repr
11+
def __repr__

dns/MANIFEST.in

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
include README.rst
2+
graft google
3+
graft unit_tests
4+
global-exclude *.pyc

dns/README.rst

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
Python Client for Google Cloud DNS
2+
==================================
3+
4+
Python idiomatic client for `Google Cloud DNS`_
5+
6+
.. _Google Cloud DNS: https://cloud.google.com/dns/
7+
8+
- `Homepage`_
9+
- `API Documentation`_
10+
11+
.. _Homepage: https://googlecloudplatform.github.io/google-cloud-python/
12+
.. _API Documentation: http://googlecloudplatform.github.io/google-cloud-python/
13+
14+
Quick Start
15+
-----------
16+
17+
::
18+
19+
$ pip install --upgrade google-cloud-dns
20+
21+
Authentication
22+
--------------
23+
24+
With ``google-cloud-python`` we try to make authentication as painless as
25+
possible. Check out the `Authentication section`_ in our documentation to
26+
learn more. You may also find the `authentication document`_ shared by all
27+
the ``google-cloud-*`` libraries to be helpful.
28+
29+
.. _Authentication section: http://google-cloud-python.readthedocs.io/en/latest/google-cloud-auth.html
30+
.. _authentication document: https://github.com/GoogleCloudPlatform/gcloud-common/tree/master/authentication
31+
32+
Using the API
33+
-------------
34+
35+
The Cloud `DNS`_ API (`DNS API docs`_) provides methods that you can use to
36+
manage DNS for your applications.
37+
38+
.. _DNS: https://cloud.google.com/dns/
39+
.. _DNS API docs: https://cloud.google.com/dns/docs/apis
40+
41+
See the ``google-cloud-python`` API `DNS documentation`_ to learn
42+
how to manage DNS records using this Client Library.
43+
44+
.. _DNS documentation: https://google-cloud-python.readthedocs.io/en/stable/dns-usage.html

dns/google/__init__.py

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Copyright 2016 Google Inc.
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
try:
16+
import pkg_resources
17+
pkg_resources.declare_namespace(__name__)
18+
except ImportError:
19+
import pkgutil
20+
__path__ = pkgutil.extend_path(__path__, __name__)

dns/google/cloud/__init__.py

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Copyright 2014 Google Inc.
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
try:
16+
import pkg_resources
17+
pkg_resources.declare_namespace(__name__)
18+
except ImportError:
19+
import pkgutil
20+
__path__ = pkgutil.extend_path(__path__, __name__)

0 commit comments

Comments
 (0)