gnuastro-commits
[Top][All Lists]
Advanced

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

[gnuastro-commits] master 4f016d13 2/2: Installed scripts: sources are r


From: Mohammad Akhlaghi
Subject: [gnuastro-commits] master 4f016d13 2/2: Installed scripts: sources are renamed to .sh instead of .in
Date: Thu, 13 Jul 2023 13:26:05 -0400 (EDT)

branch: master
commit 4f016d137c9d497465dfef02624eb140ca82e6bf
Author: Mohammad Akhlaghi <mohammad@akhlaghi.org>
Commit: Mohammad Akhlaghi <mohammad@akhlaghi.org>

    Installed scripts: sources are renamed to .sh instead of .in
    
    Until now, the source of the installed scripts were files that are named as
    '*.in'. However, this suffix is mostly used by tools like Automake to make
    temporary intermediate files (like the 'Makefile.in' files). As a result,
    line-counting software (like CLOC) ignore the '*.in' files and this is
    harmful for general statistics of Gnuastro's source code.
    
    With this commit, to solve the problem, the source file of the installed
    scripts ends in '.sh' (as a shell script should be).
---
 bin/script/Makefile.am                             | 72 +++++++++++-----------
 .../{dither-simulate.in => dither-simulate.sh}     |  0
 bin/script/{ds9-region.in => ds9-region.sh}        |  0
 ...s-view.desktop.in => fits-view.desktop.desktop} |  0
 bin/script/{fits-view.in => fits-view.sh}          |  0
 .../{psf-scale-factor.in => psf-scale-factor.sh}   |  0
 .../{psf-select-stars.in => psf-select-stars.sh}   |  0
 bin/script/{psf-stamp.in => psf-stamp.sh}          |  0
 bin/script/{psf-subtract.in => psf-subtract.sh}    |  0
 bin/script/{psf-unite.in => psf-unite.sh}          |  0
 .../{radial-profile.in => radial-profile.sh}       |  0
 bin/script/{sort-by-night.in => sort-by-night.sh}  |  0
 bin/script/{zeropoint.in => zeropoint.sh}          |  0
 doc/Makefile.am                                    | 66 +++++++++++++-------
 14 files changed, 81 insertions(+), 57 deletions(-)

diff --git a/bin/script/Makefile.am b/bin/script/Makefile.am
index 788c8c8a..b4e211b9 100644
--- a/bin/script/Makefile.am
+++ b/bin/script/Makefile.am
@@ -27,9 +27,9 @@
 pkgdata_DATA = zeropoint.mk \
                dither-simulate.mk \
                astscript-fits-view.desktop
-astscript-fits-view.desktop: $(srcdir)/fits-view.desktop.in Makefile
+astscript-fits-view.desktop: $(srcdir)/fits-view.desktop.desktop Makefile
        sed -e 's|@PREFIX[@]|$(exec_prefix)|g' \
-           $(srcdir)/fits-view.desktop.in > $@
+           $(srcdir)/fits-view.desktop.desktop > $@
 
 
 
@@ -51,20 +51,20 @@ bin_SCRIPTS = astscript-fits-view \
               astscript-psf-scale-factor \
               astscript-psf-select-stars
 
-EXTRA_DIST = fits-view.in \
-             psf-unite.in \
-             psf-stamp.in \
-             zeropoint.in \
+EXTRA_DIST = fits-view.sh \
+             psf-unite.sh \
+             psf-stamp.sh \
+             zeropoint.sh \
              zeropoint.mk \
-             ds9-region.in \
-             psf-subtract.in \
-             sort-by-night.in \
-             radial-profile.in \
-             dither-simulate.in \
+             ds9-region.sh \
+             psf-subtract.sh \
+             sort-by-night.sh \
+             radial-profile.sh \
+             dither-simulate.sh \
              dither-simulate.mk \
-             psf-select-stars.in \
-             psf-scale-factor.in \
-             fits-view.desktop.in
+             psf-select-stars.sh \
+             psf-scale-factor.sh \
+             fits-view.desktop.desktop
 
 CLEANFILES = $(bin_SCRIPTS) \
              astscript-fits-view.desktop
@@ -84,46 +84,46 @@ do_subst = sed -e 's,[@]PREFIX[@],$(exec_prefix),g' \
 
 
 ## Rules to install the scripts.
-astscript-dither-simulate: dither-simulate.in Makefile
-       $(do_subst) < $(srcdir)/dither-simulate.in > $@
+astscript-dither-simulate: dither-simulate.sh Makefile
+       $(do_subst) < $(srcdir)/dither-simulate.sh > $@
        chmod +x $@
 
