try to fix code block
This commit is contained in:
parent
614a2c0d42
commit
2390c055ba
1 changed files with 14 additions and 14 deletions
|
@ -37,20 +37,20 @@ Parse les argument du scripts
|
||||||
.. code-block:: python
|
.. code-block:: python
|
||||||
:linenos:
|
:linenos:
|
||||||
|
|
||||||
def get_args():
|
def get_args():
|
||||||
"""
|
"""
|
||||||
parse agrs
|
parse agrs
|
||||||
"""
|
"""
|
||||||
parser = argparse.ArgumentParser(description="Update dns zone with online.net API")
|
parser = argparse.ArgumentParser(description="Update dns zone with online.net API")
|
||||||
group = parser.add_mutually_exclusive_group()
|
group = parser.add_mutually_exclusive_group()
|
||||||
group.add_argument("-v", "--verbose", action="store_true")
|
group.add_argument("-v", "--verbose", action="store_true")
|
||||||
group.add_argument("-q", "--quiet", action="store_true")
|
group.add_argument("-q", "--quiet", action="store_true")
|
||||||
parser.add_argument("-c", "--clean", help="clean old unused zones", action="store_true")
|
parser.add_argument("-c", "--clean", help="clean old unused zones", action="store_true")
|
||||||
parser.add_argument("-t", "--token", help="token's API (https://console.online.net/fr/api/access)")
|
parser.add_argument("-t", "--token", help="token's API (https://console.online.net/fr/api/access)")
|
||||||
parser.add_argument("-u", "--url", help="url to get public ip, default=http://ifconfig.me", default="http://ifconfig.me")
|
parser.add_argument("-u", "--url", help="url to get public ip, default=http://ifconfig.me", default="http://ifconfig.me")
|
||||||
parser.add_argument("-r", "--records", help="records to update, comma separated list")
|
parser.add_argument("-r", "--records", help="records to update, comma separated list")
|
||||||
parser.add_argument("domain", help="domain to update")
|
parser.add_argument("domain", help="domain to update")
|
||||||
return parser.parse_args()
|
return parser.parse_args()
|
||||||
|
|
||||||
|
|
||||||
fonction clear
|
fonction clear
|
||||||
|
|
Loading…
Reference in a new issue