Manage configuration files across environments

The Config4* project (disclaimer: I am its primary developer) does not have an out-of-the-box integration with .Net or WCF, so it is probably not useful to you. However, one of the features in Config4* is relevant to your question: it is the ability to embed if-then-else statements in a configuration file, so that the file … Read more

How do I find the current machine’s full hostname in C (hostname and domain information)?

To get a fully qualified name for a machine, we must first get the local hostname, and then lookup the canonical name. The easiest way to do this is by first getting the local hostname using uname() or gethostname() and then performing a lookup with gethostbyname() and looking at the h_name member of the struct … Read more

Get spring application environment in thymeleaf

You can do the following if you only have one profile active at a time. <div th:if=”${@environment.getActiveProfiles()[0] == ‘production’}”> This is the production profile – do whatever you want in here </div> The code above is based on the fact that the Thymeleaf’s Spring dialect lets you access beans using the @ symbol. And of … Read more

How to specify version ranges in Conda environment.yml

I think/assume that the syntax specifying versions is the one documented at Package match specifications. So you would write – numpy >=1.2.3,<1.3 (space after numpy, no space after the comma – not tested). BTW, I couldn’t find any documentation describing the structure of the environment file environment.yml. creating-an-environment-from-an-environment-yml-file refers to Creating an environment file manually … Read more