mirror of
https://github.com/nektos/act.git
synced 2026-04-26 01:15:51 +03:00
[PR #426] [MERGED] GitHub env file support #1447
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#1447
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?
📋 Pull Request Information
Original PR: https://github.com/nektos/act/pull/426
Author: @torbjornvatn
Created: 11/20/2020
Status: ✅ Merged
Merged: 1/12/2021
Merged by: @cplee
Base:
master← Head:GITHUB_ENV📝 Commits (10+)
73f8b6bUpgrade to the official golangci-lint action and fix some issues it found0432a73Update depsd003fbfRemove a shadow warning918842aInitialize the splitPattern only once60b57d6Initial attempt at supporting $GITHUB_ENV7ef8f8bNow it's actually workingd45ab89Replace golang.org/x/crypto/ssh/terminal with golang.org/x/term31f2f0cDisable the issue-228 test againe91bb03The linter is picky3fa01a9Merge upstream/master into GITHUB_ENV📊 Changes
16 files changed (+492 additions, -107 deletions)
View changed files
📝
.github/workflows/push.yml(+4 -4)📝
.github/workflows/test-expressions.yml(+1 -0)📝
.golangci.yml(+4 -1)📝
cmd/root.go(+11 -6)📝
go.mod(+24 -27)📝
go.sum(+339 -28)📝
pkg/common/draw.go(+0 -1)📝
pkg/common/git.go(+0 -1)📝
pkg/container/docker_run.go(+62 -7)📝
pkg/model/workflow.go(+3 -3)📝
pkg/runner/command.go(+3 -3)📝
pkg/runner/command_test.go(+19 -19)📝
pkg/runner/expression_test.go(+0 -1)📝
pkg/runner/logger.go(+3 -3)📝
pkg/runner/run_context.go(+18 -2)📝
pkg/runner/runner_test.go(+1 -1)📄 Description
This PR attempts to add support for the new Environment Files since the
::set-envcommand has been deprecated.I found a way to download a tar of the
envs.txtfile that I've assigned to$GITHUB_ENVfrom a previous step's container and merge the contents into the env map that is passed to the next step.It's possible that there are more elegant ways of doing this, but I couldn't find any other way of getting access to that file between steps.
UPDATE: I did an new attempt at solving this using the existing command handler, but it didn't work as the new way of setting the envs uses the >> to file syntax. That output can be generated from any command that's called within the
run:and as far as I understand that can't be intercepted in the command handler.DEPRECATION? We should probably add a warning or an error if you try to use the old and deprecated
::set-envsyntax, but I'm not sure how to best handle that @cpleeFixes #384
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.