Open kilianc opened 1 month ago
Van you explain the use case?
My understanding of the project is still limited, but I don't get when vim could be needed.
Having context would explain to understand why to set it up, and so to understand what to set up, and sometimes how
See here: https://github.com/gha-common/go-beautiful-html-coverage/blob/main/scripts/beautify-html.sh#L18-L23
Otheriwise, like here people need to install vim if not present.
This represents a couple of challenges:
I think supporting the most popular case on github is enough and people can contribute more if needed.
Thanks ks for your explanation it's now clearer.
I'm still doubtful about the need to install vim
to use only ex
I commented the PR you linked accordingly
the reason why sed
is not the best in this case is beacause replace in place is not POSIX. https://stackoverflow.com/questions/5694228/sed-in-place-flag-that-works-both-on-mac-bsd-and-linux
I'm still unsure to understand.
The problem seems to be related to sed with macOS, but then gsed (available via gnu-sed) would help but then here is my problem.
Is there anyone using your action on a macOS image 🤔 I mean the code you pointed out was using ubuntu-latest so an image were sed -i
does in place replace
Oh you said, the GitHub action doesn't know which package manager is available, and the OS
But what about adding a shell script to launch sed this way
tmp=$(mktemp)
sed 'whatever' file > $tmp
mv $tmp file
Then no vim needed
I am ok with an alternative solution
this is helpful when gha run in containers setups running in containers