Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Open sourcing code without including specific set-up values in source [closed]

I am creating a few small experiments / examples which I am open sourcing on git hub.

How have people dealt with user specific config/set-up vars in the past?

I would ideally like to commit the exact same code that I myself am using, but without including my URL's or app id / secrets etc.

I have thought that perhaps I could do it in one of the following ways, but is there a standard or recommended way of doing this?

baseURL = include myConfig.txt;

or

baseURL = "Enter Your URL Here";
like image 405
Trevor Boyle Avatar asked Aug 04 '26 17:08

Trevor Boyle


1 Answers

You could have the very simplest config options as environment variables.

You could have a small config object, which holds dummy values.

You could add a config.ini.sample file.

like image 171
olleolleolle Avatar answered Aug 07 '26 09:08

olleolleolle



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!