Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
tianlh
LightGBM-DCU
Commits
b33f412c
Unverified
Commit
b33f412c
authored
Jul 29, 2024
by
Nikita Titov
Committed by
GitHub
Jul 29, 2024
Browse files
[ci] fix MSVC warning about builds in temp directory (#6573)
parent
9f07fbeb
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
1 deletion
+7
-1
.ci/test_r_package_windows.ps1
.ci/test_r_package_windows.ps1
+0
-1
.ci/test_windows.ps1
.ci/test_windows.ps1
+7
-0
No files found.
.ci/test_r_package_windows.ps1
View file @
b33f412c
...
@@ -195,7 +195,6 @@ if ($env:COMPILER -ne "MSVC") {
...
@@ -195,7 +195,6 @@ if ($env:COMPILER -ne "MSVC") {
}
}
}
else
{
}
else
{
$
env
:
TMPDIR
=
$
env
:
USERPROFILE
# to avoid warnings about incremental builds inside a temp directory
$INSTALL_LOG_FILE_NAME
=
"
$
env
:
BUILD_SOURCESDIRECTORY
\00install_out.txt"
$INSTALL_LOG_FILE_NAME
=
"
$
env
:
BUILD_SOURCESDIRECTORY
\00install_out.txt"
Run-R-Code-Redirect-Stderr
"source('build_r.R')"
1
>
$INSTALL_LOG_FILE_NAME
;
$install_succeeded
=
$?
Run-R-Code-Redirect-Stderr
"source('build_r.R')"
1
>
$INSTALL_LOG_FILE_NAME
;
$install_succeeded
=
$?
Write-Output
"----- build and install logs -----"
Write-Output
"----- build and install logs -----"
...
...
.ci/test_windows.ps1
View file @
b33f412c
...
@@ -8,6 +8,13 @@ function Check-Output {
...
@@ -8,6 +8,13 @@ function Check-Output {
$
env
:
CONDA_ENV
=
"test-env"
$
env
:
CONDA_ENV
=
"test-env"
$
env
:
LGB_VER
=
(
Get-Content
$
env
:
BUILD_SOURCESDIRECTORY
\VERSION.txt
)
.
trim
()
$
env
:
LGB_VER
=
(
Get-Content
$
env
:
BUILD_SOURCESDIRECTORY
\VERSION.txt
)
.
trim
()
# Use custom temp directory to avoid
# > warning MSB8029: The Intermediate directory or Output directory cannot reside under the Temporary directory
# > as it could lead to issues with incremental build.
# And make sure this directory is always clean
$
env
:
TMPDIR
=
"
$
env
:
USERPROFILE
\tmp"
Remove-Item
$
env
:
TMPDIR
-Force
-Recurse
-ErrorAction
Ignore
[
Void
][
System.IO.Directory
]::
CreateDirectory
(
$
env
:
TMPDIR
)
if
(
$
env
:
TASK
-eq
"r-package"
)
{
if
(
$
env
:
TASK
-eq
"r-package"
)
{
&
.
\.ci\test_r_package_windows.ps1
;
Check-Output
$?
&
.
\.ci\test_r_package_windows.ps1
;
Check-Output
$?
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment