From 6ea0d82e216f7adb955c143e1c35abb9a935b670 Mon Sep 17 00:00:00 2001 From: Ruben De Smet Date: Tue, 28 Feb 2017 13:22:38 +0100 Subject: [PATCH] Enable Rust on Appveyor CI --- .ci/appveyor.yml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/.ci/appveyor.yml b/.ci/appveyor.yml index c075afbe5a..51f2b187e2 100644 --- a/.ci/appveyor.yml +++ b/.ci/appveyor.yml @@ -4,6 +4,7 @@ environment: # /E:ON and /V:ON options are not enabled in the batch script intepreter # See: http://stackoverflow.com/a/13751649/163740 CMD_IN_ENV: "cmd /E:ON /V:ON /C .\\.ci\\run_with_env.cmd" + RUST_TOOLCHAIN: "nightly-2017-07-20-x86_64-pc-windows-msvc" matrix: - PYTHON: "C:\\Python34" @@ -20,6 +21,13 @@ cache: - "C:\\Users\\appveyor\\AppData\\Local\\coala-bears\\coala-bears" - "C:\\Users\\appveyor\\AppData\\Roaming\\nltk_data" +# Workaround Appveyor bug: +# http://help.appveyor.com/discussions/problems/7115-curl-cant-download-files-through-ssl +init: + - ps: > + Disable-NetFirewallRule + -DisplayName 'Core Networking - Group Policy (LSASS-Out)' + branches: except: - /^sils\/.*/ @@ -49,6 +57,26 @@ install: - "npm config set loglevel warn" - "npm install" + - "curl -sSf -o rustup-init.exe https://win.rustup.rs/" + - "rustup-init.exe -y --default-toolchain=%RUST_TOOLCHAIN%" + # Normally, we shouldn't need the toolchain lib directory in our PATH + # https://github.com/rust-lang-nursery/rustup.rs/issues/876 + # This is actually the sole reason that we really + # need the RUST_TOOLCHAIN variable. + - "set PATH=%PATH%;C:\\Users\\appveyor\\.cargo\\bin" + # Start ignoring YAMLLintBear + # because of the line length; plitting up these paths would become unreadable + - "set PATH=%PATH%;C:\\Users\\appveyor\\.rustup\\toolchains\\%RUST_TOOLCHAIN%\\bin" + - "set PATH=%PATH%;C:\\Users\\appveyor\\.rustup\\toolchains\\%RUST_TOOLCHAIN%\\lib\\rustlib\\x86_64-pc-windows-msvc\\lib" + # Stop ignoring YAMLLintBear + - "cargo install clippy --vers 0.0.144" + + # Print rust and cargo parameters for quick debugging. + - where rustc cargo + - rustc -vV + - cargo -vV + - cargo clippy -V + build: false # Not a C# project, build stuff at the test step instead. test_script: