mirror of
https://github.com/nektos/act.git
synced 2026-04-26 09:25:54 +03:00
[GH-ISSUE #384] Support for $GITHUB_ENV #268
Labels
No labels
area/action
area/cli
area/docs
area/image
area/runner
area/workflow
backlog
confirmed/not-planned
kind/bug
kind/discussion
kind/external
kind/feature-request
kind/question
meta/duplicate
meta/invalid
meta/need-more-info
meta/resolved
meta/wontfix
meta/workaround
needs-work
pull-request
review/not-planned
size/M
size/XL
size/XXL
stale
stale-exempt
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/act#268
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @haizaar on GitHub (Oct 7, 2020).
Original GitHub issue: https://github.com/nektos/act/issues/384
Good day,
First, thank you for writing this tool - AFAIK it's the only local simulator for any CI out there.
To the topic - GH seem to have moved to a new way to define env vars [1]:
However it doesn't seem to be supported by act. Specifying the following in the workflow file:
fails with:
Can you please support it?
[1] https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-commands-for-github-actions#setting-an-environment-variable
@haizaar commented on GitHub (Oct 7, 2020):
Using the
set-envcommand also results in a deprecation warning:@fd0 commented on GitHub (Oct 11, 2020):
Thank you very much for this great tool! This issue also applies to the
add-pathcommand (e.g. viaecho ::add-path).@Jaesin commented on GitHub (Oct 22, 2020):
Another common use is writing to
$GITHUB_PATH. i.e.echo "$(composer config -g home)/vendor/bin" >> $GITHUB_PATHso the path persists in subsequent run steps.$GITHUB_PATHwould be a file that would get parsed for paths on every run command. I remember doing something like this manually with travisci a while back so it would be really nice to have this working.@Risto-Stevcev commented on GitHub (Nov 11, 2020):
Any updates on this?
@torbjornvatn commented on GitHub (Nov 11, 2020):
I've gave this a go yesterday, not completely done yet though.
I'll report back when I get it working.
@haizaar commented on GitHub (Nov 17, 2020):
set-env& friends commands are now disabled by default, i.e. warnings became errors.Now need to set
ACTIONS_ALLOW_UNSECURE_COMMANDSto make it still work.@torbjornvatn commented on GitHub (Nov 18, 2020):
@haizaar I'll see if I manage to wrap up my PR on this today
@torbjornvatn commented on GitHub (Nov 20, 2020):
I have something working now. Just have to do some clean up and testing tomorrow
@haizaar commented on GitHub (Nov 20, 2020):
@torbjornvatn If you have a build to test, let me know.
@kimtore commented on GitHub (Nov 30, 2020):
Any updates here?
@torbjornvatn commented on GitHub (Dec 1, 2020):
#426 is being reviewed by @cplee
@Sultanyaron commented on GitHub (Jan 24, 2023):
@torbjornvatn Hi, I am still getting an error when trying to set $GITHUB_ENV
Maybe you can assist here:
The error i am getting is:
Error: Error occurred running finally: Error occurred running finally: Error occurred running finally: Error occurred running finally: Error occurred running finally: Error occurred running finally: invalid format 'v0.1.0', expected a line with '=' or '<<' (original error: <nil>) (original error: <nil>) (original error: <nil>) (original error: <nil>) (original error: <nil>) (original error: <nil>)@torbjornvatn commented on GitHub (Jan 25, 2023):
Sorry @Sultanyaron, it's been so long since I looked at Act. So the implementation for this has likely changed several times since I was involved.
So I would encourage you to open a new issue and reference this one
@ChristopherHX commented on GitHub (Jan 25, 2023):
@Sultanyaron Are you writing the correct format?
The parser probably found something like this, which has a format error on line 2.
Use
cat "$GITHUB_ENV"to verify if your format is correct. Docs: https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#setting-an-environment-variable