Applies some best practices to bash scripts
This commit is contained in:
parent
052fc8e94d
commit
e548819388
@ -1,7 +1,8 @@
|
||||
#!/bin/bash
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# Installs selected content from the downloaded repos into a production folder
|
||||
#
|
||||
# Warning: git apply may fail if /opt/odoo/.git/ exists
|
||||
|
||||
if [ $UID != 0 ]; then
|
||||
echo "You need administration privileges to run this script."
|
||||
@ -119,6 +120,7 @@ pt_all ()
|
||||
pt_community # Apply patches to OCA modules
|
||||
}
|
||||
|
||||
set -ueo pipefail
|
||||
if (($# == 0))
|
||||
then
|
||||
Help
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
#!/bin/bash
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# Installs selected content from the downloaded repos into a production folder
|
||||
#
|
||||
@ -137,6 +137,7 @@ cp_all ()
|
||||
cp_custom # Install Custom modules
|
||||
}
|
||||
|
||||
set -ueo pipefail
|
||||
if (($# == 0))
|
||||
then
|
||||
Help
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
#!/bin/bash
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# Updates code from the git repositories selected
|
||||
#
|
||||
@ -150,6 +150,7 @@ gt_all ()
|
||||
gt_custom # Custom in-house modules
|
||||
}
|
||||
|
||||
set -ueo pipefail
|
||||
if (($# == 0))
|
||||
then
|
||||
Help
|
||||
|
||||
Loading…
Reference in New Issue
Block a user