Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
PyWake
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TOPFARM
PyWake
Commits
c2122122
Commit
c2122122
authored
2 years ago
by
Neil Davis
Committed by
Mads M. Pedersen
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Resolve "Build conda package for PyWake to support integration with PyWAsP"
parent
20ded352
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.gitlab-ci.yml
+46
-6
46 additions, 6 deletions
.gitlab-ci.yml
recipe/meta.yaml
+34
-0
34 additions, 0 deletions
recipe/meta.yaml
setup.py
+1
-0
1 addition, 0 deletions
setup.py
with
81 additions
and
6 deletions
.gitlab-ci.yml
+
46
−
6
View file @
c2122122
...
...
@@ -3,6 +3,7 @@ image: continuumio/anaconda3
stages
:
-
test
-
test_plugins
-
build
-
deploy
# ===== TEST PyWake debian=====
...
...
@@ -22,7 +23,7 @@ test_PyWake: # name the job what we like
# stage: # build, test, deploy defined by default [2]
# test
# script:
# - apt update
# - apt update
# - apt install libgl1-mesa-glx -y
# - python -m pip install --upgrade --force-reinstall pip
# - pip install tensorflow --user
...
...
@@ -33,7 +34,7 @@ test_PyWake: # name the job what we like
# - ci-ubuntu
# ===== Check code style =====
check_code_style
:
# name the job what we like
stage
:
# build, test, deploy defined by default [2]
...
...
@@ -128,7 +129,7 @@ pages: # "pages" is a job specifically for GitLab pages [1]
pypi_linux
:
stage
:
stage
:
deploy
only
:
-
tags
...
...
@@ -146,12 +147,51 @@ pypi_linux:
-
python -c 'from git_utils import rename_dist_file; rename_dist_file()'
-
twine upload dist/* -u $TWINE_USERNAME -p $TWINE_PASSWORD
#- twine upload --repository-url https://test.pypi.org/legacy/ dist/* -u $TWINE_USERNAME -p $TWINE_PASSWORD # for testing purposes
tags
:
tags
:
-
ci-ubuntu
build_conda
:
stage
:
build
image
:
condaforge/mambaforge:latest
dependencies
:
[]
script
:
-
export VERSION=`git describe --tags --always | sed 's/v//' | sed 's/-/.dev/' | sed 's/-/_/'`
-
mamba install -c conda-forge --override-channels -y boa conda-verify
-
conda mambabuild --no-anaconda-upload -c conda-forge --override-channels --output-folder ./conda_channel ./recipe
artifacts
:
untracked
:
false
expire_in
:
"
3
days"
paths
:
[
"
conda_channel/noarch/py_wake*.tar.bz2"
]
rules
:
-
if
:
$CI_COMMIT_TAG && $CI_COMMIT_REF_PROTECTED
-
if
:
$CI_PIPELINE_SOURCE == "merge_request_event"
when
:
manual
allow_failure
:
true
changes
:
-
setup.py
-
recipe/meta.yaml
-
when
:
never
tags
:
-
ci-ubuntu
deploy_conda
:
stage
:
deploy
image
:
docker:latest
dependencies
:
[
"
build_conda"
]
needs
:
[
"
build_conda"
]
script
:
-
CONDA_PKG=`basename ./conda_channel/noarch/py_wake*.tar.bz2`
-
cp -p ./conda_channel/noarch/$CONDA_PKG /conda_channel_open/noarch/${CONDA_PKG}.tmp
-
chown 1000:1000 /conda_channel_open/noarch/${CONDA_PKG}.tmp
-
mv /conda_channel_open/noarch/${CONDA_PKG}.tmp /conda_channel_open/noarch/${CONDA_PKG}
rules
:
-
if
:
$CI_COMMIT_TAG && $CI_COMMIT_REF_PROTECTED
tags
:
-
conda_channel
# current
# pypi_windows:
# stage:
# stage:
# deploy
# only:
# - tags
...
...
@@ -160,6 +200,6 @@ pypi_linux:
# - c:/Anaconda3/envs/pyTopfarm/python.exe setup.py bdist_wheel
# - twine upload dist/* -u %TWINE_USERNAME% -p %TWINE_PASSWORD%
# #- twine upload --repository-url https://test.pypi.org/legacy/ dist/* -u %TWINE_USERNAME% -p %TWINE_PASSWORD% # for testing purposes
# tags:
# tags:
# - CPAV_old_PC
This diff is collapsed.
Click to expand it.
recipe/meta.yaml
0 → 100644
+
34
−
0
View file @
c2122122
package
:
name
:
py_wake
version
:
{{
environ.get('VERSION'
,
'
0.0.0'
)
}}
# does not work anymore not sure why
source
:
path
:
../
build
:
number
:
0
script
:
pip install --no-deps .
skip
:
True
# [py<37]
noarch
:
python
requirements
:
# If adding new requirements be sure to also add to setup.py
run
:
-
autograd
-
h5netcdf
-
matplotlib
-
netcdf4
-
numpy
-
python
-
pyyaml
-
scipy
-
scikit-learn
# loads
-
tensorflow
# loads
-
tqdm
-
xarray
host
:
-
python
-
setuptools
test
:
imports
:
-
py_wake
\ No newline at end of file
This diff is collapsed.
Click to expand it.
setup.py
+
1
−
0
View file @
c2122122
...
...
@@ -53,6 +53,7 @@ setup(name='py_wake',
'
rotor_avg_models/gaussian_overlap_.02_.02_128_512.nc
'
],
},
# When adding extra requirements be sure to update recipe/meta.yaml
install_requires
=
[
'
matplotlib
'
,
# for plotting
'
numpy
'
,
# for numerical calculations
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment