-
Notifications
You must be signed in to change notification settings - Fork 87
/
.gitpod.yml
124 lines (121 loc) · 5.27 KB
/
.gitpod.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
image:
file: .gitpod/Dockerfile
# --------------------------------------------------------
# some useful extensions to have
vscode:
extensions:
- vivaxy.vscode-conventional-commits
- streetsidesoftware.code-spell-checker
- ms-python.python
- ms-python.black-formatter
- twxs.cmake
- ms-vscode.cmake-tools
- xaver.clang-format
- hbenl.vscode-test-explorer
- matepek.vscode-catch2-test-adapter
- bierner.markdown-mermaid
- DavidAnson.vscode-markdownlint
- darkriszty.markdown-table-prettify
# --------------------------------------------------------
# VSCode setup, Conan installation, and build of all the targets
tasks:
- name: vscode settings
init: |
mkdir -p "$PWD/.vscode";
cat << 'EOF' > "$PWD/.vscode/settings.json"
{
"workbench.startupEditor": "none",
"editor.tabSize": 2,
"editor.formatOnSave": true,
"editor.bracketPairColorization.enabled": true,
"editor.guides.bracketPairs": "active",
"cmake.generator": "Ninja Multi-Config",
"cmake.configureOnOpen": true,
"cmake.useCMakePresets": "always",
"cmake.options.statusBarVisibility": "visible",
"cmake.options.advanced": {
"testPreset": {
"statusBarVisibility": "hidden"
},
"ctest": {
"statusBarVisibility": "hidden"
}
},
"clang-format.executable": "/usr/bin/clang-format-17",
"C_Cpp.default.configurationProvider": "ms-vscode.cmake-tools",
"yaml.schemas": {
"https://squidfunk.github.io/mkdocs-material/schema.json": "mkdocs.yml"
},
"yaml.customTags": [
"!ENV scalar",
"!ENV sequence",
"tag:yaml.org,2002:python/name:materialx.emoji.to_svg",
"tag:yaml.org,2002:python/name:materialx.emoji.twemoji",
"tag:yaml.org,2002:python/name:pymdownx.superfences.fence_code_format"
]
}
EOF
exit
- name: install python packages
init: |
python -m venv ${PYTHON_VENV}
source ${PYTHON_VENV}/bin/activate
pip install -Ur requirements.txt
gp sync-done python-init
- name: configure conan and install dependencies
init: |
gp sync-await python-init
conan profile detect
conan config install $PWD/.gitpod/conan
conan install . -pr gcc12 -o '&:std_format=False' -b missing
conan install . -pr gcc12 -o '&:std_format=False' -b missing -s build_type=Debug
gp sync-done conan-gcc12-20
conan install . -pr gcc13 -o '&:std_format=True' -b missing
conan install . -pr gcc13 -o '&:std_format=True' -b missing -s build_type=Debug
gp sync-done conan-gcc13-20
conan install . -pr clang16 -o '&:std_format=False' -b missing
conan install . -pr clang16 -o '&:std_format=False' -b missing -s build_type=Debug
gp sync-done conan-clang16-20
conan install . -pr clang17 -o '&:std_format=True' -o '&:cxx_modules=True' -b missing
conan install . -pr clang17 -o '&:std_format=True' -o '&:cxx_modules=True' -b missing -s build_type=Debug
gp sync-done conan-clang17-20
conan remote login -p $ARTIFACTORY_TOKEN conan-gitpod-mp-units $ARTIFACTORY_USER
conan upload "*" -r conan-gitpod-mp-units -c
- name: gcc-12-20
init: |
gp sync-await conan-gcc12-20
source ${PYTHON_VENV}/bin/activate
conan build . -pr gcc12 -o '&:std_format=False'
conan build . -pr gcc12 -o '&:std_format=False' -s build_type=Debug
echo "🛠️ gcc-12 pre-build done for C++20, header files, and libfmt! You can close this terminal and use 'Build' button in the VSCode status bar for incremental builds. 🛠️"
- name: gcc-13-20
init: |
gp sync-await conan-gcc13-20
source ${PYTHON_VENV}/bin/activate
conan build . -pr gcc13 -o '&:std_format=True'
conan build . -pr gcc13 -o '&:std_format=True' -s build_type=Debug
echo "🛠️ gcc-13 pre-build done for C++20 and header files! You can close this terminal and use 'Build' button in the VSCode status bar for incremental builds. 🛠️"
- name: clang-16-20
init: |
gp sync-await conan-clang16-20
source ${PYTHON_VENV}/bin/activate
conan build . -pr clang16 -o '&:std_format=False'
conan build . -pr clang16 -o '&:std_format=False' -s build_type=Debug
echo "🛠️ clang-16 pre-build done for C++20, header files, and libfmt! You can close this terminal and use 'Build' button in the VSCode status bar for incremental builds. 🛠️"
- name: clang-17-20
init: |
gp sync-await conan-clang17-20
source ${PYTHON_VENV}/bin/activate
conan build . -pr clang17 -o '&:std_format=True' -o '&:cxx_modules=True'
conan build . -pr clang17 -o '&:std_format=True' -o '&:cxx_modules=True' -s build_type=Debug
echo "🛠️ clang-17 pre-build done for C++20! You can close this terminal and use 'Build' button in the VSCode status bar for incremental builds. 🛠️"
- name: documentation
init: |
gp sync-await python-init
source ${PYTHON_VENV}/bin/activate
mkdocs serve &
echo "📚 Documentation generation done! You can open it by clicking on 'Open Preview' or 'Open Browser' in the VSCode dialog window. 📚"
- name: open-contributing-guide
init: |
gp open CONTRIBUTING.md
exit