gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [taler-deployment] branch master updated: build subcommand


From: gnunet
Subject: [GNUnet-SVN] [taler-deployment] branch master updated: build subcommand
Date: Fri, 11 Oct 2019 19:16:00 +0200

This is an automated email from the git hooks/post-receive script.

dold pushed a commit to branch master
in repository deployment.

The following commit(s) were added to refs/heads/master by this push:
     new 91e61c6  build subcommand
91e61c6 is described below

commit 91e61c6cdf2737495ac975c41006aa575d488673
Author: Florian Dold <address@hidden>
AuthorDate: Fri Oct 11 22:45:50 2019 +0530

    build subcommand
---
 bin/taler-deployment | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/bin/taler-deployment b/bin/taler-deployment
index 68ca6dc..a3e5ca0 100755
--- a/bin/taler-deployment
+++ b/bin/taler-deployment
@@ -59,7 +59,7 @@ class Repo:
     name: str
     url: str
     deps: List[str]
-    builder: Callable
+    builder: Callable[[Repo, Path], None]
 
 
 @click.group()
@@ -131,7 +131,7 @@ def build_gnunet(r: Repo, p: Path):
     (p / "taler-buildstamp").touch()
 
 
-def build_exchange(r, p):
+def build_exchange(r: Repo, p: Path):
     update_checkout(r, p)
     subprocess.run(["./bootstrap"], check=True)
     pfx = Path.home() / "local"
@@ -295,7 +295,7 @@ def update_repos():
                 s.unlink()
 
 
-def get_stale_repos():
+def get_stale_repos() -> List[Repo]:
     timestamps = {}
     stale = []
     for r in repos:
@@ -305,7 +305,7 @@ def get_stale_repos():
             timestamps[r.name] = time.time()
             stale.append(r)
             continue
-        timestamps[r.name] = s.stat().st_mtime
+        ts = timestamps[r.name] = s.stat().st_mtime
         for dep in r.deps:
             if timestamps[dep] > ts:
                 stale.append(r)
@@ -314,7 +314,7 @@ def get_stale_repos():
 
 
 @cli.command()
-def build():
+def build() -> None:
     """Build the deployment from source."""
     ensure_activated()
     update_repos()
@@ -323,12 +323,12 @@ def build():
     for r in stale:
         p = Path.home() / "sources" / r.name
         os.chdir(p.as_posix())
-        r.builder(p)
+        r.builder(r, p) # type: ignore
 
 
 @cli.command()
 @click.argument("envname", type=click.Choice(["test", "int", "demo"]))
-def bootstrap(envname):
+def bootstrap(envname) -> None:
     """Bootstrap a GNU Taler deployment."""
 
     home = Path.home()

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]