Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Use actions/checkout for submodules #973

Merged
merged 1 commit into from
Feb 8, 2023
Merged

Conversation

abhinav
Copy link
Contributor

@abhinav abhinav commented Feb 8, 2023

Our workflows have a manual step to download submodules
for the repository.

This has started failing for new PRs with an error like the following:

fatal: detected dubious ownership in repository at '/__w/pulumi-java/pulumi-java'
To add an exception for this directory, call:

	git config --global --add safe.directory /__w/pulumi-java/pulumi-java

Although this can be fixed by marking the directory safe,
it's entirely unnecessary because the actions/checkout GitHub Action
supports checkout out submodules natively.

This removes all git submodule update --init --recursive steps,
opting into actions/checkout's submodules functionality instead.

Our workflows have a manual step to download submodules
for the repository.

This has started failing for new PRs with an error like the following:

```
fatal: detected dubious ownership in repository at '/__w/pulumi-java/pulumi-java'
To add an exception for this directory, call:

	git config --global --add safe.directory /__w/pulumi-java/pulumi-java
```

Although this can be fixed by marking the directory safe,
it's entirely unnecessary because the actions/checkout GitHub Action
supports checkout out submodules natively.

This removes all `git submodule update --init --recursive` steps,
opting into actions/checkout's submodules functionality instead.
@abhinav abhinav added the impact/no-changelog-required This issue doesn't require a CHANGELOG update label Feb 8, 2023
@abhinav
Copy link
Contributor Author

abhinav commented Feb 8, 2023

Example failure: #972

@Frassle Frassle merged commit a6836b3 into main Feb 8, 2023
@Frassle Frassle deleted the abhinav/submodules branch February 8, 2023 08:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
impact/no-changelog-required This issue doesn't require a CHANGELOG update
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants