Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 0af4e806e9 | |||
| a89208769e | |||
| 4cce91d01c | |||
| 0a7ac702c0 |
@@ -1,5 +1,8 @@
|
||||
# @actions/glob Releases
|
||||
|
||||
### 0.5.1
|
||||
- When using the `excludeHiddenFiles` option, log any ignored files with `core.info()` [#2040](https://github.com/actions/toolkit/pull/2040)
|
||||
|
||||
### 0.5.0
|
||||
- Added `excludeHiddenFiles` option, which is disabled by default to preserve existing behavior [#1791: Add glob option to ignore hidden files](https://github.com/actions/toolkit/pull/1791)
|
||||
|
||||
|
||||
Generated
+2
-2
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@actions/glob",
|
||||
"version": "0.5.0",
|
||||
"version": "0.5.1",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"description": "Actions glob lib",
|
||||
@@ -21,7 +21,7 @@
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "@actions/glob",
|
||||
"version": "0.5.0",
|
||||
"version": "0.5.1",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@actions/core": "^1.9.1",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@actions/glob",
|
||||
"version": "0.5.0",
|
||||
"version": "0.5.1",
|
||||
"preview": true,
|
||||
"description": "Actions glob lib",
|
||||
"keywords": [
|
||||
|
||||
@@ -104,6 +104,7 @@ export class DefaultGlobber implements Globber {
|
||||
|
||||
// Search
|
||||
const traversalChain: string[] = [] // used to detect cycles
|
||||
let loggedFirstHiddenMessage = false // if printing hidden, is this the first one
|
||||
while (stack.length) {
|
||||
// Pop
|
||||
const item = stack.pop() as SearchState
|
||||
@@ -130,6 +131,11 @@ export class DefaultGlobber implements Globber {
|
||||
|
||||
// Hidden file or directory?
|
||||
if (options.excludeHiddenFiles && path.basename(item.path).match(/^\./)) {
|
||||
if (!loggedFirstHiddenMessage) {
|
||||
core.info(`Ignoring the following hidden files and directories`)
|
||||
loggedFirstHiddenMessage = true
|
||||
}
|
||||
core.info(`- ${item.path}`)
|
||||
continue
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user