-astscript-ds9-region: ds9-region.in Makefile
-       $(do_subst) < $(srcdir)/ds9-region.in > $@
+astscript-ds9-region: ds9-region.sh Makefile
+       $(do_subst) < $(srcdir)/ds9-region.sh > $@
        chmod +x $@
 
-astscript-fits-view: fits-view.in Makefile
-       $(do_subst) < $(srcdir)/fits-view.in > $@
+astscript-fits-view: fits-view.sh Makefile
+       $(do_subst) < $(srcdir)/fits-view.sh > $@
        chmod +x $@
 
-astscript-psf-unite: psf-unite.in Makefile
-       $(do_subst) < $(srcdir)/psf-unite.in > $@
+astscript-psf-unite: psf-unite.sh Makefile
+       $(do_subst) < $(srcdir)/psf-unite.sh > $@
        chmod +x $@
 
-astscript-psf-stamp: psf-stamp.in Makefile
-       $(do_subst) < $(srcdir)/psf-stamp.in > $@
+astscript-psf-stamp: psf-stamp.sh Makefile
+       $(do_subst) < $(srcdir)/psf-stamp.sh > $@
        chmod +x $@
 
-astscript-psf-scale-factor: psf-scale-factor.in Makefile
-       $(do_subst) < $(srcdir)/psf-scale-factor.in > $@
+astscript-psf-scale-factor: psf-scale-factor.sh Makefile
+       $(do_subst) < $(srcdir)/psf-scale-factor.sh > $@
        chmod +x $@
 
-astscript-psf-select-stars: psf-select-stars.in Makefile
-       $(do_subst) < $(srcdir)/psf-select-stars.in > $@
+astscript-psf-select-stars: psf-select-stars.sh Makefile
+       $(do_subst) < $(srcdir)/psf-select-stars.sh > $@
        chmod +x $@
 
-astscript-psf-subtract: psf-subtract.in Makefile
-       $(do_subst) < $(srcdir)/psf-subtract.in > $@
+astscript-psf-subtract: psf-subtract.sh Makefile
+       $(do_subst) < $(srcdir)/psf-subtract.sh > $@
        chmod +x $@
 
-astscript-radial-profile: radial-profile.in Makefile
-       $(do_subst) < $(srcdir)/radial-profile.in > $@
+astscript-radial-profile: radial-profile.sh Makefile
+       $(do_subst) < $(srcdir)/radial-profile.sh > $@
        chmod +x $@
 
-astscript-sort-by-night: sort-by-night.in Makefile
-       $(do_subst) < $(srcdir)/sort-by-night.in > $@
+astscript-sort-by-night: sort-by-night.sh Makefile
+       $(do_subst) < $(srcdir)/sort-by-night.sh > $@
        chmod +x $@
 
-astscript-zeropoint: zeropoint.in Makefile
-       $(do_subst) < $(srcdir)/zeropoint.in > $@
+astscript-zeropoint: zeropoint.sh Makefile
+       $(do_subst) < $(srcdir)/zeropoint.sh > $@
        chmod +x $@
diff --git a/bin/script/dither-simulate.in b/bin/script/dither-simulate.sh
similarity index 100%
rename from bin/script/dither-simulate.in
rename to bin/script/dither-simulate.sh
diff --git a/bin/script/ds9-region.in b/bin/script/ds9-region.sh
similarity index 100%
rename from bin/script/ds9-region.in
rename to bin/script/ds9-region.sh
diff --git a/bin/script/fits-view.desktop.in 
b/bin/script/fits-view.desktop.desktop
similarity index 100%
rename from bin/script/fits-view.desktop.in
rename to bin/script/fits-view.desktop.desktop
diff --git a/bin/script/fits-view.in b/bin/script/fits-view.sh
similarity index 100%
rename from bin/script/fits-view.in
rename to bin/script/fits-view.sh
diff --git a/bin/script/psf-scale-factor.in b/bin/script/psf-scale-factor.sh
similarity index 100%
rename from bin/script/psf-scale-factor.in
rename to bin/script/psf-scale-factor.sh
diff --git a/bin/script/psf-select-stars.in b/bin/script/psf-select-stars.sh
similarity index 100%
rename from bin/script/psf-select-stars.in
rename to bin/script/psf-select-stars.sh
diff --git a/bin/script/psf-stamp.in b/bin/script/psf-stamp.sh
similarity index 100%
rename from bin/script/psf-stamp.in
rename to bin/script/psf-stamp.sh
diff --git a/bin/script/psf-subtract.in b/bin/script/psf-subtract.sh
similarity index 100%
rename from bin/script/psf-subtract.in
rename to bin/script/psf-subtract.sh
diff --git a/bin/script/psf-unite.in b/bin/script/psf-unite.sh
similarity index 100%
rename from bin/script/psf-unite.in
rename to bin/script/psf-unite.sh
diff --git a/bin/script/radial-profile.in b/bin/script/radial-profile.sh
similarity index 100%
rename from bin/script/radial-profile.in
rename to bin/script/radial-profile.sh
diff --git a/bin/script/sort-by-night.in b/bin/script/sort-by-night.sh
similarity index 100%
rename from bin/script/sort-by-night.in
rename to bin/script/sort-by-night.sh
diff --git a/bin/script/zeropoint.in b/bin/script/zeropoint.sh
similarity index 100%
rename from bin/script/zeropoint.in
rename to bin/script/zeropoint.sh
diff --git a/doc/Makefile.am b/doc/Makefile.am
index 02d770ce..5e4d146e 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -144,20 +144,39 @@ endif
 if COND_WARP
   MAYBE_WARP_MAN = man/astwarp.1
 endif
