DEV: Upgrade ACE Editor to 1.4.12, remove extra ACE files (#10431)

DEV: Upgrade ACE Editor to 1.4.12, remove extra ACE files (#10431)

diff --git a/lib/tasks/javascript.rake b/lib/tasks/javascript.rake
index 25392df..a5f4a99 100644
--- a/lib/tasks/javascript.rake
+++ b/lib/tasks/javascript.rake
@@ -63,7 +63,7 @@ task 'javascript:update' do
       source: 'bootstrap/js/modal.js',
       destination: 'bootstrap-modal.js'
     }, {
-      source: 'ace-builds/src-min-noconflict/.',
+      source: 'ace-builds/src-min-noconflict/ace.js',
       destination: 'ace',
       public: true
     }, {
@@ -203,11 +203,6 @@ task 'javascript:update' do
       File.write(test_bundle_dest, HighlightJs.bundle(langs))
     end
 
-    if src.include? "ace-builds"
-      puts "Cleanup unused snippets folder for ACE"
-      system("rm -rf node_modules/ace-builds/src-min-noconflict/snippets")
-    end
-
     if f[:public_root]
       dest = "#{public_root}/#{filename}"
     elsif f[:public]
@@ -216,6 +211,14 @@ task 'javascript:update' do
       dest = "#{vendor_js}/#{filename}"
     end
 
+    if src.include? "ace.js"
+      ace_root = "#{library_src}/ace-builds/src-min-noconflict/"
+      addtl_files = [ "ext-searchbox", "mode-html", "mode-scss", "mode-sql", "theme-chrome", "worker-html"]
+      addtl_files.each do |file|
+        FileUtils.cp_r("#{ace_root}#{file}.js", dest)
+      end
+    end
+
     # lodash.js needs building
     if src.include? "lodash.js"
       puts "Building custom lodash.js build"
diff --git a/package.json b/package.json
index e73fee2..22890f3 100644
--- a/package.json
+++ b/package.json
@@ -8,7 +8,7 @@
   "dependencies": {
     "@fortawesome/fontawesome-free": "5.11.2",
     "@popperjs/core": "v2.0.6",
-    "ace-builds": "1.4.2",
+    "ace-builds": "1.4.12",
     "blueimp-file-upload": "10.13.0",
     "bootbox": "3.2.0",
     "bootstrap": "v3.4.1",
diff --git a/public/javascripts/ace/ace.js b/public/javascripts/ace/ace.js
index 58119de..f259ac2 100644
--- a/public/javascripts/ace/ace.js
+++ b/public/javascripts/ace/ace.js
@@ -1,4 +1,4 @@

[... diff too long, it was truncated ...]

GitHub sha: eae8b046

This commit appears in #10431 which was merged by pmusaraj.