Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: remove new lines from inputs #272

Merged
merged 1 commit into from
Oct 20, 2022
Merged

Conversation

btkostner
Copy link
Contributor

This removes new lines from inputs. Some actions, like actions/cache take inputs via new line strings. When generating documentation for these, the new line wasn't removed causing table issues.

Before:

| parameter | description | required | default |
| - | - | - | - |
| cache-path | A list of files, directories, and wildcard patterns to cache and restore. By default this will cache the build and deps folder allowing for faster rebuilding. | `false` | _build
deps
 |
| cache-name | (Optional) The name of the cache. This is used to build the full cache key. By default this uses the job name which should suffice is most scenarios. If you have a custom naming scheme or want to share caches between different actions you can set it here. The reason we set this differently for each job is because tools will have different compile settings, like credo and dialyzer, and therefor have different files cached. | `false` | ${{ github.job }} |

After:

| parameter | description | required | default |
| - | - | - | - |
| cache-path | A list of files, directories, and wildcard patterns to cache and restore. By default this will cache the build and deps folder allowing for faster rebuilding. | `false` | _build deps  |
| cache-name | (Optional) The name of the cache. This is used to build the full cache key. By default this uses the job name which should suffice is most scenarios. If you have a custom naming scheme or want to share caches between different actions you can set it here. The reason we set this differently for each job is because tools will have different compile settings, like credo and dialyzer, and therefor have different files cached. | 

@btkostner
Copy link
Contributor Author

btkostner commented Sep 12, 2022

Btw, I tried to update the tests but was getting a huge amount of issues. Is there any reason you are manually using readFileSync with expect? I would imagine using Jest snapshots would be much easier.

@npalm npalm self-requested a review September 14, 2022 09:11
@npalm
Copy link
Owner

npalm commented Oct 20, 2022

Sorry for the late response, no explicit reason for not using snapshot. Feel free te improve.

@npalm
Copy link
Owner

npalm commented Oct 20, 2022

@btkostner thanks for your contribution Would you have time to work out an example with snapshot tests?

@npalm npalm merged commit dbdbd50 into npalm:main Oct 20, 2022
semantic-releaser bot pushed a commit that referenced this pull request Oct 20, 2022
## [1.1.0](1.0.4...1.1.0) (2022-10-20)

### Features

* trim output text ([#271](#271)) ([411256a](411256a))

### Bug Fixes

* remove new lines from inputs ([#272](#272)) ([dbdbd50](dbdbd50))
* Update test for trim [#271](#271) ([#297](#297)) ([6746b95](6746b95))
* Upgrade dependcies ([#296](#296)) ([b2a0a32](b2a0a32))
@semantic-releaser
Copy link
Contributor

🎉 This PR is included in version 1.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants