Skip to content

Commit f45e0a6

Browse files
authored
Avoid replacing/scribbling on 'setup.py' during synth. (#6125)
Closes #6123.
1 parent a136da8 commit f45e0a6

File tree

1 file changed

+7
-10
lines changed

1 file changed

+7
-10
lines changed

packages/google-cloud-dlp/synth.py

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -23,20 +23,17 @@
2323
gapic = gcp.GAPICGenerator()
2424
common = gcp.CommonTemplates()
2525

26-
client_library_version = "0.7.0"
27-
2826
library = gapic.py_library(
2927
"dlp", "v2", config_path="/google/privacy/dlp/artman_dlp_v2.yaml"
3028
)
3129

32-
s.copy(library, excludes=["README.rst", "nox.py", "docs/index.rst"])
33-
34-
# Set Release Status
35-
release_status = "Development Status :: 3 - Alpha"
36-
s.replace("setup.py", "(release_status = )(.*)$", f"\\1'{release_status}'")
37-
38-
# Set version
39-
s.replace("setup.py", "version = .*", f"version = '{client_library_version}'")
30+
excludes = [
31+
"README.rst",
32+
"nox.py",
33+
"setup.py",
34+
"docs/index.rst",
35+
]
36+
s.copy(library, excludes=excludes)
4037

4138
# Fix namespace
4239
s.replace(

0 commit comments

Comments
 (0)