amoghrajesh commented on code in PR #51329:
URL: https://github.com/apache/airflow/pull/51329#discussion_r2127993930


##########
.pre-commit-config.yaml:
##########
@@ -178,6 +178,7 @@ repos:
       - id: insert-license
         name: Add license for all Go files
         types: [go]
+        exclude: mocks/.*\.go$

Review Comment:
   Hmm, wouldn't we need license for "all" files? The precommit will add it, so 
we needn't be too worries about it



##########
.pre-commit-config.yaml:
##########
@@ -1266,6 +1267,14 @@ repos:
         files:
           
^airflow-ctl/src/airflowctl/api/operations.py|airflow-ctl/src/airflowctl/cli/.*\.py$
         additional_dependencies: ['rich>=12.4.4']
+      - id: mockery
+        name: Generate mocks for go
+        entry: --entrypoint ./scripts/in_container/run_mockery.sh 
vektra/mockery:3

Review Comment:
   Did you try doing something like:
   ```
   - id: go-mockery
     name: Generate mocks for Go
     language: docker_image
     entry: sh -c "cd go-sdk && mockery"
     types: [go]
     files: ^go-sdk/
     exclude: mocks/.*\.go$
     pass_filenames: false
     additional_dependencies: [vektra/mockery:3]
   ```



##########
.pre-commit-config.yaml:
##########
@@ -1266,6 +1267,14 @@ repos:
         files:
           
^airflow-ctl/src/airflowctl/api/operations.py|airflow-ctl/src/airflowctl/cli/.*\.py$
         additional_dependencies: ['rich>=12.4.4']
+      - id: mockery
+        name: Generate mocks for go
+        entry: --entrypoint ./scripts/in_container/run_mockery.sh 
vektra/mockery:3

Review Comment:
   Another qn is, do we not need to supply the mockery.yml to the command? (not 
sure)



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to