Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
D
dtu-10mw-rwt
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
Admin message
The Gitlab server is succesfully updated to version 17.9.2
Show more breadcrumbs
HAWC Reference Models
dtu-10mw-rwt
Commits
7e7af9de
Commit
7e7af9de
authored
4 years ago
by
Jenni Rinker
Browse files
Options
Downloads
Patches
Plain Diff
put tag name in zip name
parent
751926ae
No related branches found
No related tags found
1 merge request
!4
Merge debugging changes in make_zip back into develop
Pipeline
#15305
failed
4 years ago
Stage: test
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
.gitlab-ci.yml
+1
-1
1 addition, 1 deletion
.gitlab-ci.yml
utils/prepare_zip_file.py
+12
-9
12 additions, 9 deletions
utils/prepare_zip_file.py
with
13 additions
and
10 deletions
.gitlab-ci.yml
+
1
−
1
View file @
7e7af9de
...
...
@@ -3,7 +3,7 @@ make_32bit_zip:
script
:
-
pip install git+https://gitlab.windenergy.dtu.dk/hawc-reference-models/reference-utilities.git
-
cd utils
-
python3 prepare_zip_file.py
-
python3 prepare_zip_file.py
$CI_COMMIT_REF_NAME
artifacts
:
paths
:
-
dtu-10mw-rwt.zip
...
...
This diff is collapsed.
Click to expand it.
utils/prepare_zip_file.py
+
12
−
9
View file @
7e7af9de
...
...
@@ -4,14 +4,17 @@
import
os
import
shutil
import
subprocess
import
sys
from
refutils
import
(
turb_to_hs2
,
turb_to_step
,
delete_dlls
,
clone_repo
,
get_repo_info
)
if
__name__
==
'
__main__
'
:
# get ref name
ci_ref
=
sys
.
argv
[
1
]
# script inputs
mod_dir
=
'
../dtu-10mw-rwt/
'
# must end with slash
zip_name
=
'
../dtu-10mw-rwt
'
zip_name
=
f
'
../dtu-10mw-rwt
_
{
ci_ref
}
'
basename
=
'
DTU_10MW_RWT
'
dll_git_url
=
'
https://gitlab.windenergy.dtu.dk/OpenLAC/control-binary/control-win32.git
'
dll_branch
=
'
ref_models
'
...
...
@@ -54,14 +57,14 @@ if __name__ == '__main__':
#subprocess.run(['rmdir', '/s', '/q', 'control-win32'], shell=True, check=True)
# write the git branch and commit to file
url
,
branch
,
commit
,
date
=
get_repo_info
()
with
open
(
mod_dir
+
'
git_version.txt
'
,
'
w
'
)
as
f
:
f
.
write
(
f
'
Git info for
{
basename
}
zip file
\n
'
)
f
.
write
(
'
------------------------------------
\n
'
)
f
.
write
(
'
Automatically generated using CI on following repo.
\n\n
'
)
f
.
write
(
f
'
Repo url:
{
url
}
\n
'
)
f
.
write
(
f
'
Branch:
{
branch
}
\n
'
)
f
.
write
(
f
'
Commit:
{
commit
}
made on
{
date
}
\n
'
)
#
url, branch, commit, date = get_repo_info()
#
with open(mod_dir + 'git_version.txt', 'w') as f:
#
f.write(f'Git info for {basename} zip file\n')
#
f.write('------------------------------------\n')
#
f.write('Automatically generated using CI on following repo.\n\n')
#
f.write(f'Repo url: {url}\n')
#
f.write(f'Branch: {branch}\n')
#
f.write(f'Commit: {commit} made on {date}\n')
# ======= make the archive =======
shutil
.
make_archive
(
mod_dir
,
'
zip
'
,
zip_name
)
...
...
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