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

[CLOSED] Do something about src/config.json #10881

Open
3 tasks done
core-ai-bot opened this issue Aug 30, 2021 · 6 comments
Open
3 tasks done

[CLOSED] Do something about src/config.json #10881

core-ai-bot opened this issue Aug 30, 2021 · 6 comments

Comments

@core-ai-bot
Copy link
Member

Issue by ficristo
Saturday Sep 10, 2016 at 14:08 GMT
Originally opened as adobe/brackets#12771


Prerequisites

  • Can you reproduce the problem with Debug \ Reload Without Extensions?
  • Did you perform a cursory search to see if your bug or enhancement is already reported?
  • Did you read the Troubleshooting guide?

For more information on how to write a good bug report read here
For more information on how to contribute read here

Description

Now that npm install is part of the build we should do something about config.json:
it is regenerated everytime which is ok, but it needs different values if we are in dev or in production.
We should find a better way to manage the differences.

Steps to Reproduce

  1. Run npm install

Expected behavior:
Running git status config.json should not appear in the modified files.

Actual behavior:
Running git status config.json appears in the modified files.

Versions

Windows 10
master

@core-ai-bot
Copy link
Member Author

Comment by zaggino
Saturday Sep 10, 2016 at 15:23 GMT


In brackets-electron I made src/config.json to be ignored by git, since it's recreated after every npm install

@core-ai-bot
Copy link
Member Author

Comment by ficristo
Saturday Sep 10, 2016 at 16:04 GMT


AFAIK the only thing to manage is healthDataServerURL which points to https://healthdev.brackets.io/healthDataLog in dev and points to https://health.brackets.io/healthDataLog in production.
After we find a way for that we can put src/config.json in .gitignore.

@core-ai-bot
Copy link
Member Author

Comment by petetnt
Sunday Sep 11, 2016 at 10:35 GMT


Can we use environment variables? Something like healthDataServerURL = (BRACKETS_ENV === "development" ? "https://healthdev.brackets.io/healthDataLog" : "https://health.brackets.io/healthDataLog")?

@core-ai-bot
Copy link
Member Author

Comment by MarcelGerber
Sunday Sep 11, 2016 at 22:07 GMT


We probably don't even need that.
package.json is used in dev and src/config.json in production, so we could just integrate this difference into the code that copies the values around.

@core-ai-bot
Copy link
Member Author

Comment by nethip
Friday Dec 09, 2016 at 05:57 GMT


Let me have a look at this issue. I am also thinking in line with@MarcelGerber

@core-ai-bot
Copy link
Member Author

Comment by MarcelGerber
Saturday Jun 17, 2017 at 21:16 GMT


Mostly fixed with #12778.
Created #13458 to fix another small inconsistency I am experiencing, see the PR description for more information.

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

1 participant