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

improvement: Simplify checks #570

Merged
merged 3 commits into from Aug 15, 2022
Merged

improvement: Simplify checks #570

merged 3 commits into from Aug 15, 2022

Conversation

thyarles
Copy link
Contributor

Just pointing that the && and || on bash are not equivalent to the if ... then ... else, as you can get more details here.

You can simplify the way to save the exit_status from this

COMMAND && exit_status=$? || exit_status=$?

to this

COMMAND ; exit_status=$?

Thanks!

Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for implementing a fix, could you ensure that the test covers your changes.

@thyarles thyarles changed the title Suggestion: Simplify checks improvement: Simplify checks Aug 13, 2022
@thyarles
Copy link
Contributor Author

Hi @jackton1!

Since last week GitHub started offering a way to clone only the main branch by default. Do you think this could be the reason the test failed?

Thank you!

@jackton1
Copy link
Member

@thyarles Yes I believe that’s the problem.

@jackton1
Copy link
Member

@all-contributors please add @thyarles for code.

@allcontributors
Copy link
Contributor

@jackton1

I've put up a pull request to add @thyarles! 🎉

@jackton1 jackton1 merged commit f834a93 into tj-actions:main Aug 15, 2022
@thyarles
Copy link
Contributor Author

thyarles commented Aug 15, 2022

Hi @jackton1,

Thanks for accepting my PR. I have more few improvisations on the bash. Should I do it and suggest as well?

@jacktony1
Copy link
Contributor

Hi @thyarles, Sure you can create a new Pull Request and I'll be happy to review it.

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

Successfully merging this pull request may close these issues.

None yet

3 participants