From e28fc224d85d8d46239e4279e55eb90ebc206242 Mon Sep 17 00:00:00 2001
From: Tim O'Donnell <timodonnell@gmail.com>
Date: Tue, 6 Feb 2018 17:25:13 -0500
Subject: [PATCH] Add --version argument to mhcflurry-predict

---
 mhcflurry/predict_command.py | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/mhcflurry/predict_command.py b/mhcflurry/predict_command.py
index aea742d3..61f64e4f 100644
--- a/mhcflurry/predict_command.py
+++ b/mhcflurry/predict_command.py
@@ -35,6 +35,7 @@ import pandas
 
 from .downloads import get_default_class1_models_dir
 from .class1_affinity_predictor import Class1AffinityPredictor
+from .version import __version__
 
 
 parser = argparse.ArgumentParser(
@@ -61,7 +62,11 @@ helper_args.add_argument(
     default=False,
     help="Prints the list of supported peptide lengths and exits"
 )
-
+helper_args.add_argument(
+    "--version",
+    action="version",
+    version="mhcflurry %s" % __version__,
+)
 
 input_args = parser.add_argument_group(title="Required input arguments")
 input_args.add_argument(
-- 
GitLab