configuration-files

Hide octave-workspace file from home directory

对着背影说爱祢 提交于 2019-12-02 01:03:32
I would like to change the file octave-workspace from my home directory, simply renaming it to .octave_workspace . How can I manage to make octave recognize a workspace file (or create a new one) with this new name? Thanks. That is the purpose of the octave_core_file_name() function. Add the following to your .octaverc file: octave_core_file_name (".octave-workspace") OSX Solution: You can use chflags To hide a file from Finder: chflags hidden /Path/To/File To unhide: chflags nohidden /Path/To/File Linux Solution: From what I'm reading here, you can create a "hidden" files file, which contains

Where to put a config file for a compiled Python script?

梦想的初衷 提交于 2019-12-01 23:47:22
问题 This is similar to Where to put a configuration file in Python?, but I'm asking about scripts compiled/frozen with py2exe or similar on Windows systems. (Namely, this one: What config file format to use for user-friendly strings of arbitrary bytes? https://gist.github.com/1119561) My first thought was to put the config file in the same folder as the .exe, which makes it sort of self-contained. But if I associate files with the .exe, it will be called from their directory, not its own, so I'd

Append or modify keys in conf files using sed/bash one-liner

左心房为你撑大大i 提交于 2019-12-01 23:11:33
I often have to modify files such as sysctl.conf , and I'm familiar with using sed to replace existing values. Is there a way to append the new key/value pair to the file if sed wasn't able to replace it? For instance, using this example: modify config file using bash script sed -c -i "s/\($TARGET_KEY *= *\).*/\1$REPLACEMENT_VALUE/" $CONFIG_FILE How could I add the $TARGET_KEY = $REPLACEMENT_VALUE new line to $CONFIG_FILE using the same sed expression with slight changes? And on a related topic, how can I force creation of $CONFIG_FILE if it didn't exist? You can't easily do it all in a single

What is the equivalent of Web.config transform in ASP.NET Core?

孤街浪徒 提交于 2019-12-01 17:54:19
ASP.NET Core documentation suggests we should use appsettings.json file, along with a file per environment, containing overriding values. The problem is that all these files are published, though only appsettings.json and appsettings.[Environment].json are relevant. The other problem is that to change a config value on server one must inspect both files: base and environment specific. So my question is: what is the cleanest way to have one configuration file in each deployment environment? The key difference is that ASP.NET Core apps are not deployed for a particular configuration, as ASP.NET

Celery: ignoring BROKER_URL in config file

China☆狼群 提交于 2019-12-01 17:03:50
My question is a duplicate of this one , but more detailed. The problem is that I have a BROKER_URL set in my Celery config file, but that isn't reflected in and I am loading the config: I checked, and it is being loaded - in fact, other constants defined there are being set, just not BROKER_URL . This appears to be a bug, but I wanted to be sure. celeryconfig.py : BROKER_URL = "amqp://user:password@remote.server.com:5672//vhost" CELERY_TASK_SERIALIZER = 'json' CELERY_RESULT_SERIALIZER = 'json' CELERY_ENABLE_UTC = True ( JSON is being used as the serializer, not Pickle , so I know this is

Symfony2 - Why use XML for settings/config?

好久不见. 提交于 2019-12-01 15:56:40
Is there any interest to use XML over YAML for each of these types of file: config security routing services translations I would like to ask XML vs YAML and JSON globally, but I'll stick to these topics :) Vitalii Zurian In my company projects for each of mentioned above points we use YAML because it is more readable. The most readable. The readablest. EDIT : The only abstract situation I can imagine for using XML over YAML - is probably for some dynamic file writers, since it is easier to manipulate with nodes using SimpleXML or something like that. For example, if you need to define some

Unable to create a custom section for web.config

我与影子孤独终老i 提交于 2019-12-01 13:32:22
问题 I created a custom section in the web.config file but it isn't able to load my custom type that is going to manage the section. Here are the definitions: <configSections> <section name="MembershipProviders" type="MyApp.BusinessObjects.MembershipProviderFactory.MembershipProvidersSection" allowLocation="true" allowDefinition="Everywhere" /> </configSections> namespace MyApp.BusinessObjects { public class MembershipProviderFactory { internal virtual IMembershipProvider Create() { } public class

Asp.Net VNext App Settings on Azure

淺唱寂寞╮ 提交于 2019-12-01 12:06:40
I really enjoyed the new Configuration feature of Asp.Net vNext using de default appsettings.json But I would like to change the values of that file when I publish the website as a Azure Web App. The old web.config appsettings was easy to change and configure the properties on the environment. Do you know how to do this? I prefer to user the default provider instead of creating a custom configuration provider. Thank you! If you set App Settings in the Azure Portal, they become environment variables at runtime, and should get picked up by the ASP.NET vNext runtime. So you don't need to

Permanent Config File in Pylint

有些话、适合烂在心里 提交于 2019-12-01 11:07:43
问题 I've setup a custom configuration file for Pylint (name, conveniently, config). There has to be a way that I don't have to include --rcfile=config on every run. How can I set the config file permanently? 回答1: set the path to that file in the PYLINTRC environment variable, or rename the file $HOME/.pylintrc or /etc/pylintrc (the latter is probably only supported on *nix) 回答2: When you do not specify the --rcfile option, Pylint searches for a configuration file in the following order and uses

WCF Config element: baseAddressPrefixFilters

廉价感情. 提交于 2019-12-01 05:47:01
I have read the documentation for this element but still fail to understand what its purpose is. Here is a sample of how I've seen it used in examples: <serviceHostingEnvironment> <baseAddressPrefixFilters> <add prefix="http://localhost:5100/"/> </baseAddressPrefixFilters> </serviceHostingEnvironment> I want to understand what this does that the base addresses in a service node doesn't do. I don't understand what this element is actually used for. Maurice A WCF service host will only allow a single base address per scheme (HTTP in this case). Now if you deploy a WCF service on an IIS