Skip to content

Commit 7792aec

Browse files
added deploy to pypi
1 parent 4c32dad commit 7792aec

3 files changed

Lines changed: 56 additions & 0 deletions

File tree

.github/workflows/wheels.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,3 +56,44 @@ jobs:
5656
pattern: python_ics-*
5757
merge-multiple: true
5858
path: ./wheelhouse/
59+
60+
deploy_pypi:
61+
name: "Deploy PyPI"
62+
runs-on: ubuntu-latest
63+
needs: build_wheels
64+
if: |
65+
github.ref_name == 'master' ||
66+
startsWith(github.event.ref, 'refs/tags/v')
67+
steps:
68+
- uses: actions/checkout@v4
69+
with:
70+
fetch-depth: 0
71+
72+
- name: Install uv
73+
uses: astral-sh/setup-uv@v5
74+
with:
75+
enable-cache: true
76+
cache-dependency-glob: uv.lock
77+
78+
- name: Set up Python
79+
run: |
80+
uv python install 3.12
81+
uv venv -p 3.12
82+
source .venv/bin/activate
83+
uv pip install check-wheel-contents twine
84+
85+
- uses: actions/download-artifact@v4
86+
with:
87+
pattern: python_ics-*
88+
merge-multiple: true
89+
path: ./wheelhouse/
90+
91+
- name: "Publish to PyPI"
92+
if: |
93+
github.ref_name == 'master' ||
94+
startsWith(github.event.ref, 'refs/tags/v')
95+
run: |
96+
source .venv/bin/activate
97+
uv pip install check-wheel-contents twine
98+
check-wheel-contents ./wheelhouse/*.whl
99+
twine upload -u __token__ -p ${{ secrets.PYPI_TOKEN }} --verbose ./wheelhouse/*

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
# python virtual environment
22
.venv/
33

4+
icsnVC40_processed.h
5+
icsnVC40.h.*
6+
*.whl
7+
48
# Byte-compiled / optimized / DLL files
59
__pycache__/
610
*.py[cod]

src/setup_module_auto_defines.cpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -383,6 +383,7 @@ int setup_module_auto_defines(PyObject * module)
383383
result += PyModule_AddIntMacro(module, SPY_STATUS2_ETHERNET_T1S_BURST);
384384
result += PyModule_AddIntMacro(module, SPY_STATUS2_ETHERNET_T1S_ETHERNET);
385385
result += PyModule_AddIntMacro(module, SPY_STATUS3_ETHERNET_TX_COLLISION);
386+
result += PyModule_AddIntMacro(module, SPY_STATUS3_ETHERNET_T1S_WAKE);
386387
result += PyModule_AddIntMacro(module, SPY_STATUS2_FLEXRAY_TX_AB);
387388
result += PyModule_AddIntMacro(module, SPY_STATUS2_FLEXRAY_TX_AB_NO_A);
388389
result += PyModule_AddIntMacro(module, SPY_STATUS2_FLEXRAY_TX_AB_NO_B);
@@ -584,6 +585,7 @@ int setup_module_auto_defines(PyObject * module)
584585
result += PyModule_AddIntMacro(module, ETHERNET_SETTINGS2_FLAG2_SNF_TAP_ENABLE);
585586
result += PyModule_AddIntMacro(module, ETHERNET_SETTINGS2_FLAG2_DISABLE_TAP_TO_HOST);
586587
result += PyModule_AddIntMacro(module, ETHERNET_SETTINGS2_FLAG2_SHOW_TAP_TX_RECEIPT);
588+
result += PyModule_AddIntMacro(module, ETHERNET_SETTINGS2_FLAG2_TCP_COMM_STATIC_PORT_ENABLE);
587589
// enum
588590
result += PyModule_AddIntMacro(module, SFP_ID_UNKNOWN);
589591
result += PyModule_AddIntMacro(module, SFP_ID_FINISAR_FCLF8522P2BTL);
@@ -614,6 +616,7 @@ int setup_module_auto_defines(PyObject * module)
614616
result += PyModule_AddIntMacro(module, ETHERNET_SETTINGS10G_FLAG_DISABLE_TAP_TO_HOST);
615617
result += PyModule_AddIntMacro(module, ETHERNET_SETTINGS10G_FLAG_MACSEC_ENABLE);
616618
result += PyModule_AddIntMacro(module, ETHERNET_SETTINGS10G_FLAG_SHOW_TAP_TX_RECEIPT);
619+
result += PyModule_AddIntMacro(module, ETHERNET_SETTINGS10G_FLAG_TCP_COMM_STATIC_PORT_ENABLE);
617620
result += PyModule_AddIntMacro(module, ETHERNET_SETTINGS10G_FLAG_COMM_IN_USE);
618621
result += PyModule_AddIntMacro(module, ETHERNET10G_SETTINGS_SIZE);
619622
result += PyModule_AddIntMacro(module, ETHERNET10T1S_SETTINGS_SIZE);
@@ -713,6 +716,7 @@ int setup_module_auto_defines(PyObject * module)
713716
result += PyModule_AddIntMacro(module, swUpdateValidateComponent);
714717
result += PyModule_AddIntMacro(module, swUpdateFinalize);
715718
result += PyModule_AddIntMacro(module, swUpdateGetCommunicationVersion);
719+
result += PyModule_AddIntMacro(module, swUpdateCheckFwVersion);
716720
// end of enum - };
717721

718722
result += PyModule_AddIntMacro(module, SExtSubCmdHdr_SIZE);
@@ -1003,6 +1007,13 @@ int setup_module_auto_defines(PyObject * module)
10031007
result += PyModule_AddIntMacro(module, CMP_STREAMS_FIRE3);
10041008
result += PyModule_AddIntMacro(module, CMP_STREAMS_FIRE3FR);
10051009
result += PyModule_AddIntMacro(module, CMP_STREAMS_RED2);
1010+
// enum
1011+
result += PyModule_AddIntMacro(module, NETWORK_TIMESYNC_OFF);
1012+
result += PyModule_AddIntMacro(module, NETWORK_TIMESYNC_AUTO);
1013+
result += PyModule_AddIntMacro(module, NETWORK_TIMESYNC_NTP_ONLY);
1014+
result += PyModule_AddIntMacro(module, NETWORK_TIMESYNC_GPS_ONLY);
1015+
// end of enum - };
1016+
10061017
result += PyModule_AddIntMacro(module, SRed2Settings_SIZE);
10071018
result += PyModule_AddIntMacro(module, SFire3Settings_SIZE);
10081019
result += PyModule_AddIntMacro(module, SFire3FlexraySettings_SIZE);

0 commit comments

Comments
 (0)