+
 #if COND_TEMPLATE
 #  MAYBE_TEMPLATE_MAN = man/astTEMPLATE.1
 #endif
-dist_man_MANS = $(MAYBE_ARITHMETIC_MAN) $(MAYBE_BUILDPROG_MAN) \
-  $(MAYBE_CONVERTT_MAN) $(MAYBE_CONVOLVE_MAN) $(MAYBE_COSMICCAL_MAN) \
-  $(MAYBE_CROP_MAN) $(MAYBE_FITS_MAN) $(MAYBE_MATCH_MAN) \
-  $(MAYBE_MKCATALOG_MAN) $(MAYBE_MKNOISE_MAN) $(MAYBE_MKPROF_MAN) \
-  $(MAYBE_NOISECHISEL_MAN) $(MAYBE_QUERY_MAN) $(MAYBE_SEGMENT_MAN) \
-  $(MAYBE_STATISTICS_MAN) $(MAYBE_TABLE_MAN) $(MAYBE_WARP_MAN) \
-  man/astscript-ds9-region.1 man/astscript-fits-view.1 \
-  man/astscript-psf-scale-factor.1 man/astscript-psf-select-stars.1 \
-  man/astscript-psf-stamp.1 man/astscript-psf-subtract.1 \
-  man/astscript-psf-unite.1 man/astscript-radial-profile.1 \
-  man/astscript-sort-by-night.1 man/astscript-zeropoint.1
+
+dist_man_MANS = $(MAYBE_ARITHMETIC_MAN) \
+  $(MAYBE_BUILDPROG_MAN) \
+  $(MAYBE_CONVERTT_MAN) \
+  $(MAYBE_CONVOLVE_MAN) \
+  $(MAYBE_COSMICCAL_MAN) \
+  $(MAYBE_CROP_MAN) \
+  $(MAYBE_FITS_MAN) \
+  $(MAYBE_MATCH_MAN) \
+  $(MAYBE_MKCATALOG_MAN) \
+  $(MAYBE_MKNOISE_MAN) \
+  $(MAYBE_MKPROF_MAN) \
+  $(MAYBE_NOISECHISEL_MAN) \
+  $(MAYBE_QUERY_MAN) \
+  $(MAYBE_SEGMENT_MAN) \
+  $(MAYBE_STATISTICS_MAN) \
+  $(MAYBE_TABLE_MAN) \
+  $(MAYBE_WARP_MAN) \
+  man/astscript-dither-simulate.1 \
+  man/astscript-ds9-region.1 \
+  man/astscript-fits-view.1 \
+  man/astscript-psf-scale-factor.1 \
+  man/astscript-psf-select-stars.1 \
+  man/astscript-psf-stamp.1 \
+  man/astscript-psf-subtract.1 \
+  man/astscript-psf-unite.1 \
+  man/astscript-radial-profile.1 \
+  man/astscript-sort-by-night.1 \
+  man/astscript-zeropoint.1
 
 
 ## See if help2man is present or not. When help2man doesn't exist, we don't
@@ -253,52 +272,57 @@ man/astwarp.1: $(top_srcdir)/bin/warp/args.h  
$(ALLMANSDEP)
 
 
 # The Scripts:
-man/astscript-ds9-region.1: $(top_srcdir)/bin/script/ds9-region.in   \
+man/astscript-dither-simulate.1: $(top_srcdir)/bin/script/dither-simulate.sh   
\
+                            $(ALLMANSDEP)
+       $(MAYBE_HELP2MAN) -n "Simulate the exposure map of a dither pattern" \
+                         --libtool 
$(toputildir)/script/astscript-dither-simulate
+
+man/astscript-ds9-region.1: $(top_srcdir)/bin/script/ds9-region.sh   \
                             $(ALLMANSDEP)
        $(MAYBE_HELP2MAN) -n "Create an SAO DS9 region file from a table" \
                          --libtool $(toputildir)/script/astscript-ds9-region
 
-man/astscript-fits-view.1: $(top_srcdir)/bin/script/fits-view.in   \
+man/astscript-fits-view.1: $(top_srcdir)/bin/script/fits-view.sh   \
                             $(ALLMANSDEP)
        $(MAYBE_HELP2MAN) -n "View FITS images in DS9 and tables in TOPCAT 
based on contents" \
                          --libtool $(toputildir)/script/astscript-fits-view
 
-man/astscript-psf-scale-factor.1: $(top_srcdir)/bin/script/psf-scale-factor.in 
\
+man/astscript-psf-scale-factor.1: $(top_srcdir)/bin/script/psf-scale-factor.sh 
\
                                   $(ALLMANSDEP)
        $(MAYBE_HELP2MAN) -n "Find factor to scale PSF to a given star in an 
image" \
                          --libtool 
$(toputildir)/script/astscript-psf-scale-factor
 
-man/astscript-psf-select-stars.1: $(top_srcdir)/bin/script/psf-select-stars.in 
\
+man/astscript-psf-select-stars.1: $(top_srcdir)/bin/script/psf-select-stars.sh 
\
                                   $(ALLMANSDEP)
        $(MAYBE_HELP2MAN) -n "Select good stars for constructing the PSF" \
                          --libtool 
$(toputildir)/script/astscript-psf-select-stars
 
-man/astscript-psf-stamp.1: $(top_srcdir)/bin/script/psf-stamp.in \
+man/astscript-psf-stamp.1: $(top_srcdir)/bin/script/psf-stamp.sh \
                            $(ALLMANSDEP)
        $(MAYBE_HELP2MAN) -n "Make normalized stamp of star with background 
objects masked" \
                          --libtool $(toputildir)/script/astscript-psf-stamp
 
-man/astscript-psf-subtract.1: $(top_srcdir)/bin/script/psf-subtract.in \
+man/astscript-psf-subtract.1: $(top_srcdir)/bin/script/psf-subtract.sh \
                               $(ALLMANSDEP)
        $(MAYBE_HELP2MAN) -n "Subtract a given PSF model from the image of 
star" \
                          --libtool $(toputildir)/script/astscript-psf-subtract
 
-man/astscript-psf-unite.1: $(top_srcdir)/bin/script/psf-unite.in \
+man/astscript-psf-unite.1: $(top_srcdir)/bin/script/psf-unite.sh \
                            $(ALLMANSDEP)
        $(MAYBE_HELP2MAN) -n "Unite the outer and inner regions of the PSF into 
one" \
                          --libtool $(toputildir)/script/astscript-psf-unite
 
-man/astscript-radial-profile.1: $(top_srcdir)/bin/script/radial-profile.in   \
+man/astscript-radial-profile.1: $(top_srcdir)/bin/script/radial-profile.sh   \
                                 $(ALLMANSDEP)
        $(MAYBE_HELP2MAN) -n "Create a radial profile of an object in an image" 
\
                          --libtool 
$(toputildir)/script/astscript-radial-profile
 
-man/astscript-sort-by-night.1: $(top_srcdir)/bin/script/sort-by-night.in   \
+man/astscript-sort-by-night.1: $(top_srcdir)/bin/script/sort-by-night.sh   \
                                $(ALLMANSDEP)
        $(MAYBE_HELP2MAN) -n "Sort input FITS files by night"              \
                          --libtool $(toputildir)/script/astscript-sort-by-night
 
-man/astscript-zeropoint.1: $(top_srcdir)/bin/script/zeropoint.in   \
+man/astscript-zeropoint.1: $(top_srcdir)/bin/script/zeropoint.sh   \
                            $(ALLMANSDEP)
        $(MAYBE_HELP2MAN) -n "Estimate zero point of an image" \
                          --libtool $(toputildir)/script/astscript-zeropoint



reply via email to

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