Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: tj-actions/auto-doc
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v2.5.0
Choose a base ref
...
head repository: tj-actions/auto-doc
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v2.5.1
Choose a head ref
  • 3 commits
  • 6 files changed
  • 3 contributors

Commits on May 4, 2023

  1. Merge pull request #471 from tj-actions/upgrade-to-v2.5.0

    Upgraded to v2.5.0
    repo-ranger[bot] authored May 4, 2023
    Copy the full SHA
    34c0c4c View commit details
  2. chore: skip fields that are within the limit (#472)

    Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
    jackton1 and github-actions[bot] authored May 4, 2023
    Copy the full SHA
    45a609f View commit details
  3. Copy the full SHA
    7872d2f View commit details
Showing with 189 additions and 180 deletions.
  1. +15 −6 HISTORY.md
  2. +14 −14 README.md
  3. +2 −2 internal/utils/word_wrap.go
  4. +51 −51 test/README-inputColumns.md
  5. +28 −28 test/README-outputColumns.md
  6. +79 −79 test/README.md
21 changes: 15 additions & 6 deletions HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,21 @@
# Changelog

## [v2.5.1](https://github.com/tj-actions/auto-doc/tree/v2.5.1) (2023-05-04)

[Full Changelog](https://github.com/tj-actions/auto-doc/compare/v2.5.0...v2.5.1)

**Merged pull requests:**

- chore: skip fields that are within the limit [\#472](https://github.com/tj-actions/auto-doc/pull/472) ([jackton1](https://github.com/jackton1))
- Upgraded to v2.5.0 [\#471](https://github.com/tj-actions/auto-doc/pull/471) ([jackton1](https://github.com/jackton1))

## [v2.5.0](https://github.com/tj-actions/auto-doc/tree/v2.5.0) (2023-05-04)

[Full Changelog](https://github.com/tj-actions/auto-doc/compare/v2.4.0...v2.5.0)
[Full Changelog](https://github.com/tj-actions/auto-doc/compare/v2...v2.5.0)

## [v2](https://github.com/tj-actions/auto-doc/tree/v2) (2023-05-04)

[Full Changelog](https://github.com/tj-actions/auto-doc/compare/v2.4.0...v2)

**Closed issues:**

@@ -18,11 +31,7 @@

## [v2.4.0](https://github.com/tj-actions/auto-doc/tree/v2.4.0) (2023-04-30)

[Full Changelog](https://github.com/tj-actions/auto-doc/compare/v2...v2.4.0)

## [v2](https://github.com/tj-actions/auto-doc/tree/v2) (2023-04-30)

[Full Changelog](https://github.com/tj-actions/auto-doc/compare/v2.3.2...v2)
[Full Changelog](https://github.com/tj-actions/auto-doc/compare/v2.3.2...v2.4.0)

**Merged pull requests:**

28 changes: 14 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -60,20 +60,20 @@ Add the `Inputs` and/or `Outputs` and/or `Secrets` (only supported by reusable w
<!-- AUTO-DOC-INPUT:START - Do not remove or modify this section -->
| 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<br>in a column |
| filename | string | false | `"action.yml"` | Path to the yaml file |
| input\_columns | string | false | | List of action.yml **input** columns names<br>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<br>to display, default (display all columns) |
| reusable | string | false | | Boolean Indicating whether the file is<br>a reusable workflow |
| reusable\_input\_columns | string | false | | List of reusable workflow **input** column<br>names to display, default (display all columns) |
| reusable\_output\_columns | string | false | | List of reusable workflow **output** column<br>names to display, default (display all columns) |
| reusable\_secret\_columns | string | false | | List of reusable workflow **secret** column<br>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 <br>in a column |
| filename | string | false | `"action.yml"` | Path to the yaml file |
| input\_columns | string | false | | List of action.yml **input** columns names <br>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 <br>to display, default (display all columns) |
| reusable | string | false | | Boolean Indicating whether the file is <br>a reusable workflow |
| reusable\_input\_columns | string | false | | List of reusable workflow **input** column <br>names to display, default (display all columns) |
| reusable\_output\_columns | string | false | | List of reusable workflow **output** column <br>names to display, default (display all columns) |
| reusable\_secret\_columns | string | false | | List of reusable workflow **secret** column <br>names to display, default (display all columns) |
| version | string | false | | The version number to run |
<!-- AUTO-DOC-INPUT:END -->
4 changes: 2 additions & 2 deletions internal/utils/word_wrap.go
Original file line number Diff line number Diff line change
@@ -24,7 +24,7 @@ import (

// WordWrap wraps text at the specified number of columns
func WordWrap(s string, limit int) string {
if strings.TrimSpace(s) == "" {
if strings.TrimSpace(s) == "" || len(strings.Fields(s)) <= limit {
return s
}

@@ -53,7 +53,7 @@ func WordWrap(s string, limit int) string {
limit = len(strSlice)
}

result = result + strings.Join(strSlice[:limit], " ") + "<br>"
result = result + strings.Join(strSlice[:limit], " ") + " <br>"

// discard the elements that were copied over to result
strSlice = strSlice[limit:]
Loading