PklProject.exclude doesn't respect directories #116

Closed
opened 2025-12-30 01:21:03 +01:00 by adam · 3 comments
Owner

Originally created by @StefMa on GitHub (Mar 14, 2024).

in my project I have examples/ and tests/ directory.
Obviously I want to exclude those to be packaged.
I can use the following to ignore the files of these directories:

exclude {
  "examples/**"
  "tests/**"
}

However, an empty directory examples and test is placed into the final zip.

I guess this should be avoided.
In case of an directory is empty it shouldn't be part of the final zip.

Originally created by @StefMa on GitHub (Mar 14, 2024). in my project I have `examples/` and `tests/` directory. Obviously I want to exclude those to be packaged. I can use the following to ignore **the files of these directories**: ``` exclude { "examples/**" "tests/**" } ``` However, an empty directory `examples` and `test` is placed into the final `zip`. I guess this should be avoided. In case of an directory is empty it shouldn't be part of the final `zip`.
adam closed this issue 2025-12-30 01:21:03 +01:00
Author
Owner

@bioball commented on GitHub (Mar 14, 2024):

Agree; this is an oddity of packaging right now.

@bioball commented on GitHub (Mar 14, 2024): Agree; this is an oddity of packaging right now.
Author
Owner

@StefMa commented on GitHub (Mar 14, 2024):

If you point me to the direction where to change this I could tackle this
if you want 🙃

On Thu, Mar 14, 2024, 6:39 PM Daniel Chao @.***> wrote:

Agree; this is an oddity of packaging right now.


Reply to this email directly, view it on GitHub
https://github.com/apple/pkl/issues/318#issuecomment-1997994466, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/ACOBQ6Y7KX7JHJX53ACF3LDYYHODZAVCNFSM6AAAAABEWGEVGOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSOJXHE4TINBWGY
.
You are receiving this because you authored the thread.Message ID:
@.***>

@StefMa commented on GitHub (Mar 14, 2024): If you point me to the direction where to change this I could tackle this if you want 🙃 On Thu, Mar 14, 2024, 6:39 PM Daniel Chao ***@***.***> wrote: > Agree; this is an oddity of packaging right now. > > — > Reply to this email directly, view it on GitHub > <https://github.com/apple/pkl/issues/318#issuecomment-1997994466>, or > unsubscribe > <https://github.com/notifications/unsubscribe-auth/ACOBQ6Y7KX7JHJX53ACF3LDYYHODZAVCNFSM6AAAAABEWGEVGOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSOJXHE4TINBWGY> > . > You are receiving this because you authored the thread.Message ID: > ***@***.***> >
Author
Owner

@bioball commented on GitHub (Mar 14, 2024):

Right here! 9c1ae0d683/pkl-core/src/main/java/org/pkl/core/project/ProjectPackager.java (L343)

@bioball commented on GitHub (Mar 14, 2024): Right here! https://github.com/apple/pkl/blob/9c1ae0d68392bb24040b2ae8fcc689d4c18186cd/pkl-core/src/main/java/org/pkl/core/project/ProjectPackager.java#L343
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/pkl#116