Browse Source

Install command to do static analysis on bash scripts

Bob Mottram 7 years ago
parent
commit
6a9bd38440
2 changed files with 9 additions and 0 deletions
  1. 1
    0
      src/freedombone-image-customise
  2. 8
    0
      src/freedombone-utils-setup

+ 1
- 0
src/freedombone-image-customise View File

@@ -1699,6 +1699,7 @@ function image_setup_utils {
1699 1699
     chroot "$rootdir" apt-get -yq dist-upgrade
1700 1700
     chroot "$rootdir" apt-get -yq install ca-certificates
1701 1701
     chroot "$rootdir" apt-get -yq install apt-utils
1702
+    chroot "$rootdir" apt-get -yq install shellcheck
1702 1703
 
1703 1704
     if [[ $ARCHITECTURE == 'amd64' ]]; then
1704 1705
         chroot "$rootdir" apt-get -yq install linux-image-amd64

+ 8
- 0
src/freedombone-utils-setup View File

@@ -787,6 +787,11 @@ function congestion_control {
787 787
     fi
788 788
 }
789 789
 
790
+function install_shellcheck {
791
+    # Used by the tests command
792
+    apt-get -yq install shellcheck
793
+}
794
+
790 795
 function setup_utils {
791 796
     read_config_param "PROJECT_REPO"
792 797
     write_config_param "PROJECT_REPO" "$PROJECT_REPO"
@@ -1006,6 +1011,9 @@ function setup_utils {
1006 1011
 
1007 1012
     function_check setup_powerline
1008 1013
     setup_powerline
1014
+
1015
+    function_check install_shellcheck
1016
+    install_shellcheck
1009 1017
 }
1010 1018
 
1011 1019
 function setup_email {