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

Update example jq for retrieving regions and carbon intensity #4320

Closed
gilzow opened this issue Jan 7, 2025 · 0 comments · Fixed by #4321
Closed

Update example jq for retrieving regions and carbon intensity #4320

gilzow opened this issue Jan 7, 2025 · 0 comments · Fixed by #4321
Assignees

Comments

@gilzow
Copy link
Collaborator

gilzow commented Jan 7, 2025

Where on docs.platform.sh should be changed?

https://docs.platform.sh/development/regions.html#environmental-impact
https://docs.upsun.com/development/regions.html#environmental-impact

What exactly should be updated?

from:

platform api:curl regions | jq -r '.regions[] | select(.available) | .label + ": " + .environmental_impact.carbon_intensity'

to

platform api:curl regions | jq -r '.regions[] | select(.available) | "\(.label): \(.environmental_impact.carbon_intensity)"'

Additional context

we might consider mentioning we're using jq's string interpolation https://jqlang.github.io/jq/manual/#string-interpolation

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

Successfully merging a pull request may close this issue.

1 participant