The solution is simply:
We only collect "RegularFiles".
In this case we filter out directories of that returning List.
Since the regular files already includes the path (obviously), the packaging still works as expected 🚀
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.
## 📋 Pull Request Information
**Original PR:** https://github.com/apple/pkl/pull/330
**Author:** [@StefMa](https://github.com/StefMa)
**Created:** 3/17/2024
**Status:** ✅ Merged
**Merged:** 3/19/2024
**Merged by:** [@bioball](https://github.com/bioball)
**Base:** `main` ← **Head:** `package-empty-dirs`
---
### 📝 Commits (2)
- [`a0ee462`](https://github.com/apple/pkl/commit/a0ee462f59b654b1ccaf403c5132a24057734815) Do not package empty directories
- [`aea985d`](https://github.com/apple/pkl/commit/aea985df82aaba1c710bcd858756e413d684d134) Remove unused method
### 📊 Changes
**2 files changed** (+22 additions, -30 deletions)
<details>
<summary>View changed files</summary>
📝 `pkl-cli/src/test/kotlin/org/pkl/cli/CliProjectPackagerTest.kt` (+17 -13)
📝 `pkl-core/src/main/java/org/pkl/core/project/ProjectPackager.java` (+5 -17)
</details>
### 📄 Description
fixes #318
The solution is simply:
We only collect "RegularFiles".
In this case we filter out directories of that returning `List`.
Since the regular files already includes the path (obviously), the packaging still works as expected 🚀
---
<sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
📋 Pull Request Information
Original PR: https://github.com/apple/pkl/pull/330
Author: @StefMa
Created: 3/17/2024
Status: ✅ Merged
Merged: 3/19/2024
Merged by: @bioball
Base:
main← Head:package-empty-dirs📝 Commits (2)
a0ee462Do not package empty directoriesaea985dRemove unused method📊 Changes
2 files changed (+22 additions, -30 deletions)
View changed files
📝
pkl-cli/src/test/kotlin/org/pkl/cli/CliProjectPackagerTest.kt(+17 -13)📝
pkl-core/src/main/java/org/pkl/core/project/ProjectPackager.java(+5 -17)📄 Description
fixes #318
The solution is simply:
We only collect "RegularFiles".
In this case we filter out directories of that returning
List.Since the regular files already includes the path (obviously), the packaging still works as expected 🚀
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.