Commit 9207941
authored
Selectively Clearing Cache Folders (#1268)
This pull request enhances the `clear-cache` command in the HoloHub CLI
by introducing new flags to allow users to selectively clear specific
types of cache folders. The changes improve usability and maintain
backward compatibility with previous behavior.
**CLI Feature Enhancements:**
* Added `--build`, `--data`, and `--install` flags to the `clear-cache`
command, allowing users to clear only build, data, or install folders,
respectively.
[[1]](diffhunk://#diff-9c212b6b2b7ad0d4afe9fc076b7d9988417d1b6f1c99de4bbb4e445798e55e4dR436-R440)
[[2]](diffhunk://#diff-1ef9cb2fbb55a15400848086c55046b4c552ea60d34e315fd638a0ca0c5396bbR124-R126)
**Implementation Details:**
* Updated the `handle_clear_cache` method in `holohub.py` to process the
new flags, collecting only the relevant directories based on user input.
If no flags are provided, all cache folders are cleared to maintain
backward compatibility.
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
* **New Features**
* The clear-cache command now supports selective cache clearing with
three new options: `--build`, `--data`, and `--install`. Each option
restricts cache clearing to the corresponding folder type. When no
option is specified, all cache categories are cleared, maintaining
backward compatibility with existing workflows.
<sub>✏️ Tip: You can customize this high-level summary in your review
settings.</sub>
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Signed-off-by: B Hashemian <[email protected]>1 parent 0a4df14 commit 9207941
2 files changed
+65
-20
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
207 | 207 | | |
208 | 208 | | |
209 | 209 | | |
210 | | - | |
| 210 | + | |
| 211 | + | |
211 | 212 | | |
212 | | - | |
213 | | - | |
214 | | - | |
| 213 | + | |
215 | 214 | | |
216 | | - | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
217 | 218 | | |
218 | | - | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
219 | 223 | | |
220 | | - | |
221 | | - | |
222 | | - | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
223 | 231 | | |
224 | | - | |
225 | | - | |
226 | | - | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
227 | 240 | | |
228 | 241 | | |
229 | 242 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
436 | 436 | | |
437 | 437 | | |
438 | 438 | | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
439 | 444 | | |
440 | 445 | | |
441 | 446 | | |
| |||
2038 | 2043 | | |
2039 | 2044 | | |
2040 | 2045 | | |
| 2046 | + | |
| 2047 | + | |
| 2048 | + | |
| 2049 | + | |
| 2050 | + | |
| 2051 | + | |
| 2052 | + | |
| 2053 | + | |
| 2054 | + | |
| 2055 | + | |
| 2056 | + | |
2041 | 2057 | | |
2042 | 2058 | | |
| 2059 | + | |
| 2060 | + | |
| 2061 | + | |
| 2062 | + | |
| 2063 | + | |
| 2064 | + | |
| 2065 | + | |
| 2066 | + | |
2043 | 2067 | | |
2044 | 2068 | | |
2045 | 2069 | | |
2046 | 2070 | | |
2047 | 2071 | | |
2048 | | - | |
2049 | | - | |
2050 | | - | |
2051 | | - | |
2052 | | - | |
2053 | | - | |
2054 | | - | |
2055 | | - | |
| 2072 | + | |
| 2073 | + | |
| 2074 | + | |
| 2075 | + | |
| 2076 | + | |
| 2077 | + | |
| 2078 | + | |
| 2079 | + | |
| 2080 | + | |
| 2081 | + | |
| 2082 | + | |
| 2083 | + | |
| 2084 | + | |
| 2085 | + | |
| 2086 | + | |
| 2087 | + | |
2056 | 2088 | | |
2057 | 2089 | | |
2058 | 2090 | | |
| |||
0 commit comments