diff --git a/README.md b/README.md index 6c63ba32..3cb389da 100644 --- a/README.md +++ b/README.md @@ -60,20 +60,20 @@ Add the `Inputs` and/or `Outputs` and/or `Secrets` (only supported by reusable w -| INPUT | TYPE | REQUIRED | DEFAULT | DESCRIPTION | -|-------------------------|--------|----------|----------------|----------------------------------------------------------------------------------------------------| -| bin\_path | string | false | | Path to the auto-doc binary | -| col\_max\_width | string | false | `"1000"` | Max width of a column | -| col\_max\_words | string | false | `"5"` | Max number of words per line
in a column | -| filename | string | false | `"action.yml"` | Path to the yaml file | -| input\_columns | string | false | | List of action.yml **input** columns names
to display, default (display all columns) | -| output | string | false | `"README.md"` | Path to the output file | -| output\_columns | string | false | | List of action.yml **output** column names
to display, default (display all columns) | -| reusable | string | false | | Boolean Indicating whether the file is
a reusable workflow | -| reusable\_input\_columns | string | false | | List of reusable workflow **input** column
names to display, default (display all
columns) | -| reusable\_output\_columns | string | false | | List of reusable workflow **output** column
names to display, default (display all
columns) | -| reusable\_secret\_columns | string | false | | List of reusable workflow **secret** column
names to display, default (display all
columns) | -| version | string | false | | The version number to run | +| INPUT | TYPE | REQUIRED | DEFAULT | DESCRIPTION | +|-------------------------|--------|----------|----------------|------------------------------------------------------------------------------------------------| +| bin\_path | string | false | | Path to the auto-doc binary | +| col\_max\_width | string | false | `"1000"` | Max width of a column | +| col\_max\_words | string | false | `"5"` | Max number of words per line
in a column | +| filename | string | false | `"action.yml"` | Path to the yaml file | +| input\_columns | string | false | | List of action.yml **input** columns names
to display, default (display all columns) | +| output | string | false | `"README.md"` | Path to the output file | +| output\_columns | string | false | | List of action.yml **output** column names
to display, default (display all columns) | +| reusable | string | false | | Boolean Indicating whether the file is
a reusable workflow | +| reusable\_input\_columns | string | false | | List of reusable workflow **input** column
names to display, default (display all columns) | +| reusable\_output\_columns | string | false | | List of reusable workflow **output** column
names to display, default (display all columns) | +| reusable\_secret\_columns | string | false | | List of reusable workflow **secret** column
names to display, default (display all columns) | +| version | string | false | | The version number to run | diff --git a/internal/types/action.go b/internal/types/action.go index bb46f720..e5e93c89 100644 --- a/internal/types/action.go +++ b/internal/types/action.go @@ -80,7 +80,7 @@ func (a *Action) WriteDocumentation(inputTable, outputTable *strings.Builder) er var output []byte - hasInputsData, inputStartIndexes, inputEndIndexes := utils.HasBytesInBetween( + hasInputsData, Indices := utils.HasBytesInBetween( input, []byte(internal.InputAutoDocStart), []byte(internal.InputAutoDocEnd), @@ -90,9 +90,7 @@ func (a *Action) WriteDocumentation(inputTable, outputTable *strings.Builder) er inputsStr := strings.TrimSpace(inputTable.String()) if hasInputsData { - for i := 0; i < len(inputStartIndexes); i++ { - output = utils.ReplaceBytesInBetween(output, inputStartIndexes[i], inputEndIndexes[i], []byte(inputsStr)) - } + output = utils.ReplaceBytesInBetween(output, Indices, []byte(inputsStr)) } else { re := regexp.MustCompile(fmt.Sprintf("(?m)^%s", internal.InputsHeader)) output = re.ReplaceAllFunc(input, func(match []byte) []byte { @@ -103,7 +101,7 @@ func (a *Action) WriteDocumentation(inputTable, outputTable *strings.Builder) er }) } - hasOutputsData, outputStartIndexes, outputEndIndexes := utils.HasBytesInBetween( + hasOutputsData, Indices := utils.HasBytesInBetween( output, []byte(internal.OutputAutoDocStart), []byte(internal.OutputAutoDocEnd), @@ -112,9 +110,7 @@ func (a *Action) WriteDocumentation(inputTable, outputTable *strings.Builder) er outputsStr := strings.TrimSpace(outputTable.String()) if hasOutputsData { - for i := 0; i < len(outputStartIndexes); i++ { - output = utils.ReplaceBytesInBetween(output, outputStartIndexes[i], outputEndIndexes[i], []byte(outputsStr)) - } + output = utils.ReplaceBytesInBetween(output, Indices, []byte(outputsStr)) } else { re := regexp.MustCompile(fmt.Sprintf("(?m)^%s", internal.OutputsHeader)) output = re.ReplaceAllFunc(output, func(match []byte) []byte { diff --git a/internal/types/reusable.go b/internal/types/reusable.go index d6b31653..5e8a3fda 100644 --- a/internal/types/reusable.go +++ b/internal/types/reusable.go @@ -27,9 +27,10 @@ import ( "github.com/olekukonko/tablewriter" "github.com/spf13/cobra" + "gopkg.in/yaml.v3" + "github.com/tj-actions/auto-doc/v2/internal" "github.com/tj-actions/auto-doc/v2/internal/utils" - "gopkg.in/yaml.v3" ) // ReusableInput represents the input of the reusable workflow @@ -92,7 +93,7 @@ func (r *Reusable) WriteDocumentation(inputTable, outputTable, secretsTable *str var output []byte - hasInputsData, inputStartIndexes, inputEndIndexes := utils.HasBytesInBetween( + hasInputsData, Indices := utils.HasBytesInBetween( input, []byte(internal.InputAutoDocStart), []byte(internal.InputAutoDocEnd), @@ -102,9 +103,7 @@ func (r *Reusable) WriteDocumentation(inputTable, outputTable, secretsTable *str inputsStr := strings.TrimSpace(inputTable.String()) if hasInputsData { - for i := 0; i < len(inputStartIndexes); i++ { - output = utils.ReplaceBytesInBetween(output, inputStartIndexes[i], inputEndIndexes[i], []byte(inputsStr)) - } + output = utils.ReplaceBytesInBetween(output, Indices, []byte(inputsStr)) } else { re := regexp.MustCompile(fmt.Sprintf("(?m)^%s", internal.InputsHeader)) output = re.ReplaceAllFunc(input, func(match []byte) []byte { @@ -115,7 +114,7 @@ func (r *Reusable) WriteDocumentation(inputTable, outputTable, secretsTable *str }) } - hasOutputsData, outputStartIndexes, outputEndIndexes := utils.HasBytesInBetween( + hasOutputsData, Indices := utils.HasBytesInBetween( output, []byte(internal.OutputAutoDocStart), []byte(internal.OutputAutoDocEnd), @@ -124,9 +123,7 @@ func (r *Reusable) WriteDocumentation(inputTable, outputTable, secretsTable *str outputsStr := strings.TrimSpace(outputTable.String()) if hasOutputsData { - for i := 0; i < len(outputStartIndexes); i++ { - output = utils.ReplaceBytesInBetween(output, outputStartIndexes[i], outputEndIndexes[i], []byte(outputsStr)) - } + output = utils.ReplaceBytesInBetween(output, Indices, []byte(outputsStr)) } else { re := regexp.MustCompile(fmt.Sprintf("(?m)^%s", internal.OutputsHeader)) output = re.ReplaceAllFunc(output, func(match []byte) []byte { @@ -137,7 +134,7 @@ func (r *Reusable) WriteDocumentation(inputTable, outputTable, secretsTable *str }) } - hasSecretsData, secretsStartIndexes, secretsEndIndexes := utils.HasBytesInBetween( + hasSecretsData, Indices := utils.HasBytesInBetween( output, []byte(internal.SecretsAutoDocStart), []byte(internal.SecretsAutoDocEnd), @@ -146,9 +143,7 @@ func (r *Reusable) WriteDocumentation(inputTable, outputTable, secretsTable *str secretsStr := strings.TrimSpace(secretsTable.String()) if hasSecretsData { - for i := 0; i < len(secretsStartIndexes); i++ { - output = utils.ReplaceBytesInBetween(output, secretsStartIndexes[i], secretsEndIndexes[i], []byte(secretsStr)) - } + output = utils.ReplaceBytesInBetween(output, Indices, []byte(secretsStr)) } else { re := regexp.MustCompile(fmt.Sprintf("(?m)^%s", internal.SecretsHeader)) output = re.ReplaceAllFunc(output, func(match []byte) []byte { diff --git a/internal/utils/bytes_utils.go b/internal/utils/bytes_utils.go index 48b48c4e..c5397aab 100644 --- a/internal/utils/bytes_utils.go +++ b/internal/utils/bytes_utils.go @@ -17,57 +17,34 @@ limitations under the License. package utils import ( + "fmt" "regexp" ) // HasBytesInBetween checks if a byte array has a start and end byte array and returns true if and all occurrences of start and end -func HasBytesInBetween(value, start, end []byte) (found bool, startIndexes []int, endIndexes []int) { - startRegexp := regexp.MustCompile("(?m)^" + string(start)) - endRegexp := regexp.MustCompile("(?m)^" + string(end)) +func HasBytesInBetween(value, start, end []byte) (found bool, Indices [][]int) { + // Multiline regex + findRegex := regexp.MustCompile(fmt.Sprintf(`(?s)%s(.*?)%s`, regexp.QuoteMeta(string(start)), regexp.QuoteMeta(string(end)))) + Indices = findRegex.FindAllIndex(value, -1) - // Find all start and end indexes - for i := 0; i < len(value); i++ { - startLoc := startRegexp.FindIndex(value[i:]) - endLoc := endRegexp.FindIndex(value[i:]) - if len(startLoc) > 0 && len(endLoc) > 0 { - startIndex := startLoc[0] + i - endIndex := endLoc[1] + i - - if startIndex < endIndex { - // Check if there is a closer end index between the current start and the previously found end index - for j := len(endIndexes) - 1; j >= 0; j-- { - if endIndex < endIndexes[j] && endIndexes[j] < startIndex { - // Use the closer end index instead - endIndex = endIndexes[j] - } - } - - startIndexes = append(startIndexes, startIndex) - endIndexes = append(endIndexes, endIndex) - - // Move the index to the end of the found end index - i = endIndex - 1 - } else { - // Move the index to the end of the found start index - i = startIndex - 1 - } - } + if len(Indices) == 0 { + return false, Indices } - if len(startIndexes) == 0 || len(endIndexes) == 0 { - return false, nil, nil - } - - return true, startIndexes, endIndexes + return true, Indices } -// ReplaceBytesInBetween replaces a byte array between a start and end index with a new byte array -func ReplaceBytesInBetween(value []byte, startIndex int, endIndex int, new []byte) []byte { - t := make([]byte, len(value)+len(new)) - w := 0 +// ReplaceBytesInBetween replaces a byte array between an array of start and end Indices with a new byte array +func ReplaceBytesInBetween(value []byte, indices [][]int, new []byte) []byte { + t := make([]byte, 0, len(value)+len(new)*len(indices)) + prevIndex := 0 + + for _, v := range indices { + t = append(t, value[prevIndex:v[0]]...) + t = append(t, new...) + prevIndex = v[1] + } - w += copy(t[:startIndex], value[:startIndex]) - w += copy(t[w:w+len(new)], new) - w += copy(t[w:], value[endIndex:]) - return t[0:w] + t = append(t, value[prevIndex:]...) + return t } diff --git a/internal/utils/word_wrap.go b/internal/utils/word_wrap.go index 154f1758..890e7847 100644 --- a/internal/utils/word_wrap.go +++ b/internal/utils/word_wrap.go @@ -19,54 +19,88 @@ package utils import ( "regexp" "strings" + "unicode" ) -// WordWrap wraps lengthy words with the br html tag except code blocks, links, and code +// WordWrap wraps text at the specified number of columns func WordWrap(s string, limit int) string { if strings.TrimSpace(s) == "" { return s } - // compile regular expressions for Markdown links and code blocks and code - linkRegex := regexp.MustCompile(`\[.*]\(.*\)`) - codeBlockRegex := regexp.MustCompile(`\` + "```" + `.*` + "```" + `\s*`) - // convert string to slice - strSlice := strings.Fields(s) - currentLimit := limit + var ( + linkIndices = getAllLinksIndex(s) + codeBlockIndices = getAllCodeBlocksIndex(s) + codeIndices = getAllCodeIndex(s) + parenthesisIndices = getAllParenthesisIndex(s) + italicIndices = getAllItalicIndex(s) + start = 0 + ) - var result string + // split the string into words that aren't between any of the links, code blocks, code and parenthesis + strSlice := strings.FieldsFunc(s, func(r rune) bool { + shouldExclude := isWithin(start, linkIndices) || isWithin(start, codeBlockIndices) || isWithin(start, codeIndices) || isWithin(start, parenthesisIndices) || isWithin(start, italicIndices) + start++ + return !shouldExclude && unicode.IsSpace(r) + }) + + var result = "" for len(strSlice) >= 1 { // convert slice/array back to string - // but insert
at specified limit - // unless the current slice contains a Markdown link or code block or code - hasMore := len(strSlice) > currentLimit - - if hasMore && len(result) > 0 { - result += " " + // but insert \r\n at specified limit + if len(strSlice) < limit { + limit = len(strSlice) } - if len(strSlice) < currentLimit { - currentLimit = len(strSlice) - result = result + strings.Join(strSlice[:currentLimit], " ") - } else if currentLimit == limit && !linkRegex.MatchString(strings.Join(strSlice[:currentLimit], " ")) && !codeBlockRegex.MatchString(strings.Join(strSlice[:currentLimit], " ")) { - result = result + strings.Join(strSlice[:currentLimit], " ") + "
" - } else { - result = result + strings.Join(strSlice[:currentLimit], " ") - } + result = result + strings.Join(strSlice[:limit], " ") + "
" // discard the elements that were copied over to result - strSlice = strSlice[currentLimit:] + strSlice = strSlice[limit:] + } + + // Trim the last
tag + result = strings.TrimSuffix(result, "
") - // change the limit - // to cater for the last few words in the line - if len(strSlice) < currentLimit { - currentLimit = len(strSlice) + return result +} + +func isWithin(index int, ranges [][]int) bool { + for _, r := range ranges { + if index >= r[0] && index < r[1] { + return true } } - // Remove trailing
if any - result = strings.TrimSuffix(result, "
") + return false +} + +func getAllLinksIndex(s string) [][]int { + linkRegex := regexp.MustCompile(`\[(.*?)\]\((.*?)\)`) + + return linkRegex.FindAllStringIndex(s, -1) +} + +func getAllCodeBlocksIndex(s string) [][]int { + codeBlockRegex := regexp.MustCompile("```[^`]*```") + + return codeBlockRegex.FindAllStringIndex(s, -1) +} + +func getAllCodeIndex(s string) [][]int { + codeRegex := regexp.MustCompile("`[^`]*`") + + return codeRegex.FindAllStringIndex(s, -1) +} + +func getAllParenthesisIndex(s string) [][]int { + parenthesisRegex := regexp.MustCompile(`\((.*?)\)`) + + return parenthesisRegex.FindAllStringIndex(s, -1) +} + +func getAllItalicIndex(s string) [][]int { + italicRegex := regexp.MustCompile(`\*(.*?)\*`) - return strings.TrimSpace(result) + return italicRegex.FindAllStringIndex(s, -1) } diff --git a/test/README-inputColumns.md b/test/README-inputColumns.md index 57d832b1..b5540121 100644 --- a/test/README-inputColumns.md +++ b/test/README-inputColumns.md @@ -4,34 +4,34 @@ -| INPUT | TYPE | DESCRIPTION | -|-----------------------------------|--------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| base_sha | string | Specify a different base commit SHA
used for comparing changes | -| diff_relative | string | Exclude changes outside the current directory
and show path names relative to
it. **NOTE:** This requires you to
specify the top level directory via
the `path` input. | -| dir_names | string | Output unique changed directories instead of
filenames. **NOTE:** This returns `.` for
changed files located in the root
of the project. | -| dir_names_max_depth | string | Maximum depth of directories to output.
e.g `test/test1/test2` with max depth of
`2` returns `test/test1`. | -| fetch_depth | string | Depth of additional branch history fetched.
**NOTE**: This can be adjusted to
resolve errors with insufficient history. | -| files | string | File and directory patterns to detect
changes using only these list of
file(s) (Defaults to the entire repo)
**NOTE:** Multiline file/directory patterns should not
include quotes. | -| files_from_source_file | string | Source file(s) used to populate the
`files` input. | -| files_ignore | string | Ignore changes to these file(s) **NOTE:**
Multiline file/directory patterns should not include
quotes. | -| files_ignore_from_source_file | string | Source file(s) used to populate the
`files_ignore` input | -| files_ignore_separator | string | Separator used to split the `files_ignore`
input | -| files_separator | string | Separator used to split the `files`
input | -| include_all_old_new_renamed_files | string | Include `all_old_new_renamed_files` output. Note this can
generate a large output See: [#501](https://github.com/tj-actions/changed-files/issues/501). | -| json | string | Output list of changed files in
a JSON formatted string which can
be used for matrix jobs. | -| json_raw_format | string | Output list of changed files in
a raw format which means that
the output will not be surrounded
by quotes and special characters will
not be escaped. | -| match_directories | string | Indicates whether to include match directories | -| old_new_files_separator | string | Split character for old and new
renamed filename pairs. | -| old_new_separator | string | Split character for old and new
filename pairs. | -| output_dir | string | Directory to store output files. | -| path | string | Specify a relative path under `$GITHUB_WORKSPACE`
to locate the repository. | -| quotepath | string | Use non ascii characters to match
files and output the filenames completely
verbatim by setting this to `false` | -| separator | string | Split character for output strings. | -| sha | string | Specify a different commit SHA used
for comparing changes | -| since | string | Get changed files for commits whose
timestamp is older than the given
time. | -| since_last_remote_commit | string | Use the last commit on the
remote branch as the `base_sha`. Defaults
to the last non merge commit
on the target branch for pull
request events and the previous remote
commit of the current branch for
push events. | -| until | string | Get changed files for commits whose
timestamp is earlier than the given
time. | -| write_output_files | string | Write outputs to files in the
`.github/outputs` folder by default. | +| INPUT | TYPE | DESCRIPTION | +|-----------------------------------|--------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| base_sha | string | Specify a different base commit SHA
used for comparing changes | +| diff_relative | string | Exclude changes outside the current directory
and show path names relative to
it. **NOTE:** This requires you to
specify the top level directory via
the `path` input. | +| dir_names | string | Output unique changed directories instead of
filenames. **NOTE:** This returns `.` for
changed files located in the root
of the project. | +| dir_names_max_depth | string | Maximum depth of directories to output.
e.g `test/test1/test2` with max depth of
`2` returns `test/test1`. | +| fetch_depth | string | Depth of additional branch history fetched.
**NOTE**: This can be adjusted to
resolve errors with insufficient history. | +| files | string | File and directory patterns to detect
changes using only these list of
file(s) (Defaults to the entire repo) **NOTE:** Multiline file/directory patterns
should not include quotes. | +| files_from_source_file | string | Source file(s) used to populate the
`files` input. | +| files_ignore | string | Ignore changes to these file(s) **NOTE:**
Multiline file/directory patterns should not include
quotes. | +| files_ignore_from_source_file | string | Source file(s) used to populate the
`files_ignore` input | +| files_ignore_separator | string | Separator used to split the `files_ignore`
input | +| files_separator | string | Separator used to split the `files`
input | +| include_all_old_new_renamed_files | string | Include `all_old_new_renamed_files` output. Note this can
generate a large output See: [#501](https://github.com/tj-actions/changed-files/issues/501). | +| json | string | Output list of changed files in
a JSON formatted string which can
be used for matrix jobs. | +| json_raw_format | string | Output list of changed files in
a raw format which means that
the output will not be surrounded
by quotes and special characters will
not be escaped. | +| match_directories | string | Indicates whether to include match directories | +| old_new_files_separator | string | Split character for old and new
renamed filename pairs. | +| old_new_separator | string | Split character for old and new
filename pairs. | +| output_dir | string | Directory to store output files. | +| path | string | Specify a relative path under `$GITHUB_WORKSPACE`
to locate the repository. | +| quotepath | string | Use non ascii characters to match
files and output the filenames completely
verbatim by setting this to `false` | +| separator | string | Split character for output strings. | +| sha | string | Specify a different commit SHA used
for comparing changes | +| since | string | Get changed files for commits whose
timestamp is older than the given
time. | +| since_last_remote_commit | string | Use the last commit on the
remote branch as the `base_sha`. Defaults
to the last non merge commit
on the target branch for pull
request events and the previous remote
commit of the current branch for
push events. | +| until | string | Get changed files for commits whose
timestamp is earlier than the given
time. | +| write_output_files | string | Write outputs to files in the
`.github/outputs` folder by default. | @@ -39,28 +39,28 @@ -| OUTPUT | TYPE | DESCRIPTION | -|--------------------------------|--------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| added_files | string | Returns only files that are Added
(A). | -| all_changed_and_modified_files | string | Returns all changed and modified files
i.e. *a combination of (ACMRDTUX)* | -| all_changed_files | string | Returns all changed files i.e. *a
combination of all added, copied, modified
and renamed files (ACMR)* | -| all_modified_files | string | Returns all changed files i.e. *a
combination of all added, copied, modified,
renamed and deleted files (ACMRD)*. | -| all_old_new_renamed_files | string | Returns only files that are Renamed
and list their old and new
names. **NOTE:** This requires setting `include_all_old_new_renamed_files`
to `true` (R) | -| any_changed | string | Returns `true` when any of the
filenames provided using the `files` input
has changed. If no `files` have
been specified,an empty string `''` is
returned. i.e. *using a combination of
all added, copied, modified and renamed
files (ACMR)*. | -| any_deleted | string | Returns `true` when any of the
filenames provided using the `files` input
has been deleted. If no `files`
have been specified,an empty string `''`
is returned. (D) | -| any_modified | string | Returns `true` when any of the
filenames provided using the `files` input
has been modified. If no `files`
have been specified,an empty string `''`
is returned. i.e. *using a combination
of all added, copied, modified, renamed,
and deleted files (ACMRD)*. | -| copied_files | string | Returns only files that are Copied
(C). | -| deleted_files | string | Returns only files that are Deleted
(D). | -| modified_files | string | Returns only files that are Modified
(M). | -| only_changed | string | Returns `true` when only files provided
using the `files` input has changed.
If no `files` have been specified,an
empty string `''` is returned. i.e.
*using a combination of all added,
copied, modified and renamed files (ACMR)*. | -| only_deleted | string | Returns `true` when only files provided
using the `files` input has been
deleted. If no `files` have been
specified,an empty string `''` is returned.
(D) | -| only_modified | string | Returns `true` when only files provided
using the `files` input has been
modified. If no `files` have been
specified,an empty string `''` is returned.(ACMRD). | -| other_changed_files | string | Returns all other changed files not
listed in the files input i.e.
*using a combination of all added,
copied, modified and renamed files (ACMR)*. | -| other_deleted_files | string | Returns all other deleted files not
listed in the files input i.e.
*a combination of all deleted files
(D)* | -| other_modified_files | string | Returns all other modified files not
listed in the files input i.e.
*a combination of all added, copied,
modified, and deleted files (ACMRD)* | -| renamed_files | string | Returns only files that are Renamed
(R). | -| type_changed_files | string | Returns only files that have their
file type changed (T). | -| unknown_files | string | Returns only files that are Unknown
(X). | -| unmerged_files | string | Returns only files that are Unmerged
(U). | +| OUTPUT | TYPE | DESCRIPTION | +|--------------------------------|--------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| added_files | string | Returns only files that are Added
(A). | +| all_changed_and_modified_files | string | Returns all changed and modified files
i.e. *a combination of (ACMRDTUX)* | +| all_changed_files | string | Returns all changed files i.e. *a combination of all added, copied, modified and renamed files (ACMR)* | +| all_modified_files | string | Returns all changed files i.e. *a combination of all added, copied, modified, renamed and deleted files (ACMRD)*. | +| all_old_new_renamed_files | string | Returns only files that are Renamed
and list their old and new
names. **NOTE:** This requires setting `include_all_old_new_renamed_files`
to `true` (R) | +| any_changed | string | Returns `true` when any of the
filenames provided using the `files` input
has changed. If no `files` have
been specified,an empty string `''` is
returned. i.e. *using a combination of all added, copied, modified and renamed files (ACMR)*. | +| any_deleted | string | Returns `true` when any of the
filenames provided using the `files` input
has been deleted. If no `files`
have been specified,an empty string `''`
is returned. (D) | +| any_modified | string | Returns `true` when any of the
filenames provided using the `files` input
has been modified. If no `files`
have been specified,an empty string `''`
is returned. i.e. *using a combination of all added, copied, modified, renamed, and deleted files (ACMRD)*. | +| copied_files | string | Returns only files that are Copied
(C). | +| deleted_files | string | Returns only files that are Deleted
(D). | +| modified_files | string | Returns only files that are Modified
(M). | +| only_changed | string | Returns `true` when only files provided
using the `files` input has changed.
If no `files` have been specified,an
empty string `''` is returned. i.e.
*using a combination of all added, copied, modified and renamed files (ACMR)*. | +| only_deleted | string | Returns `true` when only files provided
using the `files` input has been
deleted. If no `files` have been
specified,an empty string `''` is returned.
(D) | +| only_modified | string | Returns `true` when only files provided
using the `files` input has been
modified. If no `files` have been
specified,an empty string `''` is returned.(ACMRD). | +| other_changed_files | string | Returns all other changed files not
listed in the files input i.e.
*using a combination of all added, copied, modified and renamed files (ACMR)*. | +| other_deleted_files | string | Returns all other deleted files not
listed in the files input i.e.
*a combination of all deleted files (D)* | +| other_modified_files | string | Returns all other modified files not
listed in the files input i.e.
*a combination of all added, copied, modified, and deleted files (ACMRD)* | +| renamed_files | string | Returns only files that are Renamed
(R). | +| type_changed_files | string | Returns only files that have their
file type changed (T). | +| unknown_files | string | Returns only files that are Unknown
(X). | +| unmerged_files | string | Returns only files that are Unmerged
(U). | diff --git a/test/README-outputColumns.md b/test/README-outputColumns.md index 8f5ac271..f7735213 100644 --- a/test/README-outputColumns.md +++ b/test/README-outputColumns.md @@ -4,34 +4,34 @@ -| INPUT | TYPE | REQUIRED | DEFAULT | DESCRIPTION | -|-----------------------------------|--------|----------|---------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| base_sha | string | false | | Specify a different base commit SHA
used for comparing changes | -| diff_relative | string | false | | Exclude changes outside the current directory
and show path names relative to
it. **NOTE:** This requires you to
specify the top level directory via
the `path` input. | -| dir_names | string | false | `"false"` | Output unique changed directories instead of
filenames. **NOTE:** This returns `.` for
changed files located in the root
of the project. | -| dir_names_max_depth | string | false | | Maximum depth of directories to output.
e.g `test/test1/test2` with max depth of
`2` returns `test/test1`. | -| fetch_depth | string | false | `"50"` | Depth of additional branch history fetched.
**NOTE**: This can be adjusted to
resolve errors with insufficient history. | -| files | string | false | | File and directory patterns to detect
changes using only these list of
file(s) (Defaults to the entire repo)
**NOTE:** Multiline file/directory patterns should not
include quotes. | -| files_from_source_file | string | false | | Source file(s) used to populate the
`files` input. | -| files_ignore | string | false | | Ignore changes to these file(s) **NOTE:**
Multiline file/directory patterns should not include
quotes. | -| files_ignore_from_source_file | string | false | | Source file(s) used to populate the
`files_ignore` input | -| files_ignore_separator | string | false | `"\n"` | Separator used to split the `files_ignore`
input | -| files_separator | string | false | `"\n"` | Separator used to split the `files`
input | -| include_all_old_new_renamed_files | string | false | `"false"` | Include `all_old_new_renamed_files` output. Note this can
generate a large output See: [#501](https://github.com/tj-actions/changed-files/issues/501). | -| json | string | false | `"false"` | Output list of changed files in
a JSON formatted string which can
be used for matrix jobs. | -| json_raw_format | string | false | `"false"` | Output list of changed files in
a raw format which means that
the output will not be surrounded
by quotes and special characters will
not be escaped. | -| match_directories | string | false | `"true"` | Indicates whether to include match directories | -| old_new_files_separator | string | false | `" "` | Split character for old and new
renamed filename pairs. | -| old_new_separator | string | false | `","` | Split character for old and new
filename pairs. | -| output_dir | string | false | `".github/outputs"` | Directory to store output files. | -| path | string | false | `"."` | Specify a relative path under `$GITHUB_WORKSPACE`
to locate the repository. | -| quotepath | string | false | `"true"` | Use non ascii characters to match
files and output the filenames completely
verbatim by setting this to `false` | -| separator | string | false | `" "` | Split character for output strings. | -| sha | string | false | | Specify a different commit SHA used
for comparing changes | -| since | string | false | | Get changed files for commits whose
timestamp is older than the given
time. | -| since_last_remote_commit | string | true | `"false"` | Use the last commit on the
remote branch as the `base_sha`. Defaults
to the last non merge commit
on the target branch for pull
request events and the previous remote
commit of the current branch for
push events. | -| until | string | false | | Get changed files for commits whose
timestamp is earlier than the given
time. | -| write_output_files | string | false | `"false"` | Write outputs to files in the
`.github/outputs` folder by default. | +| INPUT | TYPE | REQUIRED | DEFAULT | DESCRIPTION | +|-----------------------------------|--------|----------|---------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| base_sha | string | false | | Specify a different base commit SHA
used for comparing changes | +| diff_relative | string | false | | Exclude changes outside the current directory
and show path names relative to
it. **NOTE:** This requires you to
specify the top level directory via
the `path` input. | +| dir_names | string | false | `"false"` | Output unique changed directories instead of
filenames. **NOTE:** This returns `.` for
changed files located in the root
of the project. | +| dir_names_max_depth | string | false | | Maximum depth of directories to output.
e.g `test/test1/test2` with max depth of
`2` returns `test/test1`. | +| fetch_depth | string | false | `"50"` | Depth of additional branch history fetched.
**NOTE**: This can be adjusted to
resolve errors with insufficient history. | +| files | string | false | | File and directory patterns to detect
changes using only these list of
file(s) (Defaults to the entire repo) **NOTE:** Multiline file/directory patterns
should not include quotes. | +| files_from_source_file | string | false | | Source file(s) used to populate the
`files` input. | +| files_ignore | string | false | | Ignore changes to these file(s) **NOTE:**
Multiline file/directory patterns should not include
quotes. | +| files_ignore_from_source_file | string | false | | Source file(s) used to populate the
`files_ignore` input | +| files_ignore_separator | string | false | `"\n"` | Separator used to split the `files_ignore`
input | +| files_separator | string | false | `"\n"` | Separator used to split the `files`
input | +| include_all_old_new_renamed_files | string | false | `"false"` | Include `all_old_new_renamed_files` output. Note this can
generate a large output See: [#501](https://github.com/tj-actions/changed-files/issues/501). | +| json | string | false | `"false"` | Output list of changed files in
a JSON formatted string which can
be used for matrix jobs. | +| json_raw_format | string | false | `"false"` | Output list of changed files in
a raw format which means that
the output will not be surrounded
by quotes and special characters will
not be escaped. | +| match_directories | string | false | `"true"` | Indicates whether to include match directories | +| old_new_files_separator | string | false | `" "` | Split character for old and new
renamed filename pairs. | +| old_new_separator | string | false | `","` | Split character for old and new
filename pairs. | +| output_dir | string | false | `".github/outputs"` | Directory to store output files. | +| path | string | false | `"."` | Specify a relative path under `$GITHUB_WORKSPACE`
to locate the repository. | +| quotepath | string | false | `"true"` | Use non ascii characters to match
files and output the filenames completely
verbatim by setting this to `false` | +| separator | string | false | `" "` | Split character for output strings. | +| sha | string | false | | Specify a different commit SHA used
for comparing changes | +| since | string | false | | Get changed files for commits whose
timestamp is older than the given
time. | +| since_last_remote_commit | string | true | `"false"` | Use the last commit on the
remote branch as the `base_sha`. Defaults
to the last non merge commit
on the target branch for pull
request events and the previous remote
commit of the current branch for
push events. | +| until | string | false | | Get changed files for commits whose
timestamp is earlier than the given
time. | +| write_output_files | string | false | `"false"` | Write outputs to files in the
`.github/outputs` folder by default. | diff --git a/test/README.md b/test/README.md index 6e290434..f8d2ca2a 100644 --- a/test/README.md +++ b/test/README.md @@ -6,34 +6,34 @@ Test text ## Inputs -| INPUT | TYPE | REQUIRED | DEFAULT | DESCRIPTION | -|-----------------------------------|--------|----------|---------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| base_sha | string | false | | Specify a different base commit SHA
used for comparing changes | -| diff_relative | string | false | | Exclude changes outside the current directory
and show path names relative to
it. **NOTE:** This requires you to
specify the top level directory via
the `path` input. | -| dir_names | string | false | `"false"` | Output unique changed directories instead of
filenames. **NOTE:** This returns `.` for
changed files located in the root
of the project. | -| dir_names_max_depth | string | false | | Maximum depth of directories to output.
e.g `test/test1/test2` with max depth of
`2` returns `test/test1`. | -| fetch_depth | string | false | `"50"` | Depth of additional branch history fetched.
**NOTE**: This can be adjusted to
resolve errors with insufficient history. | -| files | string | false | | File and directory patterns to detect
changes using only these list of
file(s) (Defaults to the entire repo)
**NOTE:** Multiline file/directory patterns should not
include quotes. | -| files_from_source_file | string | false | | Source file(s) used to populate the
`files` input. | -| files_ignore | string | false | | Ignore changes to these file(s) **NOTE:**
Multiline file/directory patterns should not include
quotes. | -| files_ignore_from_source_file | string | false | | Source file(s) used to populate the
`files_ignore` input | -| files_ignore_separator | string | false | `"\n"` | Separator used to split the `files_ignore`
input | -| files_separator | string | false | `"\n"` | Separator used to split the `files`
input | -| include_all_old_new_renamed_files | string | false | `"false"` | Include `all_old_new_renamed_files` output. Note this can
generate a large output See: [#501](https://github.com/tj-actions/changed-files/issues/501). | -| json | string | false | `"false"` | Output list of changed files in
a JSON formatted string which can
be used for matrix jobs. | -| json_raw_format | string | false | `"false"` | Output list of changed files in
a raw format which means that
the output will not be surrounded
by quotes and special characters will
not be escaped. | -| match_directories | string | false | `"true"` | Indicates whether to include match directories | -| old_new_files_separator | string | false | `" "` | Split character for old and new
renamed filename pairs. | -| old_new_separator | string | false | `","` | Split character for old and new
filename pairs. | -| output_dir | string | false | `".github/outputs"` | Directory to store output files. | -| path | string | false | `"."` | Specify a relative path under `$GITHUB_WORKSPACE`
to locate the repository. | -| quotepath | string | false | `"true"` | Use non ascii characters to match
files and output the filenames completely
verbatim by setting this to `false` | -| separator | string | false | `" "` | Split character for output strings. | -| sha | string | false | | Specify a different commit SHA used
for comparing changes | -| since | string | false | | Get changed files for commits whose
timestamp is older than the given
time. | -| since_last_remote_commit | string | true | `"false"` | Use the last commit on the
remote branch as the `base_sha`. Defaults
to the last non merge commit
on the target branch for pull
request events and the previous remote
commit of the current branch for
push events. | -| until | string | false | | Get changed files for commits whose
timestamp is earlier than the given
time. | -| write_output_files | string | false | `"false"` | Write outputs to files in the
`.github/outputs` folder by default. | +| INPUT | TYPE | REQUIRED | DEFAULT | DESCRIPTION | +|-----------------------------------|--------|----------|---------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| base_sha | string | false | | Specify a different base commit SHA
used for comparing changes | +| diff_relative | string | false | | Exclude changes outside the current directory
and show path names relative to
it. **NOTE:** This requires you to
specify the top level directory via
the `path` input. | +| dir_names | string | false | `"false"` | Output unique changed directories instead of
filenames. **NOTE:** This returns `.` for
changed files located in the root
of the project. | +| dir_names_max_depth | string | false | | Maximum depth of directories to output.
e.g `test/test1/test2` with max depth of
`2` returns `test/test1`. | +| fetch_depth | string | false | `"50"` | Depth of additional branch history fetched.
**NOTE**: This can be adjusted to
resolve errors with insufficient history. | +| files | string | false | | File and directory patterns to detect
changes using only these list of
file(s) (Defaults to the entire repo) **NOTE:** Multiline file/directory patterns
should not include quotes. | +| files_from_source_file | string | false | | Source file(s) used to populate the
`files` input. | +| files_ignore | string | false | | Ignore changes to these file(s) **NOTE:**
Multiline file/directory patterns should not include
quotes. | +| files_ignore_from_source_file | string | false | | Source file(s) used to populate the
`files_ignore` input | +| files_ignore_separator | string | false | `"\n"` | Separator used to split the `files_ignore`
input | +| files_separator | string | false | `"\n"` | Separator used to split the `files`
input | +| include_all_old_new_renamed_files | string | false | `"false"` | Include `all_old_new_renamed_files` output. Note this can
generate a large output See: [#501](https://github.com/tj-actions/changed-files/issues/501). | +| json | string | false | `"false"` | Output list of changed files in
a JSON formatted string which can
be used for matrix jobs. | +| json_raw_format | string | false | `"false"` | Output list of changed files in
a raw format which means that
the output will not be surrounded
by quotes and special characters will
not be escaped. | +| match_directories | string | false | `"true"` | Indicates whether to include match directories | +| old_new_files_separator | string | false | `" "` | Split character for old and new
renamed filename pairs. | +| old_new_separator | string | false | `","` | Split character for old and new
filename pairs. | +| output_dir | string | false | `".github/outputs"` | Directory to store output files. | +| path | string | false | `"."` | Specify a relative path under `$GITHUB_WORKSPACE`
to locate the repository. | +| quotepath | string | false | `"true"` | Use non ascii characters to match
files and output the filenames completely
verbatim by setting this to `false` | +| separator | string | false | `" "` | Split character for output strings. | +| sha | string | false | | Specify a different commit SHA used
for comparing changes | +| since | string | false | | Get changed files for commits whose
timestamp is older than the given
time. | +| since_last_remote_commit | string | true | `"false"` | Use the last commit on the
remote branch as the `base_sha`. Defaults
to the last non merge commit
on the target branch for pull
request events and the previous remote
commit of the current branch for
push events. | +| until | string | false | | Get changed files for commits whose
timestamp is earlier than the given
time. | +| write_output_files | string | false | `"false"` | Write outputs to files in the
`.github/outputs` folder by default. | @@ -41,69 +41,34 @@ Test text ## Inputs -| INPUT | TYPE | REQUIRED | DEFAULT | DESCRIPTION | -|-----------------------------------|--------|----------|---------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| base_sha | string | false | | Specify a different base commit SHA
used for comparing changes | -| diff_relative | string | false | | Exclude changes outside the current directory
and show path names relative to
it. **NOTE:** This requires you to
specify the top level directory via
the `path` input. | -| dir_names | string | false | `"false"` | Output unique changed directories instead of
filenames. **NOTE:** This returns `.` for
changed files located in the root
of the project. | -| dir_names_max_depth | string | false | | Maximum depth of directories to output.
e.g `test/test1/test2` with max depth of
`2` returns `test/test1`. | -| fetch_depth | string | false | `"50"` | Depth of additional branch history fetched.
**NOTE**: This can be adjusted to
resolve errors with insufficient history. | -| files | string | false | | File and directory patterns to detect
changes using only these list of
file(s) (Defaults to the entire repo)
**NOTE:** Multiline file/directory patterns should not
include quotes. | -| files_from_source_file | string | false | | Source file(s) used to populate the
`files` input. | -| files_ignore | string | false | | Ignore changes to these file(s) **NOTE:**
Multiline file/directory patterns should not include
quotes. | -| files_ignore_from_source_file | string | false | | Source file(s) used to populate the
`files_ignore` input | -| files_ignore_separator | string | false | `"\n"` | Separator used to split the `files_ignore`
input | -| files_separator | string | false | `"\n"` | Separator used to split the `files`
input | -| include_all_old_new_renamed_files | string | false | `"false"` | Include `all_old_new_renamed_files` output. Note this can
generate a large output See: [#501](https://github.com/tj-actions/changed-files/issues/501). | -| json | string | false | `"false"` | Output list of changed files in
a JSON formatted string which can
be used for matrix jobs. | -| json_raw_format | string | false | `"false"` | Output list of changed files in
a raw format which means that
the output will not be surrounded
by quotes and special characters will
not be escaped. | -| match_directories | string | false | `"true"` | Indicates whether to include match directories | -| old_new_files_separator | string | false | `" "` | Split character for old and new
renamed filename pairs. | -| old_new_separator | string | false | `","` | Split character for old and new
filename pairs. | -| output_dir | string | false | `".github/outputs"` | Directory to store output files. | -| path | string | false | `"."` | Specify a relative path under `$GITHUB_WORKSPACE`
to locate the repository. | -| quotepath | string | false | `"true"` | Use non ascii characters to match
files and output the filenames completely
verbatim by setting this to `false` | -| separator | string | false | `" "` | Split character for output strings. | -| sha | string | false | | Specify a different commit SHA used
for comparing changes | -| since | string | false | | Get changed files for commits whose
timestamp is older than the given
time. | -| since_last_remote_commit | string | true | `"false"` | Use the last commit on the
remote branch as the `base_sha`. Defaults
to the last non merge commit
on the target branch for pull
request events and the previous remote
commit of the current branch for
push events. | -| until | string | false | | Get changed files for commits whose
timestamp is earlier than the given
time. | -| write_output_files | string | false | `"false"` | Write outputs to files in the
`.github/outputs` folder by default. | - - - -## Inputs - - - -| INPUT | TYPE | REQUIRED | DEFAULT | DESCRIPTION | -|-----------------------------------|--------|----------|---------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| base_sha | string | false | | Specify a different base commit SHA
used for comparing changes | -| diff_relative | string | false | | Exclude changes outside the current directory
and show path names relative to
it. **NOTE:** This requires you to
specify the top level directory via
the `path` input. | -| dir_names | string | false | `"false"` | Output unique changed directories instead of
filenames. **NOTE:** This returns `.` for
changed files located in the root
of the project. | -| dir_names_max_depth | string | false | | Maximum depth of directories to output.
e.g `test/test1/test2` with max depth of
`2` returns `test/test1`. | -| fetch_depth | string | false | `"50"` | Depth of additional branch history fetched.
**NOTE**: This can be adjusted to
resolve errors with insufficient history. | -| files | string | false | | File and directory patterns to detect
changes using only these list of
file(s) (Defaults to the entire repo)
**NOTE:** Multiline file/directory patterns should not
include quotes. | -| files_from_source_file | string | false | | Source file(s) used to populate the
`files` input. | -| files_ignore | string | false | | Ignore changes to these file(s) **NOTE:**
Multiline file/directory patterns should not include
quotes. | -| files_ignore_from_source_file | string | false | | Source file(s) used to populate the
`files_ignore` input | -| files_ignore_separator | string | false | `"\n"` | Separator used to split the `files_ignore`
input | -| files_separator | string | false | `"\n"` | Separator used to split the `files`
input | -| include_all_old_new_renamed_files | string | false | `"false"` | Include `all_old_new_renamed_files` output. Note this can
generate a large output See: [#501](https://github.com/tj-actions/changed-files/issues/501). | -| json | string | false | `"false"` | Output list of changed files in
a JSON formatted string which can
be used for matrix jobs. | -| json_raw_format | string | false | `"false"` | Output list of changed files in
a raw format which means that
the output will not be surrounded
by quotes and special characters will
not be escaped. | -| match_directories | string | false | `"true"` | Indicates whether to include match directories | -| old_new_files_separator | string | false | `" "` | Split character for old and new
renamed filename pairs. | -| old_new_separator | string | false | `","` | Split character for old and new
filename pairs. | -| output_dir | string | false | `".github/outputs"` | Directory to store output files. | -| path | string | false | `"."` | Specify a relative path under `$GITHUB_WORKSPACE`
to locate the repository. | -| quotepath | string | false | `"true"` | Use non ascii characters to match
files and output the filenames completely
verbatim by setting this to `false` | -| separator | string | false | `" "` | Split character for output strings. | -| sha | string | false | | Specify a different commit SHA used
for comparing changes | -| since | string | false | | Get changed files for commits whose
timestamp is older than the given
time. | -| since_last_remote_commit | string | true | `"false"` | Use the last commit on the
remote branch as the `base_sha`. Defaults
to the last non merge commit
on the target branch for pull
request events and the previous remote
commit of the current branch for
push events. | -| until | string | false | | Get changed files for commits whose
timestamp is earlier than the given
time. | -| write_output_files | string | false | `"false"` | Write outputs to files in the
`.github/outputs` folder by default. | +| INPUT | TYPE | REQUIRED | DEFAULT | DESCRIPTION | +|-----------------------------------|--------|----------|---------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| base_sha | string | false | | Specify a different base commit SHA
used for comparing changes | +| diff_relative | string | false | | Exclude changes outside the current directory
and show path names relative to
it. **NOTE:** This requires you to
specify the top level directory via
the `path` input. | +| dir_names | string | false | `"false"` | Output unique changed directories instead of
filenames. **NOTE:** This returns `.` for
changed files located in the root
of the project. | +| dir_names_max_depth | string | false | | Maximum depth of directories to output.
e.g `test/test1/test2` with max depth of
`2` returns `test/test1`. | +| fetch_depth | string | false | `"50"` | Depth of additional branch history fetched.
**NOTE**: This can be adjusted to
resolve errors with insufficient history. | +| files | string | false | | File and directory patterns to detect
changes using only these list of
file(s) (Defaults to the entire repo) **NOTE:** Multiline file/directory patterns
should not include quotes. | +| files_from_source_file | string | false | | Source file(s) used to populate the
`files` input. | +| files_ignore | string | false | | Ignore changes to these file(s) **NOTE:**
Multiline file/directory patterns should not include
quotes. | +| files_ignore_from_source_file | string | false | | Source file(s) used to populate the
`files_ignore` input | +| files_ignore_separator | string | false | `"\n"` | Separator used to split the `files_ignore`
input | +| files_separator | string | false | `"\n"` | Separator used to split the `files`
input | +| include_all_old_new_renamed_files | string | false | `"false"` | Include `all_old_new_renamed_files` output. Note this can
generate a large output See: [#501](https://github.com/tj-actions/changed-files/issues/501). | +| json | string | false | `"false"` | Output list of changed files in
a JSON formatted string which can
be used for matrix jobs. | +| json_raw_format | string | false | `"false"` | Output list of changed files in
a raw format which means that
the output will not be surrounded
by quotes and special characters will
not be escaped. | +| match_directories | string | false | `"true"` | Indicates whether to include match directories | +| old_new_files_separator | string | false | `" "` | Split character for old and new
renamed filename pairs. | +| old_new_separator | string | false | `","` | Split character for old and new
filename pairs. | +| output_dir | string | false | `".github/outputs"` | Directory to store output files. | +| path | string | false | `"."` | Specify a relative path under `$GITHUB_WORKSPACE`
to locate the repository. | +| quotepath | string | false | `"true"` | Use non ascii characters to match
files and output the filenames completely
verbatim by setting this to `false` | +| separator | string | false | `" "` | Split character for output strings. | +| sha | string | false | | Specify a different commit SHA used
for comparing changes | +| since | string | false | | Get changed files for commits whose
timestamp is older than the given
time. | +| since_last_remote_commit | string | true | `"false"` | Use the last commit on the
remote branch as the `base_sha`. Defaults
to the last non merge commit
on the target branch for pull
request events and the previous remote
commit of the current branch for
push events. | +| until | string | false | | Get changed files for commits whose
timestamp is earlier than the given
time. | +| write_output_files | string | false | `"false"` | Write outputs to files in the
`.github/outputs` folder by default. | @@ -111,28 +76,28 @@ Test text ## Inputs -| OUTPUT | TYPE | DESCRIPTION | -|--------------------------------|--------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| added_files | string | Returns only files that are Added
(A). | -| all_changed_and_modified_files | string | Returns all changed and modified files
i.e. *a combination of (ACMRDTUX)* | -| all_changed_files | string | Returns all changed files i.e. *a
combination of all added, copied, modified
and renamed files (ACMR)* | -| all_modified_files | string | Returns all changed files i.e. *a
combination of all added, copied, modified,
renamed and deleted files (ACMRD)*. | -| all_old_new_renamed_files | string | Returns only files that are Renamed
and list their old and new
names. **NOTE:** This requires setting `include_all_old_new_renamed_files`
to `true` (R) | -| any_changed | string | Returns `true` when any of the
filenames provided using the `files` input
has changed. If no `files` have
been specified,an empty string `''` is
returned. i.e. *using a combination of
all added, copied, modified and renamed
files (ACMR)*. | -| any_deleted | string | Returns `true` when any of the
filenames provided using the `files` input
has been deleted. If no `files`
have been specified,an empty string `''`
is returned. (D) | -| any_modified | string | Returns `true` when any of the
filenames provided using the `files` input
has been modified. If no `files`
have been specified,an empty string `''`
is returned. i.e. *using a combination
of all added, copied, modified, renamed,
and deleted files (ACMRD)*. | -| copied_files | string | Returns only files that are Copied
(C). | -| deleted_files | string | Returns only files that are Deleted
(D). | -| modified_files | string | Returns only files that are Modified
(M). | -| only_changed | string | Returns `true` when only files provided
using the `files` input has changed.
If no `files` have been specified,an
empty string `''` is returned. i.e.
*using a combination of all added,
copied, modified and renamed files (ACMR)*. | -| only_deleted | string | Returns `true` when only files provided
using the `files` input has been
deleted. If no `files` have been
specified,an empty string `''` is returned.
(D) | -| only_modified | string | Returns `true` when only files provided
using the `files` input has been
modified. If no `files` have been
specified,an empty string `''` is returned.(ACMRD). | -| other_changed_files | string | Returns all other changed files not
listed in the files input i.e.
*using a combination of all added,
copied, modified and renamed files (ACMR)*. | -| other_deleted_files | string | Returns all other deleted files not
listed in the files input i.e.
*a combination of all deleted files
(D)* | -| other_modified_files | string | Returns all other modified files not
listed in the files input i.e.
*a combination of all added, copied,
modified, and deleted files (ACMRD)* | -| renamed_files | string | Returns only files that are Renamed
(R). | -| type_changed_files | string | Returns only files that have their
file type changed (T). | -| unknown_files | string | Returns only files that are Unknown
(X). | -| unmerged_files | string | Returns only files that are Unmerged
(U). | +| OUTPUT | TYPE | DESCRIPTION | +|--------------------------------|--------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| added_files | string | Returns only files that are Added
(A). | +| all_changed_and_modified_files | string | Returns all changed and modified files
i.e. *a combination of (ACMRDTUX)* | +| all_changed_files | string | Returns all changed files i.e. *a combination of all added, copied, modified and renamed files (ACMR)* | +| all_modified_files | string | Returns all changed files i.e. *a combination of all added, copied, modified, renamed and deleted files (ACMRD)*. | +| all_old_new_renamed_files | string | Returns only files that are Renamed
and list their old and new
names. **NOTE:** This requires setting `include_all_old_new_renamed_files`
to `true` (R) | +| any_changed | string | Returns `true` when any of the
filenames provided using the `files` input
has changed. If no `files` have
been specified,an empty string `''` is
returned. i.e. *using a combination of all added, copied, modified and renamed files (ACMR)*. | +| any_deleted | string | Returns `true` when any of the
filenames provided using the `files` input
has been deleted. If no `files`
have been specified,an empty string `''`
is returned. (D) | +| any_modified | string | Returns `true` when any of the
filenames provided using the `files` input
has been modified. If no `files`
have been specified,an empty string `''`
is returned. i.e. *using a combination of all added, copied, modified, renamed, and deleted files (ACMRD)*. | +| copied_files | string | Returns only files that are Copied
(C). | +| deleted_files | string | Returns only files that are Deleted
(D). | +| modified_files | string | Returns only files that are Modified
(M). | +| only_changed | string | Returns `true` when only files provided
using the `files` input has changed.
If no `files` have been specified,an
empty string `''` is returned. i.e.
*using a combination of all added, copied, modified and renamed files (ACMR)*. | +| only_deleted | string | Returns `true` when only files provided
using the `files` input has been
deleted. If no `files` have been
specified,an empty string `''` is returned.
(D) | +| only_modified | string | Returns `true` when only files provided
using the `files` input has been
modified. If no `files` have been
specified,an empty string `''` is returned.(ACMRD). | +| other_changed_files | string | Returns all other changed files not
listed in the files input i.e.
*using a combination of all added, copied, modified and renamed files (ACMR)*. | +| other_deleted_files | string | Returns all other deleted files not
listed in the files input i.e.
*a combination of all deleted files (D)* | +| other_modified_files | string | Returns all other modified files not
listed in the files input i.e.
*a combination of all added, copied, modified, and deleted files (ACMRD)* | +| renamed_files | string | Returns only files that are Renamed
(R). | +| type_changed_files | string | Returns only files that have their
file type changed (T). | +| unknown_files | string | Returns only files that are Unknown
(X). | +| unmerged_files | string | Returns only files that are Unmerged
(U). |