appveyor.yml 1.47 KB
Newer Older
Guolin Ke's avatar
Guolin Ke committed
1
2
3
4
5
6
7
8
9
10
11
12
13

version: 1.0.{build}
environment:
  matrix:
    - PYTHON: "C:/Python36-x64"
      PYTHON_VERSION: 3.6
      MINICONDA: "C:/Miniconda36-x64"

clone_depth: 50

init:
  - "ECHO %PYTHON_VERSION% %MINICONDA%"

Guolin Ke's avatar
Guolin Ke committed
14
15
build_script:
  - mkdir build && cd build
Guolin Ke's avatar
Guolin Ke committed
16
  - cmake -DCMAKE_GENERATOR_PLATFORM=x64 .. && cmake --build . --target ALL_BUILD --config Release
Guolin Ke's avatar
Guolin Ke committed
17
18
19
  - cd ..

test_script:
Guolin Ke's avatar
Guolin Ke committed
20
21
22
23
  - "set PATH=%MINICONDA%;%MINICONDA%/Scripts;%PATH%"
  - conda config --set always_yes yes --set changeps1 no
  - conda update -q conda
  - conda info -a
24
  - conda install --yes numpy nose scipy scikit-learn pandas matplotlib
Guolin Ke's avatar
Guolin Ke committed
25
  - pip install pep8 pytest
26
  - pytest tests/c_api_test/test_.py
Guolin Ke's avatar
Guolin Ke committed
27
28
29
30
31
32
  - "set /p LGB_VER=< VERSION.txt"
  - cd python-package && python setup.py sdist --formats gztar
  - cd dist 
  - "pip install lightgbm-%LGB_VER%.tar.gz -v"
  - cd ../..
  - pytest tests/python_package_test
Guolin Ke's avatar
Guolin Ke committed
33
34
35
36
  - cd python-package && python setup.py bdist_wheel --plat-name=win-amd64 --universal
  - cd ../.nuget
  - python create_nuget.py
  - nuget.exe pack LightGBM.nuspec
Guolin Ke's avatar
Guolin Ke committed
37
38
39

nuget:
  project_feed: true
Guolin Ke's avatar
Guolin Ke committed
40

Guolin Ke's avatar
Guolin Ke committed
41
42
43
artifacts:
- path: Release/lib_lightgbm.dll
  name: Library
Guolin Ke's avatar
Guolin Ke committed
44
45
- path: Release/lightgbm.exe
  name: Exe
Guolin Ke's avatar
Guolin Ke committed
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
- path: python-package/dist/*
  name: Pip
- path: .nuget/*.nupkg
  name: Nuget

deploy:
  release: $(APPVEYOR_REPO_TAG_NAME)
  provider: GitHub
  auth_token:
    secure: KR44XwtxY0cLlVpQwY726BvC6gzT0cYTf0ahJ4cSvvS0UVoSJxkR900ICfVXHRoT
  artifact: Library,Exe,Pip,Nuget
  force_update: true
  draft: true
  on:
    appveyor_repo_tag: true