stecklars / dynamic-dns-netcup-api

A simple dynamic DNS client written in PHP for use with the netcup DNS API.
MIT License
178 stars 55 forks source link

Specify config files on command line #20

Closed hpreusse closed 1 year ago

hpreusse commented 2 years ago

Not sure, if I missed that option. It should be possible to specify the config file on the command line. In my personal hack it looks like this:

diff -urN dynamic-dns-netcup-api-master_mod_hilmar/functions.php dynamic-dns-netcup-api-master_mod_hilmar_orig/functions.php
--- dynamic-dns-netcup-api-master_mod_hilmar/functions.php      2021-10-23 14:53:58.036193565 +0200
+++ dynamic-dns-netcup-api-master_mod_hilmar_orig/functions.php 2018-06-10 05:27:20.000000000 +0200
@@ -1,6 +1,6 @@
 <?php

-require_once $argv[1];
+require_once 'config.php';

 //Declare possbile options
 $quiet = false;

Yes, this is based on a old release.``

stecklars commented 1 year ago

Hi @hpreusse,

Thank you for your suggestion.

This is now a new feature in the newest version 4.0 of the script: https://github.com/stecklars/dynamic-dns-netcup-api/releases/tag/v4.0