]> git.mxchange.org Git - fba.git/commitdiff
Continued:
authorRoland Häder <roland@mxchange.org>
Sun, 7 Jul 2024 20:13:23 +0000 (22:13 +0200)
committerRoland Häder <roland@mxchange.org>
Sun, 7 Jul 2024 20:13:23 +0000 (22:13 +0200)
- moved args.single handling to proper level
- wrapped strings in Shell script
- explained all entries in .gitignore

.gitignore
fba/commands.py
nodeinfo.sh

index 9f3aac0e8cc5ac084902b82ee721ba89de556a45..75d48091d83920b59ff1a83ec18dba83c6b3a5f2 100644 (file)
@@ -1,10 +1,19 @@
+# Local database file
 blocks.db*
+
+# Local configuration file
+config.json
+
+# pyreport report file
+report.log
+
+# WIP:
 blocklists/*/
+
+# Generated files by Python
 __pycache__/
-config.json
 *.cover
 *.pyc
-report.log
 *.log
 
 # Virtual environment
index a514c7914bbfe78d48d6936148c207a46fcd0b5c..8643c3009a4d47259ae9127b0348129d341d9d37 100644 (file)
@@ -1023,9 +1023,9 @@ def fetch_instances(args: argparse.Namespace) -> int:
             instances.update(row["domain"])
             continue
 
-        if args.single:
-            logger.debug("Not fetching more instances - BREAK!")
-            break
+    if args.single:
+        logger.debug("Not fetching more instances - EXIT!")
+        return 0
 
     # Loop through some instances
     database.cursor.execute(
index adfc385f66389a14776b77366ccdb8c44a4fcd2e..9712a294379814b3c78e626843a80e9985705ad9 100755 (executable)
@@ -48,12 +48,12 @@ then
                echo "$0: DOMAIN='${DOMAIN}'"
                if [ -n "$1" -a -z "${MODE}" ]
                then
-                       ./fba.py update_nodeinfo --domain=${DOMAIN} "$1"
+                       ./fba.py update_nodeinfo --domain="${DOMAIN}" "$1"
                elif [ -n "$2" ]
                then
-                       ./fba.py update_nodeinfo --domain=${DOMAIN} "$2"
+                       ./fba.py update_nodeinfo --domain="${DOMAIN}" "$2"
                else
-                       ./fba.py update_nodeinfo --domain=${DOMAIN}
+                       ./fba.py update_nodeinfo --domain="${DOMAIN}"
                fi
        done
 elif [ -n "${SOFTWARE_LIST}" ]
@@ -63,9 +63,9 @@ then
                echo "$0: SOFTWARE='${SOFTWARE}'"
                if [ -n "$2" ]
                then
-                       ./fba.py update_nodeinfo --software=${SOFTWARE} "$2"
+                       ./fba.py update_nodeinfo --software="${SOFTWARE}" "$2"
                else
-                       ./fba.py update_nodeinfo --software=${SOFTWARE}
+                       ./fba.py update_nodeinfo --software="${SOFTWARE}"
                fi
        done
 fi