File tree 3 files changed +15
-14
lines changed
3 files changed +15
-14
lines changed Original file line number Diff line number Diff line change 2
2
3
3
set -ex
4
4
5
+ sysroot=" $( rustc --print sysroot) "
6
+ case $OS in
7
+ Linux) export LD_LIBRARY_PATH=" $sysroot /lib" ;;
8
+ macOS) export DYLD_FALLBACK_LIBRARY_PATH=" $sysroot /lib" ;;
9
+ Windows) export PATH=" $( cygpath " $sysroot " ) /bin:$PATH " ;;
10
+ * ) exit 1
11
+ esac
12
+
5
13
# Check sysroot handling
6
- sysroot=$( ./target/debug/clippy-driver --print sysroot)
7
- test " $sysroot " = " $( rustc --print sysroot) "
8
-
9
- if [[ ${OS} == " Windows" ]]; then
10
- desired_sysroot=C:/tmp
11
- else
12
- desired_sysroot=/tmp
13
- fi
14
+ test " $( ./target/debug/clippy-driver --print sysroot) " = " $sysroot "
15
+
16
+ desired_sysroot=" target/sysroot"
14
17
# Set --sysroot in command line
15
18
sysroot=$( ./target/debug/clippy-driver --sysroot $desired_sysroot --print sysroot)
16
19
test " $sysroot " = $desired_sysroot
Original file line number Diff line number Diff line change 69
69
working-directory : clippy_dev
70
70
71
71
- name : Test clippy-driver
72
- run : |
73
- TOOLCHAIN=$(rustup show active-toolchain | cut -f1 -d' ')
74
- rustup run $TOOLCHAIN bash .github/driver.sh
72
+ run : .github/driver.sh
73
+ env :
74
+ OS : ${{ runner.os }}
Original file line number Diff line number Diff line change @@ -116,9 +116,7 @@ jobs:
116
116
working-directory : clippy_dev
117
117
118
118
- name : Test clippy-driver
119
- run : |
120
- TOOLCHAIN=$(rustup show active-toolchain | cut -f1 -d' ')
121
- rustup run $TOOLCHAIN bash .github/driver.sh
119
+ run : .github/driver.sh
122
120
env :
123
121
OS : ${{ runner.os }}
124
122
You can’t perform that action at this time.
0 commit comments