diff --git a/.gitignore b/.gitignore index 430cf609..2bf50090 100644 --- a/.gitignore +++ b/.gitignore @@ -10,3 +10,4 @@ npm-debug.log _gh_pages _site node_modules +test/output/ diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 00000000..5c64a5a6 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,6 @@ +script: + - "test/sass-compile-tester.sh" + +language: sass +before_install: + - gem install sass \ No newline at end of file diff --git a/test/sass-compile-tester.sh b/test/sass-compile-tester.sh new file mode 100755 index 00000000..82450d59 --- /dev/null +++ b/test/sass-compile-tester.sh @@ -0,0 +1,47 @@ +#!/bin/bash + + + +# ============================================================================== +# FUNCTIONS - START +# ============================================================================== + +run_it() +{ + + local _src="${1-bulma.sass}" + local _dest="${2-$(dirname "${BASH_SOURCE[0]}")/output/$(basename ${_src}).css}" + local _options="${3---sourcemap=none}" + + # ---------------------------------------------------------------------------- + + local _dest_dir="$(dirname "${_dest}")" + + if [ ! -d "${_dest_dir}" ]; then + + mkdir -p "${_dest_dir}" + + fi + + # ---------------------------------------------------------------------------- + + sass "${_src}" "${_dest}" ${_options} + +} +# run_it() + +# ============================================================================== +# FUNCTIONS - END +# ============================================================================== + + + +# ============================================================================== +# EXECUTION - START +# ============================================================================== + +run_it $@ + +# ============================================================================== +# EXECUTION - END +# ==============================================================================