Skip to content

Commit

Permalink
Merge pull request #676 from johnmcfarlane/fix-conan-profile-in-deplo…
Browse files Browse the repository at this point in the history
…y.sh

Fix Conan profile in deploy script
  • Loading branch information
johnmcfarlane committed Dec 27, 2020
2 parents ae38c7d + 1d0ee4c commit 4d44556
Show file tree
Hide file tree
Showing 14 changed files with 39 additions and 32 deletions.
4 changes: 2 additions & 2 deletions .github/deploy.sh → .github/deploy
Expand Up @@ -22,7 +22,7 @@ else
fi

# Generate documentation
"${PROJECT_DIR}/doc/generate.sh"
"${PROJECT_DIR}/doc/generate"

# Push revision of documentation
pushd "${PROJECT_DIR}/doc/gh-pages"
Expand All @@ -39,7 +39,7 @@ fi
popd

# Upload new version of CNL Conan package to Bintray
conan remote add --force johnmcfarlane/cnl https://api.bintray.com/conan/johnmcfarlane/cnl
"${PROJECT_DIR}/test/scripts/conan-setup"
conan user -p "${CONAN_PASS}" -r johnmcfarlane/cnl "${CONAN_USER}"
conan install --build=missing "${PROJECT_DIR}"
conan create "${PROJECT_DIR}" "cnl/${CNL_VERSION}@johnmcfarlane/development"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Expand Up @@ -22,4 +22,4 @@ jobs:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
CONAN_PASS: ${{secrets.BINTRAY_API_KEY}}
CONAN_USER: ${{secrets.BINTRAY_USERNAME}}
run: CNL_VERSION_TAG=$GITHUB_REF $GITHUB_WORKSPACE/.github/deploy.sh
run: CNL_VERSION_TAG=$GITHUB_REF $GITHUB_WORKSPACE/.github/deploy
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Expand Up @@ -331,7 +331,7 @@ jobs:

- name: Run All Tests
shell: bash
run: $GITHUB_WORKSPACE/test/scripts/shellcheck.sh
run: $GITHUB_WORKSPACE/test/scripts/shellcheck

# Test documentation generation
doxygen:
Expand All @@ -345,7 +345,7 @@ jobs:

- name: Generate documentation
shell: bash
run: $GITHUB_WORKSPACE/doc/generate.sh
run: $GITHUB_WORKSPACE/doc/generate

- name: Upload documentation
uses: actions/upload-artifact@v2
Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion test/scripts/clang-tidy.sh → test/scripts/clang-tidy
Expand Up @@ -10,6 +10,6 @@ PROJECT_DIR=$(
pwd
)

"${PROJECT_DIR}/test/scripts/test.sh" \
"${PROJECT_DIR}/test/scripts/test" \
--env CONAN_CMAKE_TOOLCHAIN_FILE="${PROJECT_DIR}/test/cmake/toolchain/clang-tidy-libc++.cmake" \
--env CXX=clang++
File renamed without changes.
Expand Up @@ -9,7 +9,7 @@ PROJECT_DIR=$(
pwd
)

"${PROJECT_DIR}/test/scripts/test.sh" \
"${PROJECT_DIR}/test/scripts/test" \
--env CONAN_CMAKE_TOOLCHAIN_FILE="${PROJECT_DIR}/test/cmake/toolchain/clang.cmake" \
--env CXX=clang++ \
--env LSAN_OPTIONS=verbosity=1:log_threads=1 \
Expand Down
2 changes: 1 addition & 1 deletion test/scripts/sanitize-gcc.sh → test/scripts/sanitize-gcc
Expand Up @@ -9,7 +9,7 @@ PROJECT_DIR=$(
pwd
)

"${PROJECT_DIR}/test/scripts/test.sh" \
"${PROJECT_DIR}/test/scripts/test" \
--env CONAN_CMAKE_TOOLCHAIN_FILE="${PROJECT_DIR}/test/cmake/toolchain/gcc.cmake" \
--env CXX=g++ \
--env LSAN_OPTIONS=verbosity=1:log_threads=1 \
Expand Down
29 changes: 29 additions & 0 deletions test/scripts/shellcheck
@@ -0,0 +1,29 @@
#!/usr/bin/env bash

# Configure, build and run ShellCheck shell script linter over all scripts in project directory

set -euo pipefail

PROJECT_DIR=$(
cd "$(dirname "$0")"/../..
pwd
)

cd "${PROJECT_DIR}"

git ls-files | while read -r file
do
if [[ -f "$file" && -x "$file" && "$(head --lines 1 "$file")" == "#!/usr/bin/env bash" ]]
then
shellcheck \
--check-sourced \
--color=always \
--external-sources \
--severity=info \
--shell=bash \
"$file"
printf "OK: %s\n" "$file"
fi
done

echo shellcheck success
22 changes: 0 additions & 22 deletions test/scripts/shellcheck.sh

This file was deleted.

File renamed without changes.
2 changes: 1 addition & 1 deletion test/scripts/test-all.sh → test/scripts/test-all
Expand Up @@ -9,5 +9,5 @@ PROJECT_DIR=$(
pwd
)

"${PROJECT_DIR}"/test/scripts/test.sh \
"${PROJECT_DIR}"/test/scripts/test \
--options target=test-all
2 changes: 1 addition & 1 deletion test/scripts/unit-test.sh → test/scripts/unit-test
Expand Up @@ -9,5 +9,5 @@ PROJECT_DIR=$(
pwd
)

"${PROJECT_DIR}/test/scripts/test.sh" \
"${PROJECT_DIR}/test/scripts/test" \
--options target=test-unit

0 comments on commit 4d44556

Please sign in to comment.