use python3 in hack

This commit is contained in:
kidddddddddddddddddddddd
2023-01-11 11:45:42 +08:00
parent ca5c522080
commit cb6a1886c0
7 changed files with 15 additions and 21 deletions

View File

@@ -1,4 +1,4 @@
#!/usr/bin/env python
#!/usr/bin/env python3
# Copyright 2015 The Kubernetes Authors.
#
@@ -14,8 +14,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from __future__ import print_function
import argparse
import datetime
import difflib
@@ -231,7 +229,7 @@ def get_regexs():
def main():
regexs = get_regexs()
refs = get_refs()
filenames = get_files(refs.keys())
filenames = get_files(list(refs.keys()))
for filename in filenames:
if not file_passes(filename, refs, regexs):

View File

@@ -1,4 +1,4 @@
#!/usr/bin/env python
#!/usr/bin/env python3
# Copyright 2016 The Kubernetes Authors.
#
@@ -48,5 +48,5 @@ class TestBoilerplate(unittest.TestCase):
sys.stdout = old_stdout
self.assertEquals(
self.assertEqual(
output, ['././fail.go', '././fail.py'])

View File

@@ -1,4 +1,4 @@
#!/usr/bin/env python
#!/usr/bin/env python3
# Copyright 2015 The Kubernetes Authors.
#

View File

@@ -1,4 +1,4 @@
#!/usr/bin/env python
#!/usr/bin/env python3
# Copyright 2015 The Kubernetes Authors.
#