Skip to content
Snippets Groups Projects
Commit abfaee4b authored by Lemmer, Jan's avatar Lemmer, Jan
Browse files

update config information

parent 0b4f1e8e
Branches
Tags
2 merge requests!43Implements #73, cleans up example file,,!38Dev/example
Pipeline #596982 failed
......@@ -106,14 +106,52 @@ fileCompare checks if file1 is (binary) identical to a file in filelist, it retu
removePltIdFiles removes functions that are part of PlotID out of flist.
# How to use the .config file
The config file is a JSON-File. At the moment two options can be set in the config file, the project ID and the remote Path.
The config file is a JSON-File. The config file stores user data and options of `PlotID`. It will be created when you use PlotID for the first time. Follow the Instructions to create the file. _Note:_ for basic usage no manual changes on the config file are required. \
**Note:** If you mess up your config-file simply delete it, PlotID will create a new one the next time you use it.
## Define an export path
If you define an export path in the config.json this path is used as location for the exported data.
## Store custom options for Publish
**add custom publish options to the config file** \
you can define your custom options for publish in the config file. **Important:** They will always have priority against Name-Value pairs!
```
configFileName = 'config.json';
configObj = PlotID.config(configFileName);
```
{
"ProjectID": "your ProjectID",
"ServerPath": "\\\\Server\\Folder1\\Subfolder"
}
This method adds the default config to your config file
```
configObj.addPublishOptions('default');
```
You can change the options in the json file, but be carefull no argumentValidation will be done on options from the config file!
## Working with multiple (project dependend) config files
<details><summary> Expand </summary>
It is possible to use individual config files for each project (configP1.json, configP2.json, ...) \
1. Create a new config file programatically
```
customConfigFileName = 'configP1.json';
configObj = PlotID.config(customConfigFileName);
configObj.addPublishOptions('default');
```
2. Use the custom Config
you need to provide the name of your custom config file to tagplot as well as to publish by using the Name-Value Pair:
` 'ConfigFileName','YOURNAME.json'` :
```
[figs, IDs] = PlotID.TagPlot(figs, 'ConfigFileName','configP1.json');
Publish(DataPaths,scriptPath, 'ConfigFileName','configP1.json')
```
</details>
# Aknowledgements
The authors would like to thank the Federal Government and the Heads of Government of the Länder, as well as the Joint Science Conference (GWK), for their funding and support within the framework of the NFDI4Ing consortium. Funded by the German Research Foundation (DFG) - project number 442146713.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment