gnuastro-commits
[Top][All Lists]
Advanced

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

[gnuastro-commits] master e5707cd 28/62: Table: Completion, all options,


From: Mohammad Akhlaghi
Subject: [gnuastro-commits] master e5707cd 28/62: Table: Completion, all options, update comments
Date: Thu, 13 May 2021 22:20:49 -0400 (EDT)

branch: master
commit e5707cdfa226d3998c29ef7b0f0dfc3aaaec4abc
Author: Pedram Ashofteh Ardakani <pedramardakani@pm.me>
Commit: Mohammad Akhlaghi <mohammad@akhlaghi.org>

    Table: Completion, all options, update comments
    
    With this commit, all options in the 'Table' program are covered.
    
    TODO: Check if we need the autocomplete to print any messages for the
    user.
---
 bin/table/completion.sh | 16 +++++++---------
 1 file changed, 7 insertions(+), 9 deletions(-)

diff --git a/bin/table/completion.sh b/bin/table/completion.sh
index ad61356..6081615 100644
--- a/bin/table/completion.sh
+++ b/bin/table/completion.sh
@@ -208,10 +208,8 @@ _gnuastro_asttable_completions(){
         prev="${COMP_WORDS[COMP_CWORD-2]}"
     fi
 
-    # A quick check to see if there is already a fits file name invoked in
-    # the current commandline. This means the order of commands does matter
-    # in this bash completion. If we do not want this, we should implement
-    # another method for suggesting completions.
+    # Return the last fits file specified in the commandline. If none,
+    # $fits_name will be a null string, i.e. "".
     fits_name="$(_gnuastro_autocomplete_get_fits_name)"
 
     # TODO: Prettify the code syntax, shorter ones on top
@@ -236,22 +234,22 @@ _gnuastro_asttable_completions(){
             # Only suggest a fits filename
             _gnuastro_autocomplete_list_fits_names
             ;;
-        -c|--column|-r|--range|-s|--sort|-C|--catcolumns)
+        -c|--column|-r|--range|-s|--sort|-C|--catcolumns| \
+            -m|--colmetadata|--inpolygon|--outpolygon| \
+            -e|--equal|-n|--notequal|-b|--noblank)
             # The function below returns the columns inside the last fits
             # file specified in the commandline. If no fits files were
             # detected, there will be no response from autocompletion. This
             # might alert the user that something is going wrong.
             _gnuastro_autocomplete_list_fits_columns "$fits_name"
             ;;
-        -W|--wcshdu)
+        -W|--wcshdu|-u|--catcolumnhdu|-h|--hdu)
             # Description is same as the '--column' option.
             _gnuastro_autocomplete_list_fits_hdu "$fits_name"
             ;;
-        -o|--output)
+        -o|--output|--polygon|-H|--head|-t|--tail)
             # Do not suggest anything.
             ;;
-        -b|--noblank) ;;
-        -h|--hdu) ;;
         *) _gnuastro_autocomplete_list_options $PROG_ADDRESS ;;
     esac
 



reply via email to

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