mirror of
https://github.com/docker-mailserver/docker-mailserver.git
synced 2024-01-19 02:48:50 +00:00
removed Darwin specific code and modified the docs to indicate macOS is not supported
This commit is contained in:
parent
d101d0aa0a
commit
54e41d04f7
|
@ -5,13 +5,9 @@ title: 'Contributing | Tests'
|
||||||
1. Install docker
|
1. Install docker
|
||||||
2. Execute `git submodule update --init --recursive`
|
2. Execute `git submodule update --init --recursive`
|
||||||
3. Install jq
|
3. Install jq
|
||||||
|
|
||||||
!!! info "MacOS Specific (needed for tests)"
|
|
||||||
|
|
||||||
```bash
|
|
||||||
brew install coreutils
|
|
||||||
# bash >= 4.0 for associative arrays
|
|
||||||
brew install bash
|
|
||||||
```
|
|
||||||
|
|
||||||
4. Execute `make clean all`
|
4. Execute `make clean all`
|
||||||
|
|
||||||
|
|
||||||
|
!!! info "Can I use MacOS?"
|
||||||
|
|
||||||
|
We do not support running linting, tests, etc on macOS at this time. Please use a linux VM.
|
8
setup.sh
8
setup.sh
|
@ -88,14 +88,6 @@ function _show_local_usage
|
||||||
|
|
||||||
function _get_absolute_script_directory
|
function _get_absolute_script_directory
|
||||||
{
|
{
|
||||||
if [[ "$(uname)" == 'Darwin' ]]
|
|
||||||
then
|
|
||||||
readlink() {
|
|
||||||
# requires coreutils
|
|
||||||
greadlink "${@:+$@}"
|
|
||||||
}
|
|
||||||
fi
|
|
||||||
|
|
||||||
if dirname "$(readlink -f "${0}")" &>/dev/null
|
if dirname "$(readlink -f "${0}")" &>/dev/null
|
||||||
then
|
then
|
||||||
DIR="$(dirname "$(readlink -f "${0}")")"
|
DIR="$(dirname "$(readlink -f "${0}")")"
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#! /usr/bin/env bash
|
#! /bin/bash
|
||||||
|
|
||||||
# version v0.2.0 unstable
|
# version v0.2.0 unstable
|
||||||
# executed by Make during CI or manually
|
# executed by Make during CI or manually
|
||||||
|
@ -6,12 +6,6 @@
|
||||||
|
|
||||||
SCRIPT="lint.sh"
|
SCRIPT="lint.sh"
|
||||||
|
|
||||||
if [[ "$(uname)" == "Darwin" ]]
|
|
||||||
then
|
|
||||||
readlink() {
|
|
||||||
greadlink "${@:+$@}" # Requires coreutils
|
|
||||||
}
|
|
||||||
fi
|
|
||||||
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
|
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
|
||||||
REPO_ROOT="$(realpath "${SCRIPT_DIR}"/../../)"
|
REPO_ROOT="$(realpath "${SCRIPT_DIR}"/../../)"
|
||||||
|
|
||||||
|
@ -104,10 +98,8 @@ function _shellcheck
|
||||||
-not -path './test/test_helper/*' \
|
-not -path './test/test_helper/*' \
|
||||||
-not -path './target/docker-configomat/*'
|
-not -path './target/docker-configomat/*'
|
||||||
)"
|
)"
|
||||||
# macOS lacks parity for `-executable` but presently produces the same results: https://stackoverflow.com/a/4458361
|
|
||||||
[[ "$(uname)" == "Darwin" ]] && FIND_EXEC="-perm -711" || FIND_EXEC="-executable"
|
|
||||||
# shellcheck disable=SC2248
|
# shellcheck disable=SC2248
|
||||||
F_BIN="$(find 'target/bin' ${FIND_EXEC} -type f)"
|
F_BIN="$(find 'target/bin' -executable -type f)"
|
||||||
F_BATS="$(find 'test' -maxdepth 1 -type f -iname '*.bats')"
|
F_BATS="$(find 'test' -maxdepth 1 -type f -iname '*.bats')"
|
||||||
|
|
||||||
# This command is a bit easier to grok as multi-line.
|
# This command is a bit easier to grok as multi-line.
|
||||||
|
|
Loading…
Reference in a new issue