2121 required : true
2222 default : false
2323 type : boolean
24+ spoof_build :
25+ description : ' Attach spoofed build'
26+ required : true
27+ default : false
28+ type : boolean
2429 send_github :
2530 description : ' Release on GitHub'
2631 required : true
4348jobs :
4449 spoofed-build :
4550 name : Build spoofed APK
51+ if : github.event.inputs.spoof_build == 'true'
4652 runs-on : ubuntu-latest
4753 outputs :
4854 release-name : ${{ steps.release-name.outputs.name }}
@@ -186,6 +192,7 @@ jobs:
186192 release :
187193 name : Release on Telegram or GitHub
188194 runs-on : ubuntu-latest
195+ if : github.event.inputs.send_telegram == 'true' || github.event.inputs.send_github == 'true'
189196 needs : [ build, spoofed-build ]
190197 steps :
191198 - name : Checkout
@@ -200,6 +207,7 @@ jobs:
200207 path : unspoofed-apk
201208
202209 - name : Download Spoofed APK
210+ if : github.event.inputs.spoof_build == 'true'
203211 uses : actions/download-artifact@v4
204212 with :
205213 name : ${{ needs.spoofed-build.outputs.release-name }}
@@ -212,6 +220,7 @@ jobs:
212220 path : mapping
213221
214222 - name : Download Spoofed Mappings
223+ if : github.event.inputs.spoof_build == 'true'
215224 uses : actions/download-artifact@v4
216225 with :
217226 name : spoofed-mapping
@@ -224,6 +233,7 @@ jobs:
224233 echo "APK_PATH=$APK_PATH" >> $GITHUB_OUTPUT
225234
226235 - name : Find spoofed APK
236+ if : github.event.inputs.spoof_build == 'true'
227237 id : find_spoofed_apk
228238 run : |
229239 APK_PATH=$(find spoofed-apk -name "*.apk" | head -n 1)
@@ -236,6 +246,7 @@ jobs:
236246 echo "MAPPING_PATH=$MAPPING_PATH" >> $GITHUB_OUTPUT
237247
238248 - name : Find spoofed mapping file
249+ if : github.event.inputs.spoof_build == 'true'
239250 id : spoofed_mapping
240251 run : |
241252 MAPPING_PATH=$(find spoofed-mapping -name "mapping.txt" | head -n 1)
@@ -321,7 +332,7 @@ jobs:
321332 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
322333
323334 - name : Upload spoofed APK to GitHub Release
324- if : steps.check_release.outputs.exists == 'false' && github.event.inputs.send_github == 'true'
335+ if : steps.check_release.outputs.exists == 'false' && github.event.inputs.send_github == 'true' && github.event.inputs.spoof_build == 'true'
325336 uses : actions/upload-release-asset@v1
326337 with :
327338 upload_url : ${{ steps.create_release.outputs.upload_url }}
@@ -343,7 +354,7 @@ jobs:
343354 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
344355
345356 - name : Upload spoofed mapping to GitHub Release
346- if : steps.check_release.outputs.exists == 'false' && github.event.inputs.send_github == 'true'
357+ if : steps.check_release.outputs.exists == 'false' && github.event.inputs.send_github == 'true' && github.event.inputs.spoof_build == 'true'
347358 uses : actions/upload-release-asset@v1
348359 with :
349360 upload_url : ${{ steps.create_release.outputs.upload_url }}
0 commit comments