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

Introduce regex to parse alephium.config.ts #277

Merged
merged 2 commits into from
Aug 26, 2024

Conversation

tdroxler
Copy link
Member

Based on this PR #239

We use regex to extract config from alephium.config.ts

Regex only allows to use simple configurations as it can't understand TS code, so no env variable or functions can be used to define the config value we are parsing here.

Currently we don't report error if we can't extract anything from alephium.config.ts and fallback on current or default config.

Copy link
Member

@simerplaha simerplaha left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've documented the drawbacks in #278, so they are in one place.

I will start writing test-cases for #239 using your transformer 👍🏼.

Using regex allows only to use simple configurations as it can't
understand TS code, so no env variable or functions can be used to
define the config value we are parsing here.
@tdroxler tdroxler force-pushed the alephium_config_ts_tranformer branch from 4780e2d to 1ec5ad0 Compare August 26, 2024 10:04
@tdroxler tdroxler merged commit fd9e005 into alephium_config_ts Aug 26, 2024
3 checks passed
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 this pull request may close these issues.

2 participants