@@ -13,21 +13,17 @@ inputs:
1313 description : ' Build packages using devcontainer'
1414 required : false
1515 default : ' false'
16- add-source-dist :
17- description : ' Should create source distribution?'
18- required : false
19- default : ' true'
2016 pre-build-command :
2117 description : ' Command to execute before packaging'
2218 required : false
2319 post-build-command :
2420 description : ' Command to execute after packaging'
2521 required : false
26-
27- python-version :
28- description : ' Python version'
22+ add-source-dist :
23+ description : ' Should create source distribution?'
2924 required : false
30- default : ' 3.9'
25+ default : ' true'
26+
3127 add-wheel-dist :
3228 description : ' Should create wheel distribution?'
3329 required : false
@@ -37,9 +33,14 @@ inputs:
3733 required : false
3834 default : ' none'
3935 debian-dist-command :
40- description : ' Debian build command'
36+ description : ' Debian packaging custom command'
4137 required : false
4238
39+ python-version :
40+ description : ' Python version'
41+ required : false
42+ default : ' 3.9'
43+
4344 docker-registry :
4445 description : ' Docker registry'
4546 required : false
@@ -58,9 +59,10 @@ inputs:
5859 description : ' Devcontainer config selector (eg. architecture, OS, etc.)'
5960 required : false
6061 default : ' .'
61- packaging-command :
62- description : ' Devcontainer run command'
62+ packaging-folder :
63+ description : ' Optional subfolder to run packaging command'
6364 required : false
65+ default : ' .'
6466
6567outputs :
6668 upload-name :
@@ -70,10 +72,13 @@ outputs:
7072runs :
7173 using : ' composite'
7274 steps :
73- - name : Symlink current Actions repo
74- working-directory : ${{ github.action_path }}
75+ - name : Symlink current action repo
76+ env :
77+ action_path : ${{ github.action_path }}
7578 shell : bash
76- run : ln -fs $(realpath ../) ${{ github.workspace }}/
79+ run : |
80+ ln -fs ${{ env.action_path }} .github/actions
81+
7782 - name : Set up environment
7883 id : set-env
7984 shell : bash
95100 shell : bash
96101 run : |
97102 git clone https://github.com/EffectiveRange/packaging-tools.git /tmp/packaging-tools
98- echo " /tmp/packaging-tools/python" >> $GITHUB_PATH
103+ sudo bash /tmp/packaging-tools/python/install.sh
99104
100105 - if : ${{ inputs.pre-build-command }}
101106 name : Run pre-build command
@@ -109,24 +114,30 @@ runs:
109114
110115 - if : ${{ inputs.use-devcontainer != 'true' }}
111116 name : Build native packages
112- uses : ./native
117+ uses : ./.github/actions/ native
113118 with :
114119 python-version : ${{ inputs.python-version }}
115- add-source-dist : ${{ inputs.add-source-dist }}
116120 add-wheel-dist : ${{ inputs.add-wheel-dist }}
117121 debian-dist-type : ${{ inputs.debian-dist-type }}
118122 debian-dist-command : ${{ inputs.debian-dist-command }}
119123
120124 - if : ${{ inputs.use-devcontainer == 'true' }}
121125 name : Build packages using a devcontainer
122- uses : ./devcontainer
126+ uses : ./.github/actions/ devcontainer
123127 with :
128+ add-wheel-dist : ${{ inputs.add-wheel-dist }}
129+ debian-dist-type : ${{ inputs.debian-dist-type }}
130+ debian-dist-command : ${{ inputs.debian-dist-command }}
124131 docker-registry : ${{ inputs.docker-registry }}
125132 docker-username : ${{ inputs.docker-username }}
126133 docker-password : ${{ inputs.docker-password }}
127134 container-platform : ${{ inputs.container-platform }}
128135 container-config : ${{ inputs.container-config }}
129- packaging-command : ${{ inputs.packaging-command }}
136+ packaging-folder : ${{ inputs.packaging-folder }}
137+
138+ - name : Unlink the action repository
139+ run : rm -f .github/actions
140+ shell : bash
130141
131142 - if : ${{ inputs.post-build-command }}
132143 name : Run post-build command
0 commit comments