From c3aa15171244856327558b48085d538f2f315189 Mon Sep 17 00:00:00 2001 From: hedger Date: Fri, 25 Aug 2023 17:38:41 +0300 Subject: [PATCH 1/5] github: Check for todos (#3011) --- .../workflows/lint_and_submodule_check.yml | 23 ++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/.github/workflows/lint_and_submodule_check.yml b/.github/workflows/lint_and_submodule_check.yml index 22ca7d893..b85409ecd 100644 --- a/.github/workflows/lint_and_submodule_check.yml +++ b/.github/workflows/lint_and_submodule_check.yml @@ -23,9 +23,8 @@ jobs: - name: 'Checkout code' uses: actions/checkout@v3 with: - fetch-depth: 1 - ref: ${{ github.event.pull_request.head.sha }} - + fetch-depth: 2 + ref: ${{ github.sha }} - name: 'Check protobuf branch' run: | @@ -48,8 +47,26 @@ jobs: exit 1; fi + - name: 'Check for new TODOs' + id: check_todos + if: github.event_name == 'pull_request' + run: | + set +e; + git diff --unified=0 --no-color ${{ github.event.pull_request.base.sha }} ${{ github.sha }} | grep -E '^\+' | grep -i -E '(TODO|HACK|FIXME|XXX)[ :]' | grep -v -- '-nofl' > lines.log; + MISSING_TICKETS=$( grep -v -E '\[FL-[0-9]+\]' lines.log ); + if [ -n "$MISSING_TICKETS" ]; then + echo "Error: Missing ticket number in \`TODO\` comment(s)" >> $GITHUB_STEP_SUMMARY; + echo "\`\`\`" >> $GITHUB_STEP_SUMMARY; + echo "$MISSING_TICKETS" >> $GITHUB_STEP_SUMMARY; + echo "\`\`\`" >> $GITHUB_STEP_SUMMARY; + exit 1; + else + echo "No new TODOs without tickets found" >> $GITHUB_STEP_SUMMARY; + fi + - name: 'Check Python code formatting' id: syntax_check_py + if: always() run: | set +e; ./fbt -s lint_py 2>&1 | tee lint-py.log; From 66d26c16cd012dc83e699d3903e3aea3843dc972 Mon Sep 17 00:00:00 2001 From: Astra <93453568+Astrrra@users.noreply.github.com> Date: Sat, 26 Aug 2023 01:09:40 +0900 Subject: [PATCH 2/5] [FL-3580] AC OFF button (#3010) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: あく --- .../infrared/scenes/infrared_scene_universal_ac.c | 6 +++--- assets/icons/Infrared/off_19x20.png | Bin 0 -> 193 bytes assets/icons/Infrared/off_hover_19x20.png | Bin 0 -> 160 bytes assets/icons/Infrared/off_text_12x5.png | Bin 0 -> 130 bytes 4 files changed, 3 insertions(+), 3 deletions(-) create mode 100644 assets/icons/Infrared/off_19x20.png create mode 100644 assets/icons/Infrared/off_hover_19x20.png create mode 100644 assets/icons/Infrared/off_text_12x5.png diff --git a/applications/main/infrared/scenes/infrared_scene_universal_ac.c b/applications/main/infrared/scenes/infrared_scene_universal_ac.c index 8914e5ad0..cbb09a525 100644 --- a/applications/main/infrared/scenes/infrared_scene_universal_ac.c +++ b/applications/main/infrared/scenes/infrared_scene_universal_ac.c @@ -21,11 +21,11 @@ void infrared_scene_universal_ac_on_enter(void* context) { 0, 6, 15, - &I_power_19x20, - &I_power_hover_19x20, + &I_off_19x20, + &I_off_hover_19x20, infrared_scene_universal_common_item_callback, context); - button_panel_add_icon(button_panel, 4, 37, &I_power_text_24x5); + button_panel_add_icon(button_panel, 10, 37, &I_off_text_12x5); infrared_brute_force_add_record(brute_force, i++, "Off"); button_panel_add_item( button_panel, diff --git a/assets/icons/Infrared/off_19x20.png b/assets/icons/Infrared/off_19x20.png new file mode 100644 index 0000000000000000000000000000000000000000..6d68d7e6e1527c309de8e19e764dbcb4e68a5584 GIT binary patch literal 193 zcmeAS@N?(olHy`uVBq!ia0vp^!ayv-!2~29m`_v&Qk(@Ik;M!Q+&~F#VMc~ob0mO* z#hxyXAr`$?Cm-ZGV8G$*`||()P1Y>Cd@m>N)iqc2&)!f_Zp@sJDme2DF1jQH+wBmKZB>MpUXO@geCx>bSJI= literal 0 HcmV?d00001 From cf74dd259966df4b1772d7f398bb80c2fda991ea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=82=E3=81=8F?= Date: Sat, 26 Aug 2023 02:00:00 +0900 Subject: [PATCH 3/5] Rfid: fix crash on broken key launch from archive (#3012) --- applications/main/lfrfid/lfrfid.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/applications/main/lfrfid/lfrfid.c b/applications/main/lfrfid/lfrfid.c index edde23804..aa7510a90 100644 --- a/applications/main/lfrfid/lfrfid.c +++ b/applications/main/lfrfid/lfrfid.c @@ -186,13 +186,15 @@ int32_t lfrfid_app(void* p) { dolphin_deed(DolphinDeedRfidEmulate); } else { furi_string_set(app->file_path, args); - lfrfid_load_key_data(app, app->file_path, true); - view_dispatcher_attach_to_gui( - app->view_dispatcher, app->gui, ViewDispatcherTypeFullscreen); - scene_manager_next_scene(app->scene_manager, LfRfidSceneEmulate); - dolphin_deed(DolphinDeedRfidEmulate); + if(lfrfid_load_key_data(app, app->file_path, true)) { + view_dispatcher_attach_to_gui( + app->view_dispatcher, app->gui, ViewDispatcherTypeFullscreen); + scene_manager_next_scene(app->scene_manager, LfRfidSceneEmulate); + dolphin_deed(DolphinDeedRfidEmulate); + } else { + view_dispatcher_stop(app->view_dispatcher); + } } - } else { view_dispatcher_attach_to_gui( app->view_dispatcher, app->gui, ViewDispatcherTypeFullscreen); From 46e74b3823a72e146e3fb492c684bd38da33d110 Mon Sep 17 00:00:00 2001 From: MX <10697207+xMasterX@users.noreply.github.com> Date: Mon, 28 Aug 2023 05:48:40 +0300 Subject: [PATCH 4/5] remake fix in ofw way view_dispatcher will skip on _run and free will be called, then app will exit same as normal --- applications/main/lfrfid/lfrfid.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/applications/main/lfrfid/lfrfid.c b/applications/main/lfrfid/lfrfid.c index a57637a4b..040043b12 100644 --- a/applications/main/lfrfid/lfrfid.c +++ b/applications/main/lfrfid/lfrfid.c @@ -192,10 +192,7 @@ int32_t lfrfid_app(void* p) { scene_manager_next_scene(app->scene_manager, LfRfidSceneEmulate); dolphin_deed(DolphinDeedRfidEmulate); } else { - // TODO: exit properly view_dispatcher_stop(app->view_dispatcher); - lfrfid_free(app); - return 0; } } } else { From 5bd868665e1c04e46867dadf9389097f2249b09f Mon Sep 17 00:00:00 2001 From: MX <10697207+xMasterX@users.noreply.github.com> Date: Mon, 28 Aug 2023 05:50:32 +0300 Subject: [PATCH 5/5] fix timer icons in ir remote icons by @Svaarich --- assets/icons/Infrared/timer_19x20.png | Bin 215 -> 225 bytes assets/icons/Infrared/timer_hover_19x20.png | Bin 208 -> 212 bytes 2 files changed, 0 insertions(+), 0 deletions(-) diff --git a/assets/icons/Infrared/timer_19x20.png b/assets/icons/Infrared/timer_19x20.png index 3938d4bf1c64aef7fb54b3d1826dfda8b2eee822..6c2bdf6bbdcc08317f2d47c21f0ccc78cfca3178 100644 GIT binary patch delta 184 zcmV;p07w7V0pS6VF@Kv$L_t(IjkT0f4!|G?LtEqhugpF+7UBR=vwoRHo`pIoA_4#; zv8xAxt|0xeBdzBRjzQM3?(+^Oi8eb`iz?1j7|GX}U5}1cJp*}eviZ8s#)5HfQSu*H zCD{l#4PZrO*cgDPFaWFSh5o<{907*qoM6N<$f~pQmhyVZp diff --git a/assets/icons/Infrared/timer_hover_19x20.png b/assets/icons/Infrared/timer_hover_19x20.png index 930a53ae4ac5103a3e816fd74077a1ec6241310d..560ef895d9f147491ff623d511d74acb939da178 100644 GIT binary patch delta 171 zcmV;c0960b0n`DIF@KIpL_t(IjkQ!;4!|G`0<-&HnSE@U#@NT^M&eH+2)0T|0sxYD zi(3M1SIF`SKwC-%E!!YzEL(deHX;?$N(F?R(! Z{{+@ZQw~YC`aS>v002ovPDHLkV1mRbNlE|! delta 167 zcmV;Y09gOj0nh=EF@K6lL_t(IjlGoH3cw%?LsQxR|8n-QDMfly*#dhh>oGN|kR$+z z2zK=%&`v?RUjXokq|~w>NRCg}wqRp~!d8T1S`I{H)aM1R2xPhO>VPxm+@Kw5XDKXN zIRmBvtf&l|kB22U0Ili``F6}Gtu8Ml(^&+J(%!lOp8kC`mLOo+W>-b>adryq{Wlyx VQw}NB%4`4t002ovPDHLkV1nWBNwxq0