Currently I have a properties file(test.properties) it has all the key pair values, Is there any way that i can add these values to $GITHUB_ENV ??
test.properties ->
- username1=user1
- username2=user2
I haven't added anything in the workflow yet just want to echo all the properties from the proeperties file..
A naïve approach would be iterating over the content of your
.properties
file line-by-line and setting them as environment variables:The bash line that reads the file line-by-line is taken from this answer.
Please note that this example will only work if you have a
.properties
file with no comments and contains onlykey=value
pairs