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

**/* not only includes subdirectories #1543

Open
brussee opened this issue Apr 4, 2025 · 1 comment
Open

**/* not only includes subdirectories #1543

brussee opened this issue Apr 4, 2025 · 1 comment

Comments

@brussee
Copy link

brussee commented Apr 4, 2025

Minimal .gitlab-ci.yml illustrating the issue

---
include:
  - local: "**/*.yml"

Expected behavior
All .yml files in subdirectories only are included.

Host information
NixOS
gitlab-ci-local 4.53.0

Containerd binary
Docker version 27.3.1, build v27.3.1

Additional context
Note the difference between:

# This matches all `.yml` files in `configs` and any subfolder in it.
include: 'configs/**.yml'

# This matches all `.yml` files only in subfolders of `configs`.
include: 'configs/**/*.yml'

Source: https://docs.gitlab.com/ci/yaml/includes/#use-includelocal-with-wildcard-file-paths

@brussee
Copy link
Author

brussee commented Apr 4, 2025

Due to the described issue, the minimal example results in infinite recursion.

A workaround is to exclude .gitlab-ci.yml like: #1542

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant