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

Github Actions uses invalid environment variables. #22

Closed
shadycuz opened this issue May 20, 2021 · 5 comments
Closed

Github Actions uses invalid environment variables. #22

shadycuz opened this issue May 20, 2021 · 5 comments
Assignees

Comments

@shadycuz
Copy link

I'm trying to test this action locally before creating my own. However the action only echo's hello. When I try to set the environment variable:

export INPUT_WHO-TO-GREET=test
bash: export: `INPUT_WHO-TO-GREET=test': not a valid identifier

It fails? It seems Github Actions allows - in its Environment variables but bash doesn't.

@jonatanlr98
Copy link

export INPUT_WHO-TO-GREET=test
bash: export: `INPUT_WHO-TO-GREET=test': not a valid identifier

@jonatanlr98
Copy link

#22 (comment)

@dh-orko
Copy link

dh-orko commented May 31, 2023

xport INPUT_WHO-TO-GREET=test
bash: export: `INPUT_WHO-TO-GREET=test': not a valid identifier

@ncalteen
Copy link
Collaborator

When testing this locally, it looks like @actions/core library is looking for the INPUT_WHO_TO_GREET environment variable instead. Hyphens are being replaced with underscores. Let me know if that helps!

@ncalteen ncalteen self-assigned this Nov 7, 2023
@ncalteen
Copy link
Collaborator

ncalteen commented Nov 7, 2023

Hello! Closing this out for now, but if you're still running into any kind of issue please reopen and let me know! I will try to respond soon as I can :)

@ncalteen ncalteen closed this as completed Nov 7, 2023
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

No branches or pull requests

6 participants
@ncalteen @shadycuz @dh-orko @jonatanlr98 and others