about summary refs log tree commit diff
path: root/pkgs/applications/version-management
diff options
context:
space:
mode:
authorFlorian Klink <flokli@flokli.de>2020-04-20 17:09:02 +0200
committerMilan <me@pbb.lc>2020-04-27 10:31:36 +0200
commit412bb5e04dd405c2d4822c0eadff269f573e33a0 (patch)
treef4cbaf24b7817a6eaacccb49dd8cfbf8d419af35 /pkgs/applications/version-management
parent9a23aeab34457e158aa10bbdc1630157f1a5fc31 (diff)
downloadnixlib-412bb5e04dd405c2d4822c0eadff269f573e33a0.tar
nixlib-412bb5e04dd405c2d4822c0eadff269f573e33a0.tar.gz
nixlib-412bb5e04dd405c2d4822c0eadff269f573e33a0.tar.bz2
nixlib-412bb5e04dd405c2d4822c0eadff269f573e33a0.tar.lz
nixlib-412bb5e04dd405c2d4822c0eadff269f573e33a0.tar.xz
nixlib-412bb5e04dd405c2d4822c0eadff269f573e33a0.tar.zst
nixlib-412bb5e04dd405c2d4822c0eadff269f573e33a0.zip
gitlab: support passing --rev to the `update-all` script
While it's already possible to invoke `update-data` with the `--rev`
argument, one still needs to run all later phases manually.

Fix this, by having `update-all` also accept a `--rev` argument, and
pass it down to `update-data`.

Also, make the help text a bit more usable, by suggesting the usual
versioning scheme used these times.
Diffstat (limited to 'pkgs/applications/version-management')
-rwxr-xr-xpkgs/applications/version-management/gitlab/update.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/pkgs/applications/version-management/gitlab/update.py b/pkgs/applications/version-management/gitlab/update.py
index a2a3a6d05b7e..86ef1e9736cc 100755
--- a/pkgs/applications/version-management/gitlab/update.py
+++ b/pkgs/applications/version-management/gitlab/update.py
@@ -100,7 +100,7 @@ def cli():
 
 
 @cli.command('update-data')
-@click.option('--rev', default='latest', help='The rev to use, \'latest\' points to the latest (stable) tag')
+@click.option('--rev', default='latest', help='The rev to use (vX.Y.Z-ee), or \'latest\'')
 def update_data(rev: str):
     """Update data.nix"""
     repo = GitLabRepo()
@@ -227,10 +227,11 @@ def update_gitlab_workhorse():
         os.unlink(gitlab_workhorse_dir / fn)
 
 @cli.command('update-all')
+@click.option('--rev', default='latest', help='The rev to use (vX.Y.Z-ee), or \'latest\'')
 @click.pass_context
-def update_all(ctx):
+def update_all(ctx, rev: str):
     """Update all gitlab components to the latest stable release"""
-    ctx.invoke(update_data, rev='latest')
+    ctx.invoke(update_data, rev=rev)
     ctx.invoke(update_rubyenv)
     ctx.invoke(update_yarnpkgs)
     ctx.invoke(update_gitaly)