From 160ed607f914a4acb3356d7bf72197295afa24f3 Mon Sep 17 00:00:00 2001 From: Ben Lye Date: Thu, 10 Nov 2022 20:13:47 +0000 Subject: [PATCH] Allow long filenames for BFT --- octoprint_firmwareupdater/static/js/firmwareupdater.js | 4 ++-- .../templates/firmwareupdater_settings.jinja2 | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/octoprint_firmwareupdater/static/js/firmwareupdater.js b/octoprint_firmwareupdater/static/js/firmwareupdater.js index a201dd2..2af62d0 100644 --- a/octoprint_firmwareupdater/static/js/firmwareupdater.js +++ b/octoprint_firmwareupdater/static/js/firmwareupdater.js @@ -643,7 +643,7 @@ $(function() { } if (self.getProfileSetting("flash_method") == "marlinbft" && self.getProfileSetting("marlinbft_use_custom_filename") && !self.checkMarlinBftCustomFileName()) { - alert = gettext("The target filename is invalid. Filename must be 8dot3 format."); + alert = gettext("The target filename is invalid."); } if (!self.flashPort() &! self.getProfileSetting("flash_method") == "dfuprogrammer") { @@ -1326,7 +1326,7 @@ $(function() { self.checkMarlinBftCustomFileName = function() { var filename = self.getProfileSetting("marlinbft_custom_filename") - var filenamePattern = new RegExp("^[A-z0-9_-]{1,8}\\.[A-z0-9]{1,3}$"); + var filenamePattern = new RegExp("^[A-z0-9_-]{1,}\\.[A-z0-9]{1,3}$"); return filenamePattern.test(filename); } diff --git a/octoprint_firmwareupdater/templates/firmwareupdater_settings.jinja2 b/octoprint_firmwareupdater/templates/firmwareupdater_settings.jinja2 index 9062308..0a899c2 100644 --- a/octoprint_firmwareupdater/templates/firmwareupdater_settings.jinja2 +++ b/octoprint_firmwareupdater/templates/firmwareupdater_settings.jinja2 @@ -547,7 +547,7 @@ - {{ _('Firmware file will be saved on the printer using the specified name. Filename must be in 8dot3 format (up 8 character name, up to 3 character extension).') }} + {{ _('Firmware file will be saved on the printer using the specified name.') }}