Add astyle to Circle CI build.

This commit is contained in:
iphydf 2018-01-19 22:39:42 +00:00
parent 656040027d
commit da4ba1731a
No known key found for this signature in database
GPG Key ID: 3855DBA2D74403C9

View File

@ -12,6 +12,7 @@ machine:
dependencies: dependencies:
pre: pre:
- sudo apt-get update - sudo apt-get update
- sudo apt-get install astyle
- sudo apt-get install clang - sudo apt-get install clang
- sudo apt-get install build-essential libtool autotools-dev automake checkinstall check git yasm - sudo apt-get install build-essential libtool autotools-dev automake checkinstall check git yasm
- sudo apt-get install libopus-dev libvpx-dev pkg-config - sudo apt-get install libopus-dev libvpx-dev pkg-config
@ -25,9 +26,20 @@ dependencies:
- java -version ; exit 0 - java -version ; exit 0
- gcc --version ; exit 0 - gcc --version ; exit 0
- clang --version ; exit 0 - clang --version ; exit 0
- astyle --version ; exit 0
compile: compile:
override: override:
### ----- check code style ------
- cd .. ; cp -av c-toxcore ./astyle_check/
- cd ../astyle_check/ ; ls -al other/astyle/astylerc
- cd ../astyle_check/ ;
SOURCES=`find . -name "*.[ch]" -and -not -name "*.api.h" -and -not -wholename "*crypto_pwhash*" -and -not -wholename "./super_donators/*"|sort`;
astyle -n --options=other/astyle/astylerc $SOURCES ; exit 0
- cd ../astyle_check/ ; git --no-pager diff
- cd ../astyle_check/ ; git diff | cat > $CIRCLE_ARTIFACTS/astyle_check.patch 2>&1
### ----- check code style ------
### ------- get libsodium ------- ### ------- get libsodium -------
- mkdir ~/libsodium - mkdir ~/libsodium
- cd ~/libsodium/ ; git clone https://github.com/jedisct1/libsodium.git - cd ~/libsodium/ ; git clone https://github.com/jedisct1/libsodium.git