#atmos-dev (2025-01)
Discuss atmos core development (golang). If you want to help out, reach out to <@UB2EH889X>
2025-01-01
2025-01-02
@Andriy Knysh (Cloud Posse) this is ready for review https://github.com/cloudposse/atmos/pull/853
@Vinny the PR looks very good.
Just one misconfiguration in atmos.yaml
, please see the comment (and ping me when you fix it)
I am not able to reproduce this anymore https://linear.app/cloudposse/issue/DEV-2845/atmos-panics-instead-of-showing-error-for-incorrect-command
2025-01-03
@Andriy Knysh (Cloud Posse) this LGTM https://github.com/cloudposse/atmos/pull/905
what
The task is was “If a default is provided for a custom command, and required is true, then it shouldn’t error.”
before
a custom cli-command is defined
after
why
Provide a deafult value in atmos.yaml for a custom CLI command, so it doesn’t error out (before it did).
references
Link to the ticket - https://linear.app/cloudposse/issue/DEV-2327/default-value-for-demo-argument-should-not-cause-an-error
Summary by CodeRabbit
• New Features
• Enhanced custom command argument handling with required and default value support.
• Added new “greet” command with a configurable name argument.
• Documentation
• Updated documentation for custom commands, including command name change from “hello” to “greet”.
• Clarified positional argument requirements and default value handling.
• Bug Fixes
• Improved argument validation logic for custom commands.
• Added more robust error messaging for invalid command configurations.
• Tests
• Introduced new test cases for the “greet” command to validate argument handling and default values.
@Andriy Knysh (Cloud Posse) looks like good now https://github.com/cloudposse/atmos/pull/853
@Vinny this config in atmos.yaml
# Syntax highlighting configuration
syntax:
enabled: true
theme: "dracula" # or use custom colors from theme
line_numbers: true
wrap: false
looks like it’s a separate sub-section under settings
but it’s not in schema.go
it’s eigher needs to be removed from atmos.yaml
and the docs, or used in schema.go
and in the code
this should be settings.terminal.syntax
(Which it currently is)
I think we are good to remove this syntax
colorize should handle yaml
@Vinny please ping me here when you finish all the changes
Why remove? What does removing it solve
because syntax themes is implemented here https://github.com/cloudposse/atmos/pull/907/files#diff-c0d6f95f5584bc195d902401b649de3778ba9f88b3758b5f22a9bec32afa7cd8R319
we don’t need it there at all as we have custom colors
But themes is nice too :-)
yeah indeed its your guys decision at the end
But I don’t understand why we have both “syntax” and “syntax_highlighting”
will be only this syntax_highlighting we can rename it
Let’s combine
But yes, I prefer we keep support for themes
But document where the list of themes is found
so to summarize right now we have
• Glamour with markdown with custom colors
• (chroma themes for Glamour also) This is not implemented now
I can do this chroma in the same glamour PR or we can create another feature to implement it, up to you @Erik Osterman (Cloud Posse)
Let’s do that in a new PR
But yes, let’s do that. Can you write a linear task and self assign
sounds good
@Andriy Knysh (Cloud Posse) I think this is also ready https://github.com/cloudposse/atmos/pull/906
what
This PR contains the code that counts the number of recursive calls, and in case it exceeds the threshold, terminates the processes (parent + all children).
Add-on to atmos.yaml
The circuit breaker in use
why
Avoid infinite loops
references
Summary by CodeRabbit
• New Features
• Added a circuit breaker mechanism to prevent infinite shell command loops.
• Implemented maximum shell depth limit of 10 levels.
• Introduced a new command loop
for testing infinite loops in the CLI.
• Enhanced environment variable tracking for nested shell executions.
• Tests
• Added a new test case to verify circuit breaker functionality.
• Ensured CLI handles infinite loop scenarios gracefully.
This is good to start review @Andriy Knysh (Cloud Posse) https://github.com/cloudposse/atmos/pull/907