From 6a44955069afcc8f51b1aa9adafc520f81f903ee Mon Sep 17 00:00:00 2001 From: William Mayor Date: Mon, 28 Nov 2016 11:54:59 +0000 Subject: [PATCH 01/38] Move ace libraries into static dir --- {ace => static/ace}/ace.js | 0 {ace => static/ace}/ext-beautify.js | 0 {ace => static/ace}/ext-chromevox.js | 0 {ace => static/ace}/ext-elastic_tabstops_lite.js | 0 {ace => static/ace}/ext-emmet.js | 0 {ace => static/ace}/ext-error_marker.js | 0 {ace => static/ace}/ext-keybinding_menu.js | 0 {ace => static/ace}/ext-language_tools.js | 0 {ace => static/ace}/ext-linking.js | 0 {ace => static/ace}/ext-modelist.js | 0 {ace => static/ace}/ext-old_ie.js | 0 {ace => static/ace}/ext-searchbox.js | 0 {ace => static/ace}/ext-settings_menu.js | 0 {ace => static/ace}/ext-spellcheck.js | 0 {ace => static/ace}/ext-split.js | 0 {ace => static/ace}/ext-static_highlight.js | 0 {ace => static/ace}/ext-statusbar.js | 0 {ace => static/ace}/ext-textarea.js | 0 {ace => static/ace}/ext-themelist.js | 0 {ace => static/ace}/ext-whitespace.js | 0 {ace => static/ace}/keybinding-emacs.js | 0 {ace => static/ace}/keybinding-vim.js | 0 {ace => static/ace}/mode-abap.js | 0 {ace => static/ace}/mode-abc.js | 0 {ace => static/ace}/mode-actionscript.js | 0 {ace => static/ace}/mode-ada.js | 0 {ace => static/ace}/mode-apache_conf.js | 0 {ace => static/ace}/mode-applescript.js | 0 {ace => static/ace}/mode-asciidoc.js | 0 {ace => static/ace}/mode-assembly_x86.js | 0 {ace => static/ace}/mode-autohotkey.js | 0 {ace => static/ace}/mode-batchfile.js | 0 {ace => static/ace}/mode-c9search.js | 0 {ace => static/ace}/mode-c_cpp.js | 0 {ace => static/ace}/mode-cirru.js | 0 {ace => static/ace}/mode-clojure.js | 0 {ace => static/ace}/mode-cobol.js | 0 {ace => static/ace}/mode-coffee.js | 0 {ace => static/ace}/mode-coldfusion.js | 0 {ace => static/ace}/mode-csharp.js | 0 {ace => static/ace}/mode-css.js | 0 {ace => static/ace}/mode-curly.js | 0 {ace => static/ace}/mode-d.js | 0 {ace => static/ace}/mode-dart.js | 0 {ace => static/ace}/mode-diff.js | 0 {ace => static/ace}/mode-django.js | 0 {ace => static/ace}/mode-dockerfile.js | 0 {ace => static/ace}/mode-dot.js | 0 {ace => static/ace}/mode-eiffel.js | 0 {ace => static/ace}/mode-ejs.js | 0 {ace => static/ace}/mode-elixir.js | 0 {ace => static/ace}/mode-elm.js | 0 {ace => static/ace}/mode-erlang.js | 0 {ace => static/ace}/mode-forth.js | 0 {ace => static/ace}/mode-ftl.js | 0 {ace => static/ace}/mode-gcode.js | 0 {ace => static/ace}/mode-gherkin.js | 0 {ace => static/ace}/mode-gitignore.js | 0 {ace => static/ace}/mode-glsl.js | 0 {ace => static/ace}/mode-golang.js | 0 {ace => static/ace}/mode-groovy.js | 0 {ace => static/ace}/mode-haml.js | 0 {ace => static/ace}/mode-handlebars.js | 0 {ace => static/ace}/mode-haskell.js | 0 {ace => static/ace}/mode-haxe.js | 0 {ace => static/ace}/mode-html.js | 0 {ace => static/ace}/mode-html_ruby.js | 0 {ace => static/ace}/mode-ini.js | 0 {ace => static/ace}/mode-io.js | 0 {ace => static/ace}/mode-jack.js | 0 {ace => static/ace}/mode-jade.js | 0 {ace => static/ace}/mode-java.js | 0 {ace => static/ace}/mode-javascript.js | 0 {ace => static/ace}/mode-json.js | 0 {ace => static/ace}/mode-jsoniq.js | 0 {ace => static/ace}/mode-jsp.js | 0 {ace => static/ace}/mode-jsx.js | 0 {ace => static/ace}/mode-julia.js | 0 {ace => static/ace}/mode-latex.js | 0 {ace => static/ace}/mode-lean.js | 0 {ace => static/ace}/mode-less.js | 0 {ace => static/ace}/mode-liquid.js | 0 {ace => static/ace}/mode-lisp.js | 0 {ace => static/ace}/mode-live_script.js | 0 {ace => static/ace}/mode-livescript.js | 0 {ace => static/ace}/mode-logiql.js | 0 {ace => static/ace}/mode-lsl.js | 0 {ace => static/ace}/mode-lua.js | 0 {ace => static/ace}/mode-luapage.js | 0 {ace => static/ace}/mode-lucene.js | 0 {ace => static/ace}/mode-makefile.js | 0 {ace => static/ace}/mode-markdown.js | 0 {ace => static/ace}/mode-mask.js | 0 {ace => static/ace}/mode-matlab.js | 0 {ace => static/ace}/mode-maze.js | 0 {ace => static/ace}/mode-mel.js | 0 {ace => static/ace}/mode-mips_assembler.js | 0 {ace => static/ace}/mode-mipsassembler.js | 0 {ace => static/ace}/mode-mushcode.js | 0 {ace => static/ace}/mode-mysql.js | 0 {ace => static/ace}/mode-nix.js | 0 {ace => static/ace}/mode-objectivec.js | 0 {ace => static/ace}/mode-ocaml.js | 0 {ace => static/ace}/mode-pascal.js | 0 {ace => static/ace}/mode-perl.js | 0 {ace => static/ace}/mode-pgsql.js | 0 {ace => static/ace}/mode-php.js | 0 {ace => static/ace}/mode-plain_text.js | 0 {ace => static/ace}/mode-powershell.js | 0 {ace => static/ace}/mode-praat.js | 0 {ace => static/ace}/mode-prolog.js | 0 {ace => static/ace}/mode-properties.js | 0 {ace => static/ace}/mode-protobuf.js | 0 {ace => static/ace}/mode-python.js | 0 {ace => static/ace}/mode-r.js | 0 {ace => static/ace}/mode-rdoc.js | 0 {ace => static/ace}/mode-rhtml.js | 0 {ace => static/ace}/mode-ruby.js | 0 {ace => static/ace}/mode-rust.js | 0 {ace => static/ace}/mode-sass.js | 0 {ace => static/ace}/mode-scad.js | 0 {ace => static/ace}/mode-scala.js | 0 {ace => static/ace}/mode-scheme.js | 0 {ace => static/ace}/mode-scss.js | 0 {ace => static/ace}/mode-sh.js | 0 {ace => static/ace}/mode-sjs.js | 0 {ace => static/ace}/mode-smarty.js | 0 {ace => static/ace}/mode-snippets.js | 0 {ace => static/ace}/mode-soy_template.js | 0 {ace => static/ace}/mode-space.js | 0 {ace => static/ace}/mode-sql.js | 0 {ace => static/ace}/mode-sqlserver.js | 0 {ace => static/ace}/mode-stylus.js | 0 {ace => static/ace}/mode-svg.js | 0 {ace => static/ace}/mode-tcl.js | 0 {ace => static/ace}/mode-tex.js | 0 {ace => static/ace}/mode-text.js | 0 {ace => static/ace}/mode-textile.js | 0 {ace => static/ace}/mode-toml.js | 0 {ace => static/ace}/mode-twig.js | 0 {ace => static/ace}/mode-typescript.js | 0 {ace => static/ace}/mode-vala.js | 0 {ace => static/ace}/mode-vbscript.js | 0 {ace => static/ace}/mode-velocity.js | 0 {ace => static/ace}/mode-verilog.js | 0 {ace => static/ace}/mode-vhdl.js | 0 {ace => static/ace}/mode-xml.js | 0 {ace => static/ace}/mode-xquery.js | 0 {ace => static/ace}/mode-yaml.js | 0 {ace => static/ace}/snippets/abap.js | 0 {ace => static/ace}/snippets/abc.js | 0 {ace => static/ace}/snippets/actionscript.js | 0 {ace => static/ace}/snippets/ada.js | 0 {ace => static/ace}/snippets/apache_conf.js | 0 {ace => static/ace}/snippets/applescript.js | 0 {ace => static/ace}/snippets/asciidoc.js | 0 {ace => static/ace}/snippets/assembly_x86.js | 0 {ace => static/ace}/snippets/autohotkey.js | 0 {ace => static/ace}/snippets/batchfile.js | 0 {ace => static/ace}/snippets/c9search.js | 0 {ace => static/ace}/snippets/c_cpp.js | 0 {ace => static/ace}/snippets/cirru.js | 0 {ace => static/ace}/snippets/clojure.js | 0 {ace => static/ace}/snippets/cobol.js | 0 {ace => static/ace}/snippets/coffee.js | 0 {ace => static/ace}/snippets/coldfusion.js | 0 {ace => static/ace}/snippets/csharp.js | 0 {ace => static/ace}/snippets/css.js | 0 {ace => static/ace}/snippets/curly.js | 0 {ace => static/ace}/snippets/d.js | 0 {ace => static/ace}/snippets/dart.js | 0 {ace => static/ace}/snippets/diff.js | 0 {ace => static/ace}/snippets/django.js | 0 {ace => static/ace}/snippets/dockerfile.js | 0 {ace => static/ace}/snippets/dot.js | 0 {ace => static/ace}/snippets/eiffel.js | 0 {ace => static/ace}/snippets/ejs.js | 0 {ace => static/ace}/snippets/elixir.js | 0 {ace => static/ace}/snippets/elm.js | 0 {ace => static/ace}/snippets/erlang.js | 0 {ace => static/ace}/snippets/forth.js | 0 {ace => static/ace}/snippets/ftl.js | 0 {ace => static/ace}/snippets/gcode.js | 0 {ace => static/ace}/snippets/gherkin.js | 0 {ace => static/ace}/snippets/gitignore.js | 0 {ace => static/ace}/snippets/glsl.js | 0 {ace => static/ace}/snippets/golang.js | 0 {ace => static/ace}/snippets/groovy.js | 0 {ace => static/ace}/snippets/haml.js | 0 {ace => static/ace}/snippets/handlebars.js | 0 {ace => static/ace}/snippets/haskell.js | 0 {ace => static/ace}/snippets/haxe.js | 0 {ace => static/ace}/snippets/html.js | 0 {ace => static/ace}/snippets/html_ruby.js | 0 {ace => static/ace}/snippets/ini.js | 0 {ace => static/ace}/snippets/io.js | 0 {ace => static/ace}/snippets/jack.js | 0 {ace => static/ace}/snippets/jade.js | 0 {ace => static/ace}/snippets/java.js | 0 {ace => static/ace}/snippets/javascript.js | 0 {ace => static/ace}/snippets/json.js | 0 {ace => static/ace}/snippets/jsoniq.js | 0 {ace => static/ace}/snippets/jsp.js | 0 {ace => static/ace}/snippets/jsx.js | 0 {ace => static/ace}/snippets/julia.js | 0 {ace => static/ace}/snippets/latex.js | 0 {ace => static/ace}/snippets/lean.js | 0 {ace => static/ace}/snippets/less.js | 0 {ace => static/ace}/snippets/liquid.js | 0 {ace => static/ace}/snippets/lisp.js | 0 {ace => static/ace}/snippets/live_script.js | 0 {ace => static/ace}/snippets/livescript.js | 0 {ace => static/ace}/snippets/logiql.js | 0 {ace => static/ace}/snippets/lsl.js | 0 {ace => static/ace}/snippets/lua.js | 0 {ace => static/ace}/snippets/luapage.js | 0 {ace => static/ace}/snippets/lucene.js | 0 {ace => static/ace}/snippets/makefile.js | 0 {ace => static/ace}/snippets/markdown.js | 0 {ace => static/ace}/snippets/mask.js | 0 {ace => static/ace}/snippets/matlab.js | 0 {ace => static/ace}/snippets/maze.js | 0 {ace => static/ace}/snippets/mel.js | 0 {ace => static/ace}/snippets/mips_assembler.js | 0 {ace => static/ace}/snippets/mipsassembler.js | 0 {ace => static/ace}/snippets/mushcode.js | 0 {ace => static/ace}/snippets/mysql.js | 0 {ace => static/ace}/snippets/nix.js | 0 {ace => static/ace}/snippets/objectivec.js | 0 {ace => static/ace}/snippets/ocaml.js | 0 {ace => static/ace}/snippets/pascal.js | 0 {ace => static/ace}/snippets/perl.js | 0 {ace => static/ace}/snippets/pgsql.js | 0 {ace => static/ace}/snippets/php.js | 0 {ace => static/ace}/snippets/plain_text.js | 0 {ace => static/ace}/snippets/powershell.js | 0 {ace => static/ace}/snippets/praat.js | 0 {ace => static/ace}/snippets/prolog.js | 0 {ace => static/ace}/snippets/properties.js | 0 {ace => static/ace}/snippets/protobuf.js | 0 {ace => static/ace}/snippets/python.js | 0 {ace => static/ace}/snippets/r.js | 0 {ace => static/ace}/snippets/rdoc.js | 0 {ace => static/ace}/snippets/rhtml.js | 0 {ace => static/ace}/snippets/ruby.js | 0 {ace => static/ace}/snippets/rust.js | 0 {ace => static/ace}/snippets/sass.js | 0 {ace => static/ace}/snippets/scad.js | 0 {ace => static/ace}/snippets/scala.js | 0 {ace => static/ace}/snippets/scheme.js | 0 {ace => static/ace}/snippets/scss.js | 0 {ace => static/ace}/snippets/sh.js | 0 {ace => static/ace}/snippets/sjs.js | 0 {ace => static/ace}/snippets/smarty.js | 0 {ace => static/ace}/snippets/snippets.js | 0 {ace => static/ace}/snippets/soy_template.js | 0 {ace => static/ace}/snippets/space.js | 0 {ace => static/ace}/snippets/sql.js | 0 {ace => static/ace}/snippets/sqlserver.js | 0 {ace => static/ace}/snippets/stylus.js | 0 {ace => static/ace}/snippets/svg.js | 0 {ace => static/ace}/snippets/tcl.js | 0 {ace => static/ace}/snippets/tex.js | 0 {ace => static/ace}/snippets/text.js | 0 {ace => static/ace}/snippets/textile.js | 0 {ace => static/ace}/snippets/toml.js | 0 {ace => static/ace}/snippets/twig.js | 0 {ace => static/ace}/snippets/typescript.js | 0 {ace => static/ace}/snippets/vala.js | 0 {ace => static/ace}/snippets/vbscript.js | 0 {ace => static/ace}/snippets/velocity.js | 0 {ace => static/ace}/snippets/verilog.js | 0 {ace => static/ace}/snippets/vhdl.js | 0 {ace => static/ace}/snippets/xml.js | 0 {ace => static/ace}/snippets/xquery.js | 0 {ace => static/ace}/snippets/yaml.js | 0 {ace => static/ace}/theme-ambiance.js | 0 {ace => static/ace}/theme-chaos.js | 0 {ace => static/ace}/theme-chrome.js | 0 {ace => static/ace}/theme-clouds.js | 0 {ace => static/ace}/theme-clouds_midnight.js | 0 {ace => static/ace}/theme-cobalt.js | 0 {ace => static/ace}/theme-crimson_editor.js | 0 {ace => static/ace}/theme-dawn.js | 0 {ace => static/ace}/theme-dreamweaver.js | 0 {ace => static/ace}/theme-eclipse.js | 0 {ace => static/ace}/theme-github.js | 0 {ace => static/ace}/theme-idle_fingers.js | 0 {ace => static/ace}/theme-iplastic.js | 0 {ace => static/ace}/theme-katzenmilch.js | 0 {ace => static/ace}/theme-kr_theme.js | 0 {ace => static/ace}/theme-kuroir.js | 0 {ace => static/ace}/theme-merbivore.js | 0 {ace => static/ace}/theme-merbivore_soft.js | 0 {ace => static/ace}/theme-mono_industrial.js | 0 {ace => static/ace}/theme-monokai.js | 0 {ace => static/ace}/theme-pastel_on_dark.js | 0 {ace => static/ace}/theme-solarized_dark.js | 0 {ace => static/ace}/theme-solarized_light.js | 0 {ace => static/ace}/theme-sqlserver.js | 0 {ace => static/ace}/theme-terminal.js | 0 {ace => static/ace}/theme-textmate.js | 0 {ace => static/ace}/theme-tomorrow.js | 0 {ace => static/ace}/theme-tomorrow_night.js | 0 {ace => static/ace}/theme-tomorrow_night_blue.js | 0 {ace => static/ace}/theme-tomorrow_night_bright.js | 0 {ace => static/ace}/theme-tomorrow_night_eighties.js | 0 {ace => static/ace}/theme-twilight.js | 0 {ace => static/ace}/theme-vibrant_ink.js | 0 {ace => static/ace}/theme-xcode.js | 0 {ace => static/ace}/worker-coffee.js | 0 {ace => static/ace}/worker-css.js | 0 {ace => static/ace}/worker-html.js | 0 {ace => static/ace}/worker-javascript.js | 0 {ace => static/ace}/worker-json.js | 0 {ace => static/ace}/worker-lua.js | 0 {ace => static/ace}/worker-php.js | 0 {ace => static/ace}/worker-xml.js | 0 {ace => static/ace}/worker-xquery.js | 0 319 files changed, 0 insertions(+), 0 deletions(-) rename {ace => static/ace}/ace.js (100%) rename {ace => static/ace}/ext-beautify.js (100%) rename {ace => static/ace}/ext-chromevox.js (100%) rename {ace => static/ace}/ext-elastic_tabstops_lite.js (100%) rename {ace => static/ace}/ext-emmet.js (100%) rename {ace => static/ace}/ext-error_marker.js (100%) rename {ace => static/ace}/ext-keybinding_menu.js (100%) rename {ace => static/ace}/ext-language_tools.js (100%) rename {ace => static/ace}/ext-linking.js (100%) rename {ace => static/ace}/ext-modelist.js (100%) rename {ace => static/ace}/ext-old_ie.js (100%) rename {ace => static/ace}/ext-searchbox.js (100%) rename {ace => static/ace}/ext-settings_menu.js (100%) rename {ace => static/ace}/ext-spellcheck.js (100%) rename {ace => static/ace}/ext-split.js (100%) rename {ace => static/ace}/ext-static_highlight.js (100%) rename {ace => static/ace}/ext-statusbar.js (100%) rename {ace => static/ace}/ext-textarea.js (100%) rename {ace => static/ace}/ext-themelist.js (100%) rename {ace => static/ace}/ext-whitespace.js (100%) rename {ace => static/ace}/keybinding-emacs.js (100%) rename {ace => static/ace}/keybinding-vim.js (100%) rename {ace => static/ace}/mode-abap.js (100%) rename {ace => static/ace}/mode-abc.js (100%) rename {ace => static/ace}/mode-actionscript.js (100%) rename {ace => static/ace}/mode-ada.js (100%) rename {ace => static/ace}/mode-apache_conf.js (100%) rename {ace => static/ace}/mode-applescript.js (100%) rename {ace => static/ace}/mode-asciidoc.js (100%) rename {ace => static/ace}/mode-assembly_x86.js (100%) rename {ace => static/ace}/mode-autohotkey.js (100%) rename {ace => static/ace}/mode-batchfile.js (100%) rename {ace => static/ace}/mode-c9search.js (100%) rename {ace => static/ace}/mode-c_cpp.js (100%) rename {ace => static/ace}/mode-cirru.js (100%) rename {ace => static/ace}/mode-clojure.js (100%) rename {ace => static/ace}/mode-cobol.js (100%) rename {ace => static/ace}/mode-coffee.js (100%) rename {ace => static/ace}/mode-coldfusion.js (100%) rename {ace => static/ace}/mode-csharp.js (100%) rename {ace => static/ace}/mode-css.js (100%) rename {ace => static/ace}/mode-curly.js (100%) rename {ace => static/ace}/mode-d.js (100%) rename {ace => static/ace}/mode-dart.js (100%) rename {ace => static/ace}/mode-diff.js (100%) rename {ace => static/ace}/mode-django.js (100%) rename {ace => static/ace}/mode-dockerfile.js (100%) rename {ace => static/ace}/mode-dot.js (100%) rename {ace => static/ace}/mode-eiffel.js (100%) rename {ace => static/ace}/mode-ejs.js (100%) rename {ace => static/ace}/mode-elixir.js (100%) rename {ace => static/ace}/mode-elm.js (100%) rename {ace => static/ace}/mode-erlang.js (100%) rename {ace => static/ace}/mode-forth.js (100%) rename {ace => static/ace}/mode-ftl.js (100%) rename {ace => static/ace}/mode-gcode.js (100%) rename {ace => static/ace}/mode-gherkin.js (100%) rename {ace => static/ace}/mode-gitignore.js (100%) rename {ace => static/ace}/mode-glsl.js (100%) rename {ace => static/ace}/mode-golang.js (100%) rename {ace => static/ace}/mode-groovy.js (100%) rename {ace => static/ace}/mode-haml.js (100%) rename {ace => static/ace}/mode-handlebars.js (100%) rename {ace => static/ace}/mode-haskell.js (100%) rename {ace => static/ace}/mode-haxe.js (100%) rename {ace => static/ace}/mode-html.js (100%) rename {ace => static/ace}/mode-html_ruby.js (100%) rename {ace => static/ace}/mode-ini.js (100%) rename {ace => static/ace}/mode-io.js (100%) rename {ace => static/ace}/mode-jack.js (100%) rename {ace => static/ace}/mode-jade.js (100%) rename {ace => static/ace}/mode-java.js (100%) rename {ace => static/ace}/mode-javascript.js (100%) rename {ace => static/ace}/mode-json.js (100%) rename {ace => static/ace}/mode-jsoniq.js (100%) rename {ace => static/ace}/mode-jsp.js (100%) rename {ace => static/ace}/mode-jsx.js (100%) rename {ace => static/ace}/mode-julia.js (100%) rename {ace => static/ace}/mode-latex.js (100%) rename {ace => static/ace}/mode-lean.js (100%) rename {ace => static/ace}/mode-less.js (100%) rename {ace => static/ace}/mode-liquid.js (100%) rename {ace => static/ace}/mode-lisp.js (100%) rename {ace => static/ace}/mode-live_script.js (100%) rename {ace => static/ace}/mode-livescript.js (100%) rename {ace => static/ace}/mode-logiql.js (100%) rename {ace => static/ace}/mode-lsl.js (100%) rename {ace => static/ace}/mode-lua.js (100%) rename {ace => static/ace}/mode-luapage.js (100%) rename {ace => static/ace}/mode-lucene.js (100%) rename {ace => static/ace}/mode-makefile.js (100%) rename {ace => static/ace}/mode-markdown.js (100%) rename {ace => static/ace}/mode-mask.js (100%) rename {ace => static/ace}/mode-matlab.js (100%) rename {ace => static/ace}/mode-maze.js (100%) rename {ace => static/ace}/mode-mel.js (100%) rename {ace => static/ace}/mode-mips_assembler.js (100%) rename {ace => static/ace}/mode-mipsassembler.js (100%) rename {ace => static/ace}/mode-mushcode.js (100%) rename {ace => static/ace}/mode-mysql.js (100%) rename {ace => static/ace}/mode-nix.js (100%) rename {ace => static/ace}/mode-objectivec.js (100%) rename {ace => static/ace}/mode-ocaml.js (100%) rename {ace => static/ace}/mode-pascal.js (100%) rename {ace => static/ace}/mode-perl.js (100%) rename {ace => static/ace}/mode-pgsql.js (100%) rename {ace => static/ace}/mode-php.js (100%) rename {ace => static/ace}/mode-plain_text.js (100%) rename {ace => static/ace}/mode-powershell.js (100%) rename {ace => static/ace}/mode-praat.js (100%) rename {ace => static/ace}/mode-prolog.js (100%) rename {ace => static/ace}/mode-properties.js (100%) rename {ace => static/ace}/mode-protobuf.js (100%) rename {ace => static/ace}/mode-python.js (100%) rename {ace => static/ace}/mode-r.js (100%) rename {ace => static/ace}/mode-rdoc.js (100%) rename {ace => static/ace}/mode-rhtml.js (100%) rename {ace => static/ace}/mode-ruby.js (100%) rename {ace => static/ace}/mode-rust.js (100%) rename {ace => static/ace}/mode-sass.js (100%) rename {ace => static/ace}/mode-scad.js (100%) rename {ace => static/ace}/mode-scala.js (100%) rename {ace => static/ace}/mode-scheme.js (100%) rename {ace => static/ace}/mode-scss.js (100%) rename {ace => static/ace}/mode-sh.js (100%) rename {ace => static/ace}/mode-sjs.js (100%) rename {ace => static/ace}/mode-smarty.js (100%) rename {ace => static/ace}/mode-snippets.js (100%) rename {ace => static/ace}/mode-soy_template.js (100%) rename {ace => static/ace}/mode-space.js (100%) rename {ace => static/ace}/mode-sql.js (100%) rename {ace => static/ace}/mode-sqlserver.js (100%) rename {ace => static/ace}/mode-stylus.js (100%) rename {ace => static/ace}/mode-svg.js (100%) rename {ace => static/ace}/mode-tcl.js (100%) rename {ace => static/ace}/mode-tex.js (100%) rename {ace => static/ace}/mode-text.js (100%) rename {ace => static/ace}/mode-textile.js (100%) rename {ace => static/ace}/mode-toml.js (100%) rename {ace => static/ace}/mode-twig.js (100%) rename {ace => static/ace}/mode-typescript.js (100%) rename {ace => static/ace}/mode-vala.js (100%) rename {ace => static/ace}/mode-vbscript.js (100%) rename {ace => static/ace}/mode-velocity.js (100%) rename {ace => static/ace}/mode-verilog.js (100%) rename {ace => static/ace}/mode-vhdl.js (100%) rename {ace => static/ace}/mode-xml.js (100%) rename {ace => static/ace}/mode-xquery.js (100%) rename {ace => static/ace}/mode-yaml.js (100%) rename {ace => static/ace}/snippets/abap.js (100%) rename {ace => static/ace}/snippets/abc.js (100%) rename {ace => static/ace}/snippets/actionscript.js (100%) rename {ace => static/ace}/snippets/ada.js (100%) rename {ace => static/ace}/snippets/apache_conf.js (100%) rename {ace => static/ace}/snippets/applescript.js (100%) rename {ace => static/ace}/snippets/asciidoc.js (100%) rename {ace => static/ace}/snippets/assembly_x86.js (100%) rename {ace => static/ace}/snippets/autohotkey.js (100%) rename {ace => static/ace}/snippets/batchfile.js (100%) rename {ace => static/ace}/snippets/c9search.js (100%) rename {ace => static/ace}/snippets/c_cpp.js (100%) rename {ace => static/ace}/snippets/cirru.js (100%) rename {ace => static/ace}/snippets/clojure.js (100%) rename {ace => static/ace}/snippets/cobol.js (100%) rename {ace => static/ace}/snippets/coffee.js (100%) rename {ace => static/ace}/snippets/coldfusion.js (100%) rename {ace => static/ace}/snippets/csharp.js (100%) rename {ace => static/ace}/snippets/css.js (100%) rename {ace => static/ace}/snippets/curly.js (100%) rename {ace => static/ace}/snippets/d.js (100%) rename {ace => static/ace}/snippets/dart.js (100%) rename {ace => static/ace}/snippets/diff.js (100%) rename {ace => static/ace}/snippets/django.js (100%) rename {ace => static/ace}/snippets/dockerfile.js (100%) rename {ace => static/ace}/snippets/dot.js (100%) rename {ace => static/ace}/snippets/eiffel.js (100%) rename {ace => static/ace}/snippets/ejs.js (100%) rename {ace => static/ace}/snippets/elixir.js (100%) rename {ace => static/ace}/snippets/elm.js (100%) rename {ace => static/ace}/snippets/erlang.js (100%) rename {ace => static/ace}/snippets/forth.js (100%) rename {ace => static/ace}/snippets/ftl.js (100%) rename {ace => static/ace}/snippets/gcode.js (100%) rename {ace => static/ace}/snippets/gherkin.js (100%) rename {ace => static/ace}/snippets/gitignore.js (100%) rename {ace => static/ace}/snippets/glsl.js (100%) rename {ace => static/ace}/snippets/golang.js (100%) rename {ace => static/ace}/snippets/groovy.js (100%) rename {ace => static/ace}/snippets/haml.js (100%) rename {ace => static/ace}/snippets/handlebars.js (100%) rename {ace => static/ace}/snippets/haskell.js (100%) rename {ace => static/ace}/snippets/haxe.js (100%) rename {ace => static/ace}/snippets/html.js (100%) rename {ace => static/ace}/snippets/html_ruby.js (100%) rename {ace => static/ace}/snippets/ini.js (100%) rename {ace => static/ace}/snippets/io.js (100%) rename {ace => static/ace}/snippets/jack.js (100%) rename {ace => static/ace}/snippets/jade.js (100%) rename {ace => static/ace}/snippets/java.js (100%) rename {ace => static/ace}/snippets/javascript.js (100%) rename {ace => static/ace}/snippets/json.js (100%) rename {ace => static/ace}/snippets/jsoniq.js (100%) rename {ace => static/ace}/snippets/jsp.js (100%) rename {ace => static/ace}/snippets/jsx.js (100%) rename {ace => static/ace}/snippets/julia.js (100%) rename {ace => static/ace}/snippets/latex.js (100%) rename {ace => static/ace}/snippets/lean.js (100%) rename {ace => static/ace}/snippets/less.js (100%) rename {ace => static/ace}/snippets/liquid.js (100%) rename {ace => static/ace}/snippets/lisp.js (100%) rename {ace => static/ace}/snippets/live_script.js (100%) rename {ace => static/ace}/snippets/livescript.js (100%) rename {ace => static/ace}/snippets/logiql.js (100%) rename {ace => static/ace}/snippets/lsl.js (100%) rename {ace => static/ace}/snippets/lua.js (100%) rename {ace => static/ace}/snippets/luapage.js (100%) rename {ace => static/ace}/snippets/lucene.js (100%) rename {ace => static/ace}/snippets/makefile.js (100%) rename {ace => static/ace}/snippets/markdown.js (100%) rename {ace => static/ace}/snippets/mask.js (100%) rename {ace => static/ace}/snippets/matlab.js (100%) rename {ace => static/ace}/snippets/maze.js (100%) rename {ace => static/ace}/snippets/mel.js (100%) rename {ace => static/ace}/snippets/mips_assembler.js (100%) rename {ace => static/ace}/snippets/mipsassembler.js (100%) rename {ace => static/ace}/snippets/mushcode.js (100%) rename {ace => static/ace}/snippets/mysql.js (100%) rename {ace => static/ace}/snippets/nix.js (100%) rename {ace => static/ace}/snippets/objectivec.js (100%) rename {ace => static/ace}/snippets/ocaml.js (100%) rename {ace => static/ace}/snippets/pascal.js (100%) rename {ace => static/ace}/snippets/perl.js (100%) rename {ace => static/ace}/snippets/pgsql.js (100%) rename {ace => static/ace}/snippets/php.js (100%) rename {ace => static/ace}/snippets/plain_text.js (100%) rename {ace => static/ace}/snippets/powershell.js (100%) rename {ace => static/ace}/snippets/praat.js (100%) rename {ace => static/ace}/snippets/prolog.js (100%) rename {ace => static/ace}/snippets/properties.js (100%) rename {ace => static/ace}/snippets/protobuf.js (100%) rename {ace => static/ace}/snippets/python.js (100%) rename {ace => static/ace}/snippets/r.js (100%) rename {ace => static/ace}/snippets/rdoc.js (100%) rename {ace => static/ace}/snippets/rhtml.js (100%) rename {ace => static/ace}/snippets/ruby.js (100%) rename {ace => static/ace}/snippets/rust.js (100%) rename {ace => static/ace}/snippets/sass.js (100%) rename {ace => static/ace}/snippets/scad.js (100%) rename {ace => static/ace}/snippets/scala.js (100%) rename {ace => static/ace}/snippets/scheme.js (100%) rename {ace => static/ace}/snippets/scss.js (100%) rename {ace => static/ace}/snippets/sh.js (100%) rename {ace => static/ace}/snippets/sjs.js (100%) rename {ace => static/ace}/snippets/smarty.js (100%) rename {ace => static/ace}/snippets/snippets.js (100%) rename {ace => static/ace}/snippets/soy_template.js (100%) rename {ace => static/ace}/snippets/space.js (100%) rename {ace => static/ace}/snippets/sql.js (100%) rename {ace => static/ace}/snippets/sqlserver.js (100%) rename {ace => static/ace}/snippets/stylus.js (100%) rename {ace => static/ace}/snippets/svg.js (100%) rename {ace => static/ace}/snippets/tcl.js (100%) rename {ace => static/ace}/snippets/tex.js (100%) rename {ace => static/ace}/snippets/text.js (100%) rename {ace => static/ace}/snippets/textile.js (100%) rename {ace => static/ace}/snippets/toml.js (100%) rename {ace => static/ace}/snippets/twig.js (100%) rename {ace => static/ace}/snippets/typescript.js (100%) rename {ace => static/ace}/snippets/vala.js (100%) rename {ace => static/ace}/snippets/vbscript.js (100%) rename {ace => static/ace}/snippets/velocity.js (100%) rename {ace => static/ace}/snippets/verilog.js (100%) rename {ace => static/ace}/snippets/vhdl.js (100%) rename {ace => static/ace}/snippets/xml.js (100%) rename {ace => static/ace}/snippets/xquery.js (100%) rename {ace => static/ace}/snippets/yaml.js (100%) rename {ace => static/ace}/theme-ambiance.js (100%) rename {ace => static/ace}/theme-chaos.js (100%) rename {ace => static/ace}/theme-chrome.js (100%) rename {ace => static/ace}/theme-clouds.js (100%) rename {ace => static/ace}/theme-clouds_midnight.js (100%) rename {ace => static/ace}/theme-cobalt.js (100%) rename {ace => static/ace}/theme-crimson_editor.js (100%) rename {ace => static/ace}/theme-dawn.js (100%) rename {ace => static/ace}/theme-dreamweaver.js (100%) rename {ace => static/ace}/theme-eclipse.js (100%) rename {ace => static/ace}/theme-github.js (100%) rename {ace => static/ace}/theme-idle_fingers.js (100%) rename {ace => static/ace}/theme-iplastic.js (100%) rename {ace => static/ace}/theme-katzenmilch.js (100%) rename {ace => static/ace}/theme-kr_theme.js (100%) rename {ace => static/ace}/theme-kuroir.js (100%) rename {ace => static/ace}/theme-merbivore.js (100%) rename {ace => static/ace}/theme-merbivore_soft.js (100%) rename {ace => static/ace}/theme-mono_industrial.js (100%) rename {ace => static/ace}/theme-monokai.js (100%) rename {ace => static/ace}/theme-pastel_on_dark.js (100%) rename {ace => static/ace}/theme-solarized_dark.js (100%) rename {ace => static/ace}/theme-solarized_light.js (100%) rename {ace => static/ace}/theme-sqlserver.js (100%) rename {ace => static/ace}/theme-terminal.js (100%) rename {ace => static/ace}/theme-textmate.js (100%) rename {ace => static/ace}/theme-tomorrow.js (100%) rename {ace => static/ace}/theme-tomorrow_night.js (100%) rename {ace => static/ace}/theme-tomorrow_night_blue.js (100%) rename {ace => static/ace}/theme-tomorrow_night_bright.js (100%) rename {ace => static/ace}/theme-tomorrow_night_eighties.js (100%) rename {ace => static/ace}/theme-twilight.js (100%) rename {ace => static/ace}/theme-vibrant_ink.js (100%) rename {ace => static/ace}/theme-xcode.js (100%) rename {ace => static/ace}/worker-coffee.js (100%) rename {ace => static/ace}/worker-css.js (100%) rename {ace => static/ace}/worker-html.js (100%) rename {ace => static/ace}/worker-javascript.js (100%) rename {ace => static/ace}/worker-json.js (100%) rename {ace => static/ace}/worker-lua.js (100%) rename {ace => static/ace}/worker-php.js (100%) rename {ace => static/ace}/worker-xml.js (100%) rename {ace => static/ace}/worker-xquery.js (100%) diff --git a/ace/ace.js b/static/ace/ace.js similarity index 100% rename from ace/ace.js rename to static/ace/ace.js diff --git a/ace/ext-beautify.js b/static/ace/ext-beautify.js similarity index 100% rename from ace/ext-beautify.js rename to static/ace/ext-beautify.js diff --git a/ace/ext-chromevox.js b/static/ace/ext-chromevox.js similarity index 100% rename from ace/ext-chromevox.js rename to static/ace/ext-chromevox.js diff --git a/ace/ext-elastic_tabstops_lite.js b/static/ace/ext-elastic_tabstops_lite.js similarity index 100% rename from ace/ext-elastic_tabstops_lite.js rename to static/ace/ext-elastic_tabstops_lite.js diff --git a/ace/ext-emmet.js b/static/ace/ext-emmet.js similarity index 100% rename from ace/ext-emmet.js rename to static/ace/ext-emmet.js diff --git a/ace/ext-error_marker.js b/static/ace/ext-error_marker.js similarity index 100% rename from ace/ext-error_marker.js rename to static/ace/ext-error_marker.js diff --git a/ace/ext-keybinding_menu.js b/static/ace/ext-keybinding_menu.js similarity index 100% rename from ace/ext-keybinding_menu.js rename to static/ace/ext-keybinding_menu.js diff --git a/ace/ext-language_tools.js b/static/ace/ext-language_tools.js similarity index 100% rename from ace/ext-language_tools.js rename to static/ace/ext-language_tools.js diff --git a/ace/ext-linking.js b/static/ace/ext-linking.js similarity index 100% rename from ace/ext-linking.js rename to static/ace/ext-linking.js diff --git a/ace/ext-modelist.js b/static/ace/ext-modelist.js similarity index 100% rename from ace/ext-modelist.js rename to static/ace/ext-modelist.js diff --git a/ace/ext-old_ie.js b/static/ace/ext-old_ie.js similarity index 100% rename from ace/ext-old_ie.js rename to static/ace/ext-old_ie.js diff --git a/ace/ext-searchbox.js b/static/ace/ext-searchbox.js similarity index 100% rename from ace/ext-searchbox.js rename to static/ace/ext-searchbox.js diff --git a/ace/ext-settings_menu.js b/static/ace/ext-settings_menu.js similarity index 100% rename from ace/ext-settings_menu.js rename to static/ace/ext-settings_menu.js diff --git a/ace/ext-spellcheck.js b/static/ace/ext-spellcheck.js similarity index 100% rename from ace/ext-spellcheck.js rename to static/ace/ext-spellcheck.js diff --git a/ace/ext-split.js b/static/ace/ext-split.js similarity index 100% rename from ace/ext-split.js rename to static/ace/ext-split.js diff --git a/ace/ext-static_highlight.js b/static/ace/ext-static_highlight.js similarity index 100% rename from ace/ext-static_highlight.js rename to static/ace/ext-static_highlight.js diff --git a/ace/ext-statusbar.js b/static/ace/ext-statusbar.js similarity index 100% rename from ace/ext-statusbar.js rename to static/ace/ext-statusbar.js diff --git a/ace/ext-textarea.js b/static/ace/ext-textarea.js similarity index 100% rename from ace/ext-textarea.js rename to static/ace/ext-textarea.js diff --git a/ace/ext-themelist.js b/static/ace/ext-themelist.js similarity index 100% rename from ace/ext-themelist.js rename to static/ace/ext-themelist.js diff --git a/ace/ext-whitespace.js b/static/ace/ext-whitespace.js similarity index 100% rename from ace/ext-whitespace.js rename to static/ace/ext-whitespace.js diff --git a/ace/keybinding-emacs.js b/static/ace/keybinding-emacs.js similarity index 100% rename from ace/keybinding-emacs.js rename to static/ace/keybinding-emacs.js diff --git a/ace/keybinding-vim.js b/static/ace/keybinding-vim.js similarity index 100% rename from ace/keybinding-vim.js rename to static/ace/keybinding-vim.js diff --git a/ace/mode-abap.js b/static/ace/mode-abap.js similarity index 100% rename from ace/mode-abap.js rename to static/ace/mode-abap.js diff --git a/ace/mode-abc.js b/static/ace/mode-abc.js similarity index 100% rename from ace/mode-abc.js rename to static/ace/mode-abc.js diff --git a/ace/mode-actionscript.js b/static/ace/mode-actionscript.js similarity index 100% rename from ace/mode-actionscript.js rename to static/ace/mode-actionscript.js diff --git a/ace/mode-ada.js b/static/ace/mode-ada.js similarity index 100% rename from ace/mode-ada.js rename to static/ace/mode-ada.js diff --git a/ace/mode-apache_conf.js b/static/ace/mode-apache_conf.js similarity index 100% rename from ace/mode-apache_conf.js rename to static/ace/mode-apache_conf.js diff --git a/ace/mode-applescript.js b/static/ace/mode-applescript.js similarity index 100% rename from ace/mode-applescript.js rename to static/ace/mode-applescript.js diff --git a/ace/mode-asciidoc.js b/static/ace/mode-asciidoc.js similarity index 100% rename from ace/mode-asciidoc.js rename to static/ace/mode-asciidoc.js diff --git a/ace/mode-assembly_x86.js b/static/ace/mode-assembly_x86.js similarity index 100% rename from ace/mode-assembly_x86.js rename to static/ace/mode-assembly_x86.js diff --git a/ace/mode-autohotkey.js b/static/ace/mode-autohotkey.js similarity index 100% rename from ace/mode-autohotkey.js rename to static/ace/mode-autohotkey.js diff --git a/ace/mode-batchfile.js b/static/ace/mode-batchfile.js similarity index 100% rename from ace/mode-batchfile.js rename to static/ace/mode-batchfile.js diff --git a/ace/mode-c9search.js b/static/ace/mode-c9search.js similarity index 100% rename from ace/mode-c9search.js rename to static/ace/mode-c9search.js diff --git a/ace/mode-c_cpp.js b/static/ace/mode-c_cpp.js similarity index 100% rename from ace/mode-c_cpp.js rename to static/ace/mode-c_cpp.js diff --git a/ace/mode-cirru.js b/static/ace/mode-cirru.js similarity index 100% rename from ace/mode-cirru.js rename to static/ace/mode-cirru.js diff --git a/ace/mode-clojure.js b/static/ace/mode-clojure.js similarity index 100% rename from ace/mode-clojure.js rename to static/ace/mode-clojure.js diff --git a/ace/mode-cobol.js b/static/ace/mode-cobol.js similarity index 100% rename from ace/mode-cobol.js rename to static/ace/mode-cobol.js diff --git a/ace/mode-coffee.js b/static/ace/mode-coffee.js similarity index 100% rename from ace/mode-coffee.js rename to static/ace/mode-coffee.js diff --git a/ace/mode-coldfusion.js b/static/ace/mode-coldfusion.js similarity index 100% rename from ace/mode-coldfusion.js rename to static/ace/mode-coldfusion.js diff --git a/ace/mode-csharp.js b/static/ace/mode-csharp.js similarity index 100% rename from ace/mode-csharp.js rename to static/ace/mode-csharp.js diff --git a/ace/mode-css.js b/static/ace/mode-css.js similarity index 100% rename from ace/mode-css.js rename to static/ace/mode-css.js diff --git a/ace/mode-curly.js b/static/ace/mode-curly.js similarity index 100% rename from ace/mode-curly.js rename to static/ace/mode-curly.js diff --git a/ace/mode-d.js b/static/ace/mode-d.js similarity index 100% rename from ace/mode-d.js rename to static/ace/mode-d.js diff --git a/ace/mode-dart.js b/static/ace/mode-dart.js similarity index 100% rename from ace/mode-dart.js rename to static/ace/mode-dart.js diff --git a/ace/mode-diff.js b/static/ace/mode-diff.js similarity index 100% rename from ace/mode-diff.js rename to static/ace/mode-diff.js diff --git a/ace/mode-django.js b/static/ace/mode-django.js similarity index 100% rename from ace/mode-django.js rename to static/ace/mode-django.js diff --git a/ace/mode-dockerfile.js b/static/ace/mode-dockerfile.js similarity index 100% rename from ace/mode-dockerfile.js rename to static/ace/mode-dockerfile.js diff --git a/ace/mode-dot.js b/static/ace/mode-dot.js similarity index 100% rename from ace/mode-dot.js rename to static/ace/mode-dot.js diff --git a/ace/mode-eiffel.js b/static/ace/mode-eiffel.js similarity index 100% rename from ace/mode-eiffel.js rename to static/ace/mode-eiffel.js diff --git a/ace/mode-ejs.js b/static/ace/mode-ejs.js similarity index 100% rename from ace/mode-ejs.js rename to static/ace/mode-ejs.js diff --git a/ace/mode-elixir.js b/static/ace/mode-elixir.js similarity index 100% rename from ace/mode-elixir.js rename to static/ace/mode-elixir.js diff --git a/ace/mode-elm.js b/static/ace/mode-elm.js similarity index 100% rename from ace/mode-elm.js rename to static/ace/mode-elm.js diff --git a/ace/mode-erlang.js b/static/ace/mode-erlang.js similarity index 100% rename from ace/mode-erlang.js rename to static/ace/mode-erlang.js diff --git a/ace/mode-forth.js b/static/ace/mode-forth.js similarity index 100% rename from ace/mode-forth.js rename to static/ace/mode-forth.js diff --git a/ace/mode-ftl.js b/static/ace/mode-ftl.js similarity index 100% rename from ace/mode-ftl.js rename to static/ace/mode-ftl.js diff --git a/ace/mode-gcode.js b/static/ace/mode-gcode.js similarity index 100% rename from ace/mode-gcode.js rename to static/ace/mode-gcode.js diff --git a/ace/mode-gherkin.js b/static/ace/mode-gherkin.js similarity index 100% rename from ace/mode-gherkin.js rename to static/ace/mode-gherkin.js diff --git a/ace/mode-gitignore.js b/static/ace/mode-gitignore.js similarity index 100% rename from ace/mode-gitignore.js rename to static/ace/mode-gitignore.js diff --git a/ace/mode-glsl.js b/static/ace/mode-glsl.js similarity index 100% rename from ace/mode-glsl.js rename to static/ace/mode-glsl.js diff --git a/ace/mode-golang.js b/static/ace/mode-golang.js similarity index 100% rename from ace/mode-golang.js rename to static/ace/mode-golang.js diff --git a/ace/mode-groovy.js b/static/ace/mode-groovy.js similarity index 100% rename from ace/mode-groovy.js rename to static/ace/mode-groovy.js diff --git a/ace/mode-haml.js b/static/ace/mode-haml.js similarity index 100% rename from ace/mode-haml.js rename to static/ace/mode-haml.js diff --git a/ace/mode-handlebars.js b/static/ace/mode-handlebars.js similarity index 100% rename from ace/mode-handlebars.js rename to static/ace/mode-handlebars.js diff --git a/ace/mode-haskell.js b/static/ace/mode-haskell.js similarity index 100% rename from ace/mode-haskell.js rename to static/ace/mode-haskell.js diff --git a/ace/mode-haxe.js b/static/ace/mode-haxe.js similarity index 100% rename from ace/mode-haxe.js rename to static/ace/mode-haxe.js diff --git a/ace/mode-html.js b/static/ace/mode-html.js similarity index 100% rename from ace/mode-html.js rename to static/ace/mode-html.js diff --git a/ace/mode-html_ruby.js b/static/ace/mode-html_ruby.js similarity index 100% rename from ace/mode-html_ruby.js rename to static/ace/mode-html_ruby.js diff --git a/ace/mode-ini.js b/static/ace/mode-ini.js similarity index 100% rename from ace/mode-ini.js rename to static/ace/mode-ini.js diff --git a/ace/mode-io.js b/static/ace/mode-io.js similarity index 100% rename from ace/mode-io.js rename to static/ace/mode-io.js diff --git a/ace/mode-jack.js b/static/ace/mode-jack.js similarity index 100% rename from ace/mode-jack.js rename to static/ace/mode-jack.js diff --git a/ace/mode-jade.js b/static/ace/mode-jade.js similarity index 100% rename from ace/mode-jade.js rename to static/ace/mode-jade.js diff --git a/ace/mode-java.js b/static/ace/mode-java.js similarity index 100% rename from ace/mode-java.js rename to static/ace/mode-java.js diff --git a/ace/mode-javascript.js b/static/ace/mode-javascript.js similarity index 100% rename from ace/mode-javascript.js rename to static/ace/mode-javascript.js diff --git a/ace/mode-json.js b/static/ace/mode-json.js similarity index 100% rename from ace/mode-json.js rename to static/ace/mode-json.js diff --git a/ace/mode-jsoniq.js b/static/ace/mode-jsoniq.js similarity index 100% rename from ace/mode-jsoniq.js rename to static/ace/mode-jsoniq.js diff --git a/ace/mode-jsp.js b/static/ace/mode-jsp.js similarity index 100% rename from ace/mode-jsp.js rename to static/ace/mode-jsp.js diff --git a/ace/mode-jsx.js b/static/ace/mode-jsx.js similarity index 100% rename from ace/mode-jsx.js rename to static/ace/mode-jsx.js diff --git a/ace/mode-julia.js b/static/ace/mode-julia.js similarity index 100% rename from ace/mode-julia.js rename to static/ace/mode-julia.js diff --git a/ace/mode-latex.js b/static/ace/mode-latex.js similarity index 100% rename from ace/mode-latex.js rename to static/ace/mode-latex.js diff --git a/ace/mode-lean.js b/static/ace/mode-lean.js similarity index 100% rename from ace/mode-lean.js rename to static/ace/mode-lean.js diff --git a/ace/mode-less.js b/static/ace/mode-less.js similarity index 100% rename from ace/mode-less.js rename to static/ace/mode-less.js diff --git a/ace/mode-liquid.js b/static/ace/mode-liquid.js similarity index 100% rename from ace/mode-liquid.js rename to static/ace/mode-liquid.js diff --git a/ace/mode-lisp.js b/static/ace/mode-lisp.js similarity index 100% rename from ace/mode-lisp.js rename to static/ace/mode-lisp.js diff --git a/ace/mode-live_script.js b/static/ace/mode-live_script.js similarity index 100% rename from ace/mode-live_script.js rename to static/ace/mode-live_script.js diff --git a/ace/mode-livescript.js b/static/ace/mode-livescript.js similarity index 100% rename from ace/mode-livescript.js rename to static/ace/mode-livescript.js diff --git a/ace/mode-logiql.js b/static/ace/mode-logiql.js similarity index 100% rename from ace/mode-logiql.js rename to static/ace/mode-logiql.js diff --git a/ace/mode-lsl.js b/static/ace/mode-lsl.js similarity index 100% rename from ace/mode-lsl.js rename to static/ace/mode-lsl.js diff --git a/ace/mode-lua.js b/static/ace/mode-lua.js similarity index 100% rename from ace/mode-lua.js rename to static/ace/mode-lua.js diff --git a/ace/mode-luapage.js b/static/ace/mode-luapage.js similarity index 100% rename from ace/mode-luapage.js rename to static/ace/mode-luapage.js diff --git a/ace/mode-lucene.js b/static/ace/mode-lucene.js similarity index 100% rename from ace/mode-lucene.js rename to static/ace/mode-lucene.js diff --git a/ace/mode-makefile.js b/static/ace/mode-makefile.js similarity index 100% rename from ace/mode-makefile.js rename to static/ace/mode-makefile.js diff --git a/ace/mode-markdown.js b/static/ace/mode-markdown.js similarity index 100% rename from ace/mode-markdown.js rename to static/ace/mode-markdown.js diff --git a/ace/mode-mask.js b/static/ace/mode-mask.js similarity index 100% rename from ace/mode-mask.js rename to static/ace/mode-mask.js diff --git a/ace/mode-matlab.js b/static/ace/mode-matlab.js similarity index 100% rename from ace/mode-matlab.js rename to static/ace/mode-matlab.js diff --git a/ace/mode-maze.js b/static/ace/mode-maze.js similarity index 100% rename from ace/mode-maze.js rename to static/ace/mode-maze.js diff --git a/ace/mode-mel.js b/static/ace/mode-mel.js similarity index 100% rename from ace/mode-mel.js rename to static/ace/mode-mel.js diff --git a/ace/mode-mips_assembler.js b/static/ace/mode-mips_assembler.js similarity index 100% rename from ace/mode-mips_assembler.js rename to static/ace/mode-mips_assembler.js diff --git a/ace/mode-mipsassembler.js b/static/ace/mode-mipsassembler.js similarity index 100% rename from ace/mode-mipsassembler.js rename to static/ace/mode-mipsassembler.js diff --git a/ace/mode-mushcode.js b/static/ace/mode-mushcode.js similarity index 100% rename from ace/mode-mushcode.js rename to static/ace/mode-mushcode.js diff --git a/ace/mode-mysql.js b/static/ace/mode-mysql.js similarity index 100% rename from ace/mode-mysql.js rename to static/ace/mode-mysql.js diff --git a/ace/mode-nix.js b/static/ace/mode-nix.js similarity index 100% rename from ace/mode-nix.js rename to static/ace/mode-nix.js diff --git a/ace/mode-objectivec.js b/static/ace/mode-objectivec.js similarity index 100% rename from ace/mode-objectivec.js rename to static/ace/mode-objectivec.js diff --git a/ace/mode-ocaml.js b/static/ace/mode-ocaml.js similarity index 100% rename from ace/mode-ocaml.js rename to static/ace/mode-ocaml.js diff --git a/ace/mode-pascal.js b/static/ace/mode-pascal.js similarity index 100% rename from ace/mode-pascal.js rename to static/ace/mode-pascal.js diff --git a/ace/mode-perl.js b/static/ace/mode-perl.js similarity index 100% rename from ace/mode-perl.js rename to static/ace/mode-perl.js diff --git a/ace/mode-pgsql.js b/static/ace/mode-pgsql.js similarity index 100% rename from ace/mode-pgsql.js rename to static/ace/mode-pgsql.js diff --git a/ace/mode-php.js b/static/ace/mode-php.js similarity index 100% rename from ace/mode-php.js rename to static/ace/mode-php.js diff --git a/ace/mode-plain_text.js b/static/ace/mode-plain_text.js similarity index 100% rename from ace/mode-plain_text.js rename to static/ace/mode-plain_text.js diff --git a/ace/mode-powershell.js b/static/ace/mode-powershell.js similarity index 100% rename from ace/mode-powershell.js rename to static/ace/mode-powershell.js diff --git a/ace/mode-praat.js b/static/ace/mode-praat.js similarity index 100% rename from ace/mode-praat.js rename to static/ace/mode-praat.js diff --git a/ace/mode-prolog.js b/static/ace/mode-prolog.js similarity index 100% rename from ace/mode-prolog.js rename to static/ace/mode-prolog.js diff --git a/ace/mode-properties.js b/static/ace/mode-properties.js similarity index 100% rename from ace/mode-properties.js rename to static/ace/mode-properties.js diff --git a/ace/mode-protobuf.js b/static/ace/mode-protobuf.js similarity index 100% rename from ace/mode-protobuf.js rename to static/ace/mode-protobuf.js diff --git a/ace/mode-python.js b/static/ace/mode-python.js similarity index 100% rename from ace/mode-python.js rename to static/ace/mode-python.js diff --git a/ace/mode-r.js b/static/ace/mode-r.js similarity index 100% rename from ace/mode-r.js rename to static/ace/mode-r.js diff --git a/ace/mode-rdoc.js b/static/ace/mode-rdoc.js similarity index 100% rename from ace/mode-rdoc.js rename to static/ace/mode-rdoc.js diff --git a/ace/mode-rhtml.js b/static/ace/mode-rhtml.js similarity index 100% rename from ace/mode-rhtml.js rename to static/ace/mode-rhtml.js diff --git a/ace/mode-ruby.js b/static/ace/mode-ruby.js similarity index 100% rename from ace/mode-ruby.js rename to static/ace/mode-ruby.js diff --git a/ace/mode-rust.js b/static/ace/mode-rust.js similarity index 100% rename from ace/mode-rust.js rename to static/ace/mode-rust.js diff --git a/ace/mode-sass.js b/static/ace/mode-sass.js similarity index 100% rename from ace/mode-sass.js rename to static/ace/mode-sass.js diff --git a/ace/mode-scad.js b/static/ace/mode-scad.js similarity index 100% rename from ace/mode-scad.js rename to static/ace/mode-scad.js diff --git a/ace/mode-scala.js b/static/ace/mode-scala.js similarity index 100% rename from ace/mode-scala.js rename to static/ace/mode-scala.js diff --git a/ace/mode-scheme.js b/static/ace/mode-scheme.js similarity index 100% rename from ace/mode-scheme.js rename to static/ace/mode-scheme.js diff --git a/ace/mode-scss.js b/static/ace/mode-scss.js similarity index 100% rename from ace/mode-scss.js rename to static/ace/mode-scss.js diff --git a/ace/mode-sh.js b/static/ace/mode-sh.js similarity index 100% rename from ace/mode-sh.js rename to static/ace/mode-sh.js diff --git a/ace/mode-sjs.js b/static/ace/mode-sjs.js similarity index 100% rename from ace/mode-sjs.js rename to static/ace/mode-sjs.js diff --git a/ace/mode-smarty.js b/static/ace/mode-smarty.js similarity index 100% rename from ace/mode-smarty.js rename to static/ace/mode-smarty.js diff --git a/ace/mode-snippets.js b/static/ace/mode-snippets.js similarity index 100% rename from ace/mode-snippets.js rename to static/ace/mode-snippets.js diff --git a/ace/mode-soy_template.js b/static/ace/mode-soy_template.js similarity index 100% rename from ace/mode-soy_template.js rename to static/ace/mode-soy_template.js diff --git a/ace/mode-space.js b/static/ace/mode-space.js similarity index 100% rename from ace/mode-space.js rename to static/ace/mode-space.js diff --git a/ace/mode-sql.js b/static/ace/mode-sql.js similarity index 100% rename from ace/mode-sql.js rename to static/ace/mode-sql.js diff --git a/ace/mode-sqlserver.js b/static/ace/mode-sqlserver.js similarity index 100% rename from ace/mode-sqlserver.js rename to static/ace/mode-sqlserver.js diff --git a/ace/mode-stylus.js b/static/ace/mode-stylus.js similarity index 100% rename from ace/mode-stylus.js rename to static/ace/mode-stylus.js diff --git a/ace/mode-svg.js b/static/ace/mode-svg.js similarity index 100% rename from ace/mode-svg.js rename to static/ace/mode-svg.js diff --git a/ace/mode-tcl.js b/static/ace/mode-tcl.js similarity index 100% rename from ace/mode-tcl.js rename to static/ace/mode-tcl.js diff --git a/ace/mode-tex.js b/static/ace/mode-tex.js similarity index 100% rename from ace/mode-tex.js rename to static/ace/mode-tex.js diff --git a/ace/mode-text.js b/static/ace/mode-text.js similarity index 100% rename from ace/mode-text.js rename to static/ace/mode-text.js diff --git a/ace/mode-textile.js b/static/ace/mode-textile.js similarity index 100% rename from ace/mode-textile.js rename to static/ace/mode-textile.js diff --git a/ace/mode-toml.js b/static/ace/mode-toml.js similarity index 100% rename from ace/mode-toml.js rename to static/ace/mode-toml.js diff --git a/ace/mode-twig.js b/static/ace/mode-twig.js similarity index 100% rename from ace/mode-twig.js rename to static/ace/mode-twig.js diff --git a/ace/mode-typescript.js b/static/ace/mode-typescript.js similarity index 100% rename from ace/mode-typescript.js rename to static/ace/mode-typescript.js diff --git a/ace/mode-vala.js b/static/ace/mode-vala.js similarity index 100% rename from ace/mode-vala.js rename to static/ace/mode-vala.js diff --git a/ace/mode-vbscript.js b/static/ace/mode-vbscript.js similarity index 100% rename from ace/mode-vbscript.js rename to static/ace/mode-vbscript.js diff --git a/ace/mode-velocity.js b/static/ace/mode-velocity.js similarity index 100% rename from ace/mode-velocity.js rename to static/ace/mode-velocity.js diff --git a/ace/mode-verilog.js b/static/ace/mode-verilog.js similarity index 100% rename from ace/mode-verilog.js rename to static/ace/mode-verilog.js diff --git a/ace/mode-vhdl.js b/static/ace/mode-vhdl.js similarity index 100% rename from ace/mode-vhdl.js rename to static/ace/mode-vhdl.js diff --git a/ace/mode-xml.js b/static/ace/mode-xml.js similarity index 100% rename from ace/mode-xml.js rename to static/ace/mode-xml.js diff --git a/ace/mode-xquery.js b/static/ace/mode-xquery.js similarity index 100% rename from ace/mode-xquery.js rename to static/ace/mode-xquery.js diff --git a/ace/mode-yaml.js b/static/ace/mode-yaml.js similarity index 100% rename from ace/mode-yaml.js rename to static/ace/mode-yaml.js diff --git a/ace/snippets/abap.js b/static/ace/snippets/abap.js similarity index 100% rename from ace/snippets/abap.js rename to static/ace/snippets/abap.js diff --git a/ace/snippets/abc.js b/static/ace/snippets/abc.js similarity index 100% rename from ace/snippets/abc.js rename to static/ace/snippets/abc.js diff --git a/ace/snippets/actionscript.js b/static/ace/snippets/actionscript.js similarity index 100% rename from ace/snippets/actionscript.js rename to static/ace/snippets/actionscript.js diff --git a/ace/snippets/ada.js b/static/ace/snippets/ada.js similarity index 100% rename from ace/snippets/ada.js rename to static/ace/snippets/ada.js diff --git a/ace/snippets/apache_conf.js b/static/ace/snippets/apache_conf.js similarity index 100% rename from ace/snippets/apache_conf.js rename to static/ace/snippets/apache_conf.js diff --git a/ace/snippets/applescript.js b/static/ace/snippets/applescript.js similarity index 100% rename from ace/snippets/applescript.js rename to static/ace/snippets/applescript.js diff --git a/ace/snippets/asciidoc.js b/static/ace/snippets/asciidoc.js similarity index 100% rename from ace/snippets/asciidoc.js rename to static/ace/snippets/asciidoc.js diff --git a/ace/snippets/assembly_x86.js b/static/ace/snippets/assembly_x86.js similarity index 100% rename from ace/snippets/assembly_x86.js rename to static/ace/snippets/assembly_x86.js diff --git a/ace/snippets/autohotkey.js b/static/ace/snippets/autohotkey.js similarity index 100% rename from ace/snippets/autohotkey.js rename to static/ace/snippets/autohotkey.js diff --git a/ace/snippets/batchfile.js b/static/ace/snippets/batchfile.js similarity index 100% rename from ace/snippets/batchfile.js rename to static/ace/snippets/batchfile.js diff --git a/ace/snippets/c9search.js b/static/ace/snippets/c9search.js similarity index 100% rename from ace/snippets/c9search.js rename to static/ace/snippets/c9search.js diff --git a/ace/snippets/c_cpp.js b/static/ace/snippets/c_cpp.js similarity index 100% rename from ace/snippets/c_cpp.js rename to static/ace/snippets/c_cpp.js diff --git a/ace/snippets/cirru.js b/static/ace/snippets/cirru.js similarity index 100% rename from ace/snippets/cirru.js rename to static/ace/snippets/cirru.js diff --git a/ace/snippets/clojure.js b/static/ace/snippets/clojure.js similarity index 100% rename from ace/snippets/clojure.js rename to static/ace/snippets/clojure.js diff --git a/ace/snippets/cobol.js b/static/ace/snippets/cobol.js similarity index 100% rename from ace/snippets/cobol.js rename to static/ace/snippets/cobol.js diff --git a/ace/snippets/coffee.js b/static/ace/snippets/coffee.js similarity index 100% rename from ace/snippets/coffee.js rename to static/ace/snippets/coffee.js diff --git a/ace/snippets/coldfusion.js b/static/ace/snippets/coldfusion.js similarity index 100% rename from ace/snippets/coldfusion.js rename to static/ace/snippets/coldfusion.js diff --git a/ace/snippets/csharp.js b/static/ace/snippets/csharp.js similarity index 100% rename from ace/snippets/csharp.js rename to static/ace/snippets/csharp.js diff --git a/ace/snippets/css.js b/static/ace/snippets/css.js similarity index 100% rename from ace/snippets/css.js rename to static/ace/snippets/css.js diff --git a/ace/snippets/curly.js b/static/ace/snippets/curly.js similarity index 100% rename from ace/snippets/curly.js rename to static/ace/snippets/curly.js diff --git a/ace/snippets/d.js b/static/ace/snippets/d.js similarity index 100% rename from ace/snippets/d.js rename to static/ace/snippets/d.js diff --git a/ace/snippets/dart.js b/static/ace/snippets/dart.js similarity index 100% rename from ace/snippets/dart.js rename to static/ace/snippets/dart.js diff --git a/ace/snippets/diff.js b/static/ace/snippets/diff.js similarity index 100% rename from ace/snippets/diff.js rename to static/ace/snippets/diff.js diff --git a/ace/snippets/django.js b/static/ace/snippets/django.js similarity index 100% rename from ace/snippets/django.js rename to static/ace/snippets/django.js diff --git a/ace/snippets/dockerfile.js b/static/ace/snippets/dockerfile.js similarity index 100% rename from ace/snippets/dockerfile.js rename to static/ace/snippets/dockerfile.js diff --git a/ace/snippets/dot.js b/static/ace/snippets/dot.js similarity index 100% rename from ace/snippets/dot.js rename to static/ace/snippets/dot.js diff --git a/ace/snippets/eiffel.js b/static/ace/snippets/eiffel.js similarity index 100% rename from ace/snippets/eiffel.js rename to static/ace/snippets/eiffel.js diff --git a/ace/snippets/ejs.js b/static/ace/snippets/ejs.js similarity index 100% rename from ace/snippets/ejs.js rename to static/ace/snippets/ejs.js diff --git a/ace/snippets/elixir.js b/static/ace/snippets/elixir.js similarity index 100% rename from ace/snippets/elixir.js rename to static/ace/snippets/elixir.js diff --git a/ace/snippets/elm.js b/static/ace/snippets/elm.js similarity index 100% rename from ace/snippets/elm.js rename to static/ace/snippets/elm.js diff --git a/ace/snippets/erlang.js b/static/ace/snippets/erlang.js similarity index 100% rename from ace/snippets/erlang.js rename to static/ace/snippets/erlang.js diff --git a/ace/snippets/forth.js b/static/ace/snippets/forth.js similarity index 100% rename from ace/snippets/forth.js rename to static/ace/snippets/forth.js diff --git a/ace/snippets/ftl.js b/static/ace/snippets/ftl.js similarity index 100% rename from ace/snippets/ftl.js rename to static/ace/snippets/ftl.js diff --git a/ace/snippets/gcode.js b/static/ace/snippets/gcode.js similarity index 100% rename from ace/snippets/gcode.js rename to static/ace/snippets/gcode.js diff --git a/ace/snippets/gherkin.js b/static/ace/snippets/gherkin.js similarity index 100% rename from ace/snippets/gherkin.js rename to static/ace/snippets/gherkin.js diff --git a/ace/snippets/gitignore.js b/static/ace/snippets/gitignore.js similarity index 100% rename from ace/snippets/gitignore.js rename to static/ace/snippets/gitignore.js diff --git a/ace/snippets/glsl.js b/static/ace/snippets/glsl.js similarity index 100% rename from ace/snippets/glsl.js rename to static/ace/snippets/glsl.js diff --git a/ace/snippets/golang.js b/static/ace/snippets/golang.js similarity index 100% rename from ace/snippets/golang.js rename to static/ace/snippets/golang.js diff --git a/ace/snippets/groovy.js b/static/ace/snippets/groovy.js similarity index 100% rename from ace/snippets/groovy.js rename to static/ace/snippets/groovy.js diff --git a/ace/snippets/haml.js b/static/ace/snippets/haml.js similarity index 100% rename from ace/snippets/haml.js rename to static/ace/snippets/haml.js diff --git a/ace/snippets/handlebars.js b/static/ace/snippets/handlebars.js similarity index 100% rename from ace/snippets/handlebars.js rename to static/ace/snippets/handlebars.js diff --git a/ace/snippets/haskell.js b/static/ace/snippets/haskell.js similarity index 100% rename from ace/snippets/haskell.js rename to static/ace/snippets/haskell.js diff --git a/ace/snippets/haxe.js b/static/ace/snippets/haxe.js similarity index 100% rename from ace/snippets/haxe.js rename to static/ace/snippets/haxe.js diff --git a/ace/snippets/html.js b/static/ace/snippets/html.js similarity index 100% rename from ace/snippets/html.js rename to static/ace/snippets/html.js diff --git a/ace/snippets/html_ruby.js b/static/ace/snippets/html_ruby.js similarity index 100% rename from ace/snippets/html_ruby.js rename to static/ace/snippets/html_ruby.js diff --git a/ace/snippets/ini.js b/static/ace/snippets/ini.js similarity index 100% rename from ace/snippets/ini.js rename to static/ace/snippets/ini.js diff --git a/ace/snippets/io.js b/static/ace/snippets/io.js similarity index 100% rename from ace/snippets/io.js rename to static/ace/snippets/io.js diff --git a/ace/snippets/jack.js b/static/ace/snippets/jack.js similarity index 100% rename from ace/snippets/jack.js rename to static/ace/snippets/jack.js diff --git a/ace/snippets/jade.js b/static/ace/snippets/jade.js similarity index 100% rename from ace/snippets/jade.js rename to static/ace/snippets/jade.js diff --git a/ace/snippets/java.js b/static/ace/snippets/java.js similarity index 100% rename from ace/snippets/java.js rename to static/ace/snippets/java.js diff --git a/ace/snippets/javascript.js b/static/ace/snippets/javascript.js similarity index 100% rename from ace/snippets/javascript.js rename to static/ace/snippets/javascript.js diff --git a/ace/snippets/json.js b/static/ace/snippets/json.js similarity index 100% rename from ace/snippets/json.js rename to static/ace/snippets/json.js diff --git a/ace/snippets/jsoniq.js b/static/ace/snippets/jsoniq.js similarity index 100% rename from ace/snippets/jsoniq.js rename to static/ace/snippets/jsoniq.js diff --git a/ace/snippets/jsp.js b/static/ace/snippets/jsp.js similarity index 100% rename from ace/snippets/jsp.js rename to static/ace/snippets/jsp.js diff --git a/ace/snippets/jsx.js b/static/ace/snippets/jsx.js similarity index 100% rename from ace/snippets/jsx.js rename to static/ace/snippets/jsx.js diff --git a/ace/snippets/julia.js b/static/ace/snippets/julia.js similarity index 100% rename from ace/snippets/julia.js rename to static/ace/snippets/julia.js diff --git a/ace/snippets/latex.js b/static/ace/snippets/latex.js similarity index 100% rename from ace/snippets/latex.js rename to static/ace/snippets/latex.js diff --git a/ace/snippets/lean.js b/static/ace/snippets/lean.js similarity index 100% rename from ace/snippets/lean.js rename to static/ace/snippets/lean.js diff --git a/ace/snippets/less.js b/static/ace/snippets/less.js similarity index 100% rename from ace/snippets/less.js rename to static/ace/snippets/less.js diff --git a/ace/snippets/liquid.js b/static/ace/snippets/liquid.js similarity index 100% rename from ace/snippets/liquid.js rename to static/ace/snippets/liquid.js diff --git a/ace/snippets/lisp.js b/static/ace/snippets/lisp.js similarity index 100% rename from ace/snippets/lisp.js rename to static/ace/snippets/lisp.js diff --git a/ace/snippets/live_script.js b/static/ace/snippets/live_script.js similarity index 100% rename from ace/snippets/live_script.js rename to static/ace/snippets/live_script.js diff --git a/ace/snippets/livescript.js b/static/ace/snippets/livescript.js similarity index 100% rename from ace/snippets/livescript.js rename to static/ace/snippets/livescript.js diff --git a/ace/snippets/logiql.js b/static/ace/snippets/logiql.js similarity index 100% rename from ace/snippets/logiql.js rename to static/ace/snippets/logiql.js diff --git a/ace/snippets/lsl.js b/static/ace/snippets/lsl.js similarity index 100% rename from ace/snippets/lsl.js rename to static/ace/snippets/lsl.js diff --git a/ace/snippets/lua.js b/static/ace/snippets/lua.js similarity index 100% rename from ace/snippets/lua.js rename to static/ace/snippets/lua.js diff --git a/ace/snippets/luapage.js b/static/ace/snippets/luapage.js similarity index 100% rename from ace/snippets/luapage.js rename to static/ace/snippets/luapage.js diff --git a/ace/snippets/lucene.js b/static/ace/snippets/lucene.js similarity index 100% rename from ace/snippets/lucene.js rename to static/ace/snippets/lucene.js diff --git a/ace/snippets/makefile.js b/static/ace/snippets/makefile.js similarity index 100% rename from ace/snippets/makefile.js rename to static/ace/snippets/makefile.js diff --git a/ace/snippets/markdown.js b/static/ace/snippets/markdown.js similarity index 100% rename from ace/snippets/markdown.js rename to static/ace/snippets/markdown.js diff --git a/ace/snippets/mask.js b/static/ace/snippets/mask.js similarity index 100% rename from ace/snippets/mask.js rename to static/ace/snippets/mask.js diff --git a/ace/snippets/matlab.js b/static/ace/snippets/matlab.js similarity index 100% rename from ace/snippets/matlab.js rename to static/ace/snippets/matlab.js diff --git a/ace/snippets/maze.js b/static/ace/snippets/maze.js similarity index 100% rename from ace/snippets/maze.js rename to static/ace/snippets/maze.js diff --git a/ace/snippets/mel.js b/static/ace/snippets/mel.js similarity index 100% rename from ace/snippets/mel.js rename to static/ace/snippets/mel.js diff --git a/ace/snippets/mips_assembler.js b/static/ace/snippets/mips_assembler.js similarity index 100% rename from ace/snippets/mips_assembler.js rename to static/ace/snippets/mips_assembler.js diff --git a/ace/snippets/mipsassembler.js b/static/ace/snippets/mipsassembler.js similarity index 100% rename from ace/snippets/mipsassembler.js rename to static/ace/snippets/mipsassembler.js diff --git a/ace/snippets/mushcode.js b/static/ace/snippets/mushcode.js similarity index 100% rename from ace/snippets/mushcode.js rename to static/ace/snippets/mushcode.js diff --git a/ace/snippets/mysql.js b/static/ace/snippets/mysql.js similarity index 100% rename from ace/snippets/mysql.js rename to static/ace/snippets/mysql.js diff --git a/ace/snippets/nix.js b/static/ace/snippets/nix.js similarity index 100% rename from ace/snippets/nix.js rename to static/ace/snippets/nix.js diff --git a/ace/snippets/objectivec.js b/static/ace/snippets/objectivec.js similarity index 100% rename from ace/snippets/objectivec.js rename to static/ace/snippets/objectivec.js diff --git a/ace/snippets/ocaml.js b/static/ace/snippets/ocaml.js similarity index 100% rename from ace/snippets/ocaml.js rename to static/ace/snippets/ocaml.js diff --git a/ace/snippets/pascal.js b/static/ace/snippets/pascal.js similarity index 100% rename from ace/snippets/pascal.js rename to static/ace/snippets/pascal.js diff --git a/ace/snippets/perl.js b/static/ace/snippets/perl.js similarity index 100% rename from ace/snippets/perl.js rename to static/ace/snippets/perl.js diff --git a/ace/snippets/pgsql.js b/static/ace/snippets/pgsql.js similarity index 100% rename from ace/snippets/pgsql.js rename to static/ace/snippets/pgsql.js diff --git a/ace/snippets/php.js b/static/ace/snippets/php.js similarity index 100% rename from ace/snippets/php.js rename to static/ace/snippets/php.js diff --git a/ace/snippets/plain_text.js b/static/ace/snippets/plain_text.js similarity index 100% rename from ace/snippets/plain_text.js rename to static/ace/snippets/plain_text.js diff --git a/ace/snippets/powershell.js b/static/ace/snippets/powershell.js similarity index 100% rename from ace/snippets/powershell.js rename to static/ace/snippets/powershell.js diff --git a/ace/snippets/praat.js b/static/ace/snippets/praat.js similarity index 100% rename from ace/snippets/praat.js rename to static/ace/snippets/praat.js diff --git a/ace/snippets/prolog.js b/static/ace/snippets/prolog.js similarity index 100% rename from ace/snippets/prolog.js rename to static/ace/snippets/prolog.js diff --git a/ace/snippets/properties.js b/static/ace/snippets/properties.js similarity index 100% rename from ace/snippets/properties.js rename to static/ace/snippets/properties.js diff --git a/ace/snippets/protobuf.js b/static/ace/snippets/protobuf.js similarity index 100% rename from ace/snippets/protobuf.js rename to static/ace/snippets/protobuf.js diff --git a/ace/snippets/python.js b/static/ace/snippets/python.js similarity index 100% rename from ace/snippets/python.js rename to static/ace/snippets/python.js diff --git a/ace/snippets/r.js b/static/ace/snippets/r.js similarity index 100% rename from ace/snippets/r.js rename to static/ace/snippets/r.js diff --git a/ace/snippets/rdoc.js b/static/ace/snippets/rdoc.js similarity index 100% rename from ace/snippets/rdoc.js rename to static/ace/snippets/rdoc.js diff --git a/ace/snippets/rhtml.js b/static/ace/snippets/rhtml.js similarity index 100% rename from ace/snippets/rhtml.js rename to static/ace/snippets/rhtml.js diff --git a/ace/snippets/ruby.js b/static/ace/snippets/ruby.js similarity index 100% rename from ace/snippets/ruby.js rename to static/ace/snippets/ruby.js diff --git a/ace/snippets/rust.js b/static/ace/snippets/rust.js similarity index 100% rename from ace/snippets/rust.js rename to static/ace/snippets/rust.js diff --git a/ace/snippets/sass.js b/static/ace/snippets/sass.js similarity index 100% rename from ace/snippets/sass.js rename to static/ace/snippets/sass.js diff --git a/ace/snippets/scad.js b/static/ace/snippets/scad.js similarity index 100% rename from ace/snippets/scad.js rename to static/ace/snippets/scad.js diff --git a/ace/snippets/scala.js b/static/ace/snippets/scala.js similarity index 100% rename from ace/snippets/scala.js rename to static/ace/snippets/scala.js diff --git a/ace/snippets/scheme.js b/static/ace/snippets/scheme.js similarity index 100% rename from ace/snippets/scheme.js rename to static/ace/snippets/scheme.js diff --git a/ace/snippets/scss.js b/static/ace/snippets/scss.js similarity index 100% rename from ace/snippets/scss.js rename to static/ace/snippets/scss.js diff --git a/ace/snippets/sh.js b/static/ace/snippets/sh.js similarity index 100% rename from ace/snippets/sh.js rename to static/ace/snippets/sh.js diff --git a/ace/snippets/sjs.js b/static/ace/snippets/sjs.js similarity index 100% rename from ace/snippets/sjs.js rename to static/ace/snippets/sjs.js diff --git a/ace/snippets/smarty.js b/static/ace/snippets/smarty.js similarity index 100% rename from ace/snippets/smarty.js rename to static/ace/snippets/smarty.js diff --git a/ace/snippets/snippets.js b/static/ace/snippets/snippets.js similarity index 100% rename from ace/snippets/snippets.js rename to static/ace/snippets/snippets.js diff --git a/ace/snippets/soy_template.js b/static/ace/snippets/soy_template.js similarity index 100% rename from ace/snippets/soy_template.js rename to static/ace/snippets/soy_template.js diff --git a/ace/snippets/space.js b/static/ace/snippets/space.js similarity index 100% rename from ace/snippets/space.js rename to static/ace/snippets/space.js diff --git a/ace/snippets/sql.js b/static/ace/snippets/sql.js similarity index 100% rename from ace/snippets/sql.js rename to static/ace/snippets/sql.js diff --git a/ace/snippets/sqlserver.js b/static/ace/snippets/sqlserver.js similarity index 100% rename from ace/snippets/sqlserver.js rename to static/ace/snippets/sqlserver.js diff --git a/ace/snippets/stylus.js b/static/ace/snippets/stylus.js similarity index 100% rename from ace/snippets/stylus.js rename to static/ace/snippets/stylus.js diff --git a/ace/snippets/svg.js b/static/ace/snippets/svg.js similarity index 100% rename from ace/snippets/svg.js rename to static/ace/snippets/svg.js diff --git a/ace/snippets/tcl.js b/static/ace/snippets/tcl.js similarity index 100% rename from ace/snippets/tcl.js rename to static/ace/snippets/tcl.js diff --git a/ace/snippets/tex.js b/static/ace/snippets/tex.js similarity index 100% rename from ace/snippets/tex.js rename to static/ace/snippets/tex.js diff --git a/ace/snippets/text.js b/static/ace/snippets/text.js similarity index 100% rename from ace/snippets/text.js rename to static/ace/snippets/text.js diff --git a/ace/snippets/textile.js b/static/ace/snippets/textile.js similarity index 100% rename from ace/snippets/textile.js rename to static/ace/snippets/textile.js diff --git a/ace/snippets/toml.js b/static/ace/snippets/toml.js similarity index 100% rename from ace/snippets/toml.js rename to static/ace/snippets/toml.js diff --git a/ace/snippets/twig.js b/static/ace/snippets/twig.js similarity index 100% rename from ace/snippets/twig.js rename to static/ace/snippets/twig.js diff --git a/ace/snippets/typescript.js b/static/ace/snippets/typescript.js similarity index 100% rename from ace/snippets/typescript.js rename to static/ace/snippets/typescript.js diff --git a/ace/snippets/vala.js b/static/ace/snippets/vala.js similarity index 100% rename from ace/snippets/vala.js rename to static/ace/snippets/vala.js diff --git a/ace/snippets/vbscript.js b/static/ace/snippets/vbscript.js similarity index 100% rename from ace/snippets/vbscript.js rename to static/ace/snippets/vbscript.js diff --git a/ace/snippets/velocity.js b/static/ace/snippets/velocity.js similarity index 100% rename from ace/snippets/velocity.js rename to static/ace/snippets/velocity.js diff --git a/ace/snippets/verilog.js b/static/ace/snippets/verilog.js similarity index 100% rename from ace/snippets/verilog.js rename to static/ace/snippets/verilog.js diff --git a/ace/snippets/vhdl.js b/static/ace/snippets/vhdl.js similarity index 100% rename from ace/snippets/vhdl.js rename to static/ace/snippets/vhdl.js diff --git a/ace/snippets/xml.js b/static/ace/snippets/xml.js similarity index 100% rename from ace/snippets/xml.js rename to static/ace/snippets/xml.js diff --git a/ace/snippets/xquery.js b/static/ace/snippets/xquery.js similarity index 100% rename from ace/snippets/xquery.js rename to static/ace/snippets/xquery.js diff --git a/ace/snippets/yaml.js b/static/ace/snippets/yaml.js similarity index 100% rename from ace/snippets/yaml.js rename to static/ace/snippets/yaml.js diff --git a/ace/theme-ambiance.js b/static/ace/theme-ambiance.js similarity index 100% rename from ace/theme-ambiance.js rename to static/ace/theme-ambiance.js diff --git a/ace/theme-chaos.js b/static/ace/theme-chaos.js similarity index 100% rename from ace/theme-chaos.js rename to static/ace/theme-chaos.js diff --git a/ace/theme-chrome.js b/static/ace/theme-chrome.js similarity index 100% rename from ace/theme-chrome.js rename to static/ace/theme-chrome.js diff --git a/ace/theme-clouds.js b/static/ace/theme-clouds.js similarity index 100% rename from ace/theme-clouds.js rename to static/ace/theme-clouds.js diff --git a/ace/theme-clouds_midnight.js b/static/ace/theme-clouds_midnight.js similarity index 100% rename from ace/theme-clouds_midnight.js rename to static/ace/theme-clouds_midnight.js diff --git a/ace/theme-cobalt.js b/static/ace/theme-cobalt.js similarity index 100% rename from ace/theme-cobalt.js rename to static/ace/theme-cobalt.js diff --git a/ace/theme-crimson_editor.js b/static/ace/theme-crimson_editor.js similarity index 100% rename from ace/theme-crimson_editor.js rename to static/ace/theme-crimson_editor.js diff --git a/ace/theme-dawn.js b/static/ace/theme-dawn.js similarity index 100% rename from ace/theme-dawn.js rename to static/ace/theme-dawn.js diff --git a/ace/theme-dreamweaver.js b/static/ace/theme-dreamweaver.js similarity index 100% rename from ace/theme-dreamweaver.js rename to static/ace/theme-dreamweaver.js diff --git a/ace/theme-eclipse.js b/static/ace/theme-eclipse.js similarity index 100% rename from ace/theme-eclipse.js rename to static/ace/theme-eclipse.js diff --git a/ace/theme-github.js b/static/ace/theme-github.js similarity index 100% rename from ace/theme-github.js rename to static/ace/theme-github.js diff --git a/ace/theme-idle_fingers.js b/static/ace/theme-idle_fingers.js similarity index 100% rename from ace/theme-idle_fingers.js rename to static/ace/theme-idle_fingers.js diff --git a/ace/theme-iplastic.js b/static/ace/theme-iplastic.js similarity index 100% rename from ace/theme-iplastic.js rename to static/ace/theme-iplastic.js diff --git a/ace/theme-katzenmilch.js b/static/ace/theme-katzenmilch.js similarity index 100% rename from ace/theme-katzenmilch.js rename to static/ace/theme-katzenmilch.js diff --git a/ace/theme-kr_theme.js b/static/ace/theme-kr_theme.js similarity index 100% rename from ace/theme-kr_theme.js rename to static/ace/theme-kr_theme.js diff --git a/ace/theme-kuroir.js b/static/ace/theme-kuroir.js similarity index 100% rename from ace/theme-kuroir.js rename to static/ace/theme-kuroir.js diff --git a/ace/theme-merbivore.js b/static/ace/theme-merbivore.js similarity index 100% rename from ace/theme-merbivore.js rename to static/ace/theme-merbivore.js diff --git a/ace/theme-merbivore_soft.js b/static/ace/theme-merbivore_soft.js similarity index 100% rename from ace/theme-merbivore_soft.js rename to static/ace/theme-merbivore_soft.js diff --git a/ace/theme-mono_industrial.js b/static/ace/theme-mono_industrial.js similarity index 100% rename from ace/theme-mono_industrial.js rename to static/ace/theme-mono_industrial.js diff --git a/ace/theme-monokai.js b/static/ace/theme-monokai.js similarity index 100% rename from ace/theme-monokai.js rename to static/ace/theme-monokai.js diff --git a/ace/theme-pastel_on_dark.js b/static/ace/theme-pastel_on_dark.js similarity index 100% rename from ace/theme-pastel_on_dark.js rename to static/ace/theme-pastel_on_dark.js diff --git a/ace/theme-solarized_dark.js b/static/ace/theme-solarized_dark.js similarity index 100% rename from ace/theme-solarized_dark.js rename to static/ace/theme-solarized_dark.js diff --git a/ace/theme-solarized_light.js b/static/ace/theme-solarized_light.js similarity index 100% rename from ace/theme-solarized_light.js rename to static/ace/theme-solarized_light.js diff --git a/ace/theme-sqlserver.js b/static/ace/theme-sqlserver.js similarity index 100% rename from ace/theme-sqlserver.js rename to static/ace/theme-sqlserver.js diff --git a/ace/theme-terminal.js b/static/ace/theme-terminal.js similarity index 100% rename from ace/theme-terminal.js rename to static/ace/theme-terminal.js diff --git a/ace/theme-textmate.js b/static/ace/theme-textmate.js similarity index 100% rename from ace/theme-textmate.js rename to static/ace/theme-textmate.js diff --git a/ace/theme-tomorrow.js b/static/ace/theme-tomorrow.js similarity index 100% rename from ace/theme-tomorrow.js rename to static/ace/theme-tomorrow.js diff --git a/ace/theme-tomorrow_night.js b/static/ace/theme-tomorrow_night.js similarity index 100% rename from ace/theme-tomorrow_night.js rename to static/ace/theme-tomorrow_night.js diff --git a/ace/theme-tomorrow_night_blue.js b/static/ace/theme-tomorrow_night_blue.js similarity index 100% rename from ace/theme-tomorrow_night_blue.js rename to static/ace/theme-tomorrow_night_blue.js diff --git a/ace/theme-tomorrow_night_bright.js b/static/ace/theme-tomorrow_night_bright.js similarity index 100% rename from ace/theme-tomorrow_night_bright.js rename to static/ace/theme-tomorrow_night_bright.js diff --git a/ace/theme-tomorrow_night_eighties.js b/static/ace/theme-tomorrow_night_eighties.js similarity index 100% rename from ace/theme-tomorrow_night_eighties.js rename to static/ace/theme-tomorrow_night_eighties.js diff --git a/ace/theme-twilight.js b/static/ace/theme-twilight.js similarity index 100% rename from ace/theme-twilight.js rename to static/ace/theme-twilight.js diff --git a/ace/theme-vibrant_ink.js b/static/ace/theme-vibrant_ink.js similarity index 100% rename from ace/theme-vibrant_ink.js rename to static/ace/theme-vibrant_ink.js diff --git a/ace/theme-xcode.js b/static/ace/theme-xcode.js similarity index 100% rename from ace/theme-xcode.js rename to static/ace/theme-xcode.js diff --git a/ace/worker-coffee.js b/static/ace/worker-coffee.js similarity index 100% rename from ace/worker-coffee.js rename to static/ace/worker-coffee.js diff --git a/ace/worker-css.js b/static/ace/worker-css.js similarity index 100% rename from ace/worker-css.js rename to static/ace/worker-css.js diff --git a/ace/worker-html.js b/static/ace/worker-html.js similarity index 100% rename from ace/worker-html.js rename to static/ace/worker-html.js diff --git a/ace/worker-javascript.js b/static/ace/worker-javascript.js similarity index 100% rename from ace/worker-javascript.js rename to static/ace/worker-javascript.js diff --git a/ace/worker-json.js b/static/ace/worker-json.js similarity index 100% rename from ace/worker-json.js rename to static/ace/worker-json.js diff --git a/ace/worker-lua.js b/static/ace/worker-lua.js similarity index 100% rename from ace/worker-lua.js rename to static/ace/worker-lua.js diff --git a/ace/worker-php.js b/static/ace/worker-php.js similarity index 100% rename from ace/worker-php.js rename to static/ace/worker-php.js diff --git a/ace/worker-xml.js b/static/ace/worker-xml.js similarity index 100% rename from ace/worker-xml.js rename to static/ace/worker-xml.js diff --git a/ace/worker-xquery.js b/static/ace/worker-xquery.js similarity index 100% rename from ace/worker-xquery.js rename to static/ace/worker-xquery.js From af858c04a03eeede34a9e620924509a08ef8d2ed Mon Sep 17 00:00:00 2001 From: William Mayor Date: Mon, 28 Nov 2016 11:55:17 +0000 Subject: [PATCH 02/38] Move python JS code into JS dir --- python-main.js => static/js/python-main.js | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename python-main.js => static/js/python-main.js (100%) diff --git a/python-main.js b/static/js/python-main.js similarity index 100% rename from python-main.js rename to static/js/python-main.js From 70e5b3a0296a58b0e4acbcabd744208e14441430 Mon Sep 17 00:00:00 2001 From: William Mayor Date: Mon, 28 Nov 2016 11:55:31 +0000 Subject: [PATCH 03/38] Move html files into template dir --- editor.html => templates/editor.html | 18 +++++++++--------- help.html => templates/help.html | 0 2 files changed, 9 insertions(+), 9 deletions(-) rename editor.html => templates/editor.html (99%) rename help.html => templates/help.html (100%) diff --git a/editor.html b/templates/editor.html similarity index 99% rename from editor.html rename to templates/editor.html index aff11bbd..c99865fe 100644 --- a/editor.html +++ b/templates/editor.html @@ -1,12 +1,12 @@ - - - - + From f0227327b9eac35bbca161711b3db0af5ec066ff Mon Sep 17 00:00:00 2001 From: William Mayor Date: Mon, 28 Nov 2016 11:56:41 +0000 Subject: [PATCH 07/38] Update getting started directions for new flask app --- README.rst | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/README.rst b/README.rst index f3f14e63..645e0c74 100644 --- a/README.rst +++ b/README.rst @@ -9,27 +9,25 @@ BBC's micro:bit device (https://en.wikipedia.org/wiki/Micro_Bit). Developer Setup --------------- -This editor works with any modern web browser. +This editor works with any modern web browser. These instructions assume that you have Python 3 installed and you're using some kind of UNIX-y system. If you're on Windows, no fear, all of this is acheivable, you'll just have to tweak the commands slightly. -Assuming you have Python 3 installed you can serve the editor like this:: +Virtual Environment ++++++++++++++++++++ - $ ./show.sh - http://localhost:8000/editor.html - Serving HTTP on 0.0.0.0 port 8000 ... +We're going to create a virtual environment for the Python code to live in. This environment will keep the work you do on this project separate from the rest of your projects. This can be really handy when you have several projects on your computer that all want to use slightly different versions of libraries:: -As the script tells us, point your browser to http://localhost:8000/editor.html. + $ pyvenv venv + (venv) $ source venv/bin/activate + (venv) $ pip install -r requirements.txt -It's also possible to run the editor directly from the file system like this, -for example:: +Running the Code +++++++++++++++++ - $ firefox editor.html +Easy peasy:: -Or by double-clicking on the ``editor.html`` file from your file manager. + (venv) $ python app.py -**IMPORTANT**: When the editor is run from the file system, the "sharing" -button is hidden. Because of security reasons, many local browsers won't allow -it to function correctly unless the editor is properly served from a network -domain rather than directly from the file system. +Then visit http://localhost:5000 to see the editor. Tests +++++ From 1d07d1d1c111948568b085aee7c0f8f8299f42c4 Mon Sep 17 00:00:00 2001 From: William Mayor Date: Mon, 28 Nov 2016 12:22:29 +0000 Subject: [PATCH 08/38] Fix references to static assets --- templates/help.html | 58 ++++++++++++++++++++++----------------------- 1 file changed, 29 insertions(+), 29 deletions(-) diff --git a/templates/help.html b/templates/help.html index e033880b..cf34f768 100644 --- a/templates/help.html +++ b/templates/help.html @@ -7,20 +7,20 @@ - + Python on the BBC micro:bit - + - - + + - + - - + + - - + + From 29577e3fd89b91257decce08b0c947317deececd Mon Sep 17 00:00:00 2001 From: William Mayor Date: Mon, 28 Nov 2016 12:22:51 +0000 Subject: [PATCH 09/38] Add placeholder buttons for new collaboration features --- static/js/python-main.js | 121 ++++++++++++--------------------------- templates/editor.html | 30 ++++++---- 2 files changed, 57 insertions(+), 94 deletions(-) diff --git a/static/js/python-main.js b/static/js/python-main.js index e319ee5d..e455ee0a 100644 --- a/static/js/python-main.js +++ b/static/js/python-main.js @@ -13,13 +13,13 @@ is attached to the div with the referenced id. */ function pythonEditor(id) { // An object that encapsulates the behaviour of the editor. - editor = {}; + var editor = {}; // Represents the ACE based editor. var ACE = ace.edit(id); // The editor is in the tag with the referenced id. ACE.setOptions({ enableSnippets: true // Enable code snippets. - }) + }); ACE.setTheme("ace/theme/kr_theme"); // Make it look nice. ACE.getSession().setMode("ace/mode/python"); // We're editing Python. ACE.getSession().setTabSize(4); // Tab=4 spaces. @@ -39,10 +39,10 @@ function pythonEditor(id) { // Give the editor user input focus. editor.focus = function() { ACE.focus(); - } + }; // Set a handler function to be run if code in the editor changes. - editor.on_change = function(handler) { + editor.onChange = function(handler) { ACE.getSession().on('change', handler); }; @@ -55,7 +55,7 @@ function pythonEditor(id) { // Triggers a snippet by name in the editor. editor.triggerSnippet = function(snippet) { var snippetManager = ace.require("ace/snippets").snippetManager; - var snippet = snippetManager.snippetNameMap.python[snippet]; + snippet = snippetManager.snippetNameMap.python[snippet]; if(snippet) { snippetManager.insertSnippet(ACE, snippet.content); } @@ -107,7 +107,7 @@ function pythonEditor(id) { checksum += chunk[j]; } chunk[4 + 16] = (-checksum) & 0xff; - output.push(':' + hexlify(chunk).toUpperCase()) + output.push(':' + hexlify(chunk).toUpperCase()); } return output.join('\n'); }; @@ -117,7 +117,7 @@ function pythonEditor(id) { var hexlified_python = this.hexlify(this.getCode()); var insertion_point = ":::::::::::::::::::::::::::::::::::::::::::"; return firmware.replace(insertion_point, hexlified_python); - } + }; // Takes a hex blob and turns it into a decoded string. editor.unhexlify = function(data) { @@ -144,7 +144,7 @@ function pythonEditor(id) { } else { return ''; } - } + }; // Given an existing hex file, return the Python script contained therein. editor.extractScript = function(hexfile) { @@ -153,7 +153,7 @@ function pythonEditor(id) { if (start_line > 0) { var lines = hex_lines.slice(start_line + 1, -2); var blob = lines.join('\n'); - if (blob=='') { + if (blob === '') { return ''; } else { return this.unhexlify(blob); @@ -161,10 +161,10 @@ function pythonEditor(id) { } else { return ''; } - } + }; return editor; -}; +} /* The following code contains the various functions that connect the behaviour of @@ -215,7 +215,7 @@ function web_editor() { fontSize = 46; } setFontSize(fontSize); - }; + } // Sets up the zoom-out functionality. function zoomOut() { @@ -225,7 +225,7 @@ function web_editor() { fontSize = 22; } setFontSize(fontSize); - }; + } // This function is called by TouchDevelop to cause the editor to be initialised. It sets things up so the user sees their code or, in the case of a new program, uses some sane defaults. function setupEditor(message) { @@ -233,7 +233,7 @@ function web_editor() { EDITOR = pythonEditor('editor'); if(!message.name) { // If there's no name, default to something sensible. - setName("microbit") + setName("microbit"); } else { setName(message.name); } @@ -266,7 +266,7 @@ function web_editor() { }); window.setTimeout(function () { // What to do if the user changes the content of the editor. - EDITOR.on_change(function () { + EDITOR.onChange(function () { dirty = true; }); }, 1); @@ -286,12 +286,6 @@ function web_editor() { return confirmationMessage; } }); - // Bind the ESCAPE key. - $(document).keyup(function(e) { - if (e.keyCode == 27) { // ESCAPE - $('#link-log').focus(); - } - }); // Bind drag and drop into editor. $('#editor').on('dragover', function(e) { e.preventDefault(); @@ -302,8 +296,6 @@ function web_editor() { e.stopPropagation(); }); $('#editor').on('drop', doDrop); - // Focus on the element with TAB-STATE=1 - $("#command-download").focus(); } // This function describes what to do when the download button is clicked. @@ -323,17 +315,18 @@ function web_editor() { // This function describes what to do when the save button is clicked. function doSave() { - var output = EDITOR.getCode(); - var ua = navigator.userAgent.toLowerCase(); - if((ua.indexOf('safari/') > -1) && (ua.indexOf('chrome') == -1)) { - alert("Safari has a bug that means your work will be downloaded as an un-named file. Please rename it to something ending in .py. Alternatively, use a browser such as Firefox or Chrome. They do not suffer from this bug."); - window.open('data:application/octet;charset=utf-8,' + encodeURIComponent(output), '_newtab'); - } else { - var filename = getName().replace(" ", "_"); - var blob = new Blob([output], {type: "text/plain"}); - saveAs(blob, filename + ".py"); - } - dirty = false; + // TODO: Push code into new gist, forking the current gist if available + } + + // This function describes what to do when the load button is clicked. + function doLoad() { + // TODO: Display a modal that asks for a gist URL to load + } + + // This function describes what to do when the explore button is clicked. + function doExplore() { + // TODO: Open a modal that shows the forks of the current gist + // TODO: If no gist is loaded then show the load modal first } // This function describes what to do when the snippets button is clicked. @@ -351,9 +344,9 @@ function web_editor() { description = name.substring(name.indexOf(' - '), name.length); return description.replace(' - ', ''); - } + }; } - } + }; vex.open({ content: Mustache.render(template, context), afterOpen: function(vexContent) { @@ -367,37 +360,6 @@ function web_editor() { }); } - function doShare() { - // Triggered when the user wants to generate a link to share their code. - var template = $('#share-template').html(); - Mustache.parse(template); - var qs_array = []; - qs_array.push('name=' + encodeURIComponent(getName())); - qs_array.push('comment=' + encodeURIComponent(getDescription())); - qs_array.push('code=' + encodeURIComponent(EDITOR.getCode())); - var old_url = window.location.href.split('?'); - var new_url = old_url[0].replace('#', '') + '?' + qs_array.join('&'); - // shortener API - var url = "https://www.googleapis.com/urlshortener/v1/url?key=AIzaSyB2_Cwh5lKUX4a681ZERd3FAt8ijdwbukk"; - $.ajax(url, { - type: "POST", - contentType: 'application/json', - data: JSON.stringify({ - longUrl: new_url - }) - }).done(function( data ) { - console.log(data); - vex.open({ - content: Mustache.render(template, {}) - }) - $('#direct-link').attr('href', data.id); - $('#direct-link').text(data.id); - $('#twitter-button').html(''); - $('#facebook-button').attr('src', 'https://www.facebook.com/plugins/share_button.php?href=' + encodeURIComponent(data.id) + '&layout=button&size=small&mobile_iframe=true&width=59&height=20&appId'); - twttr.widgets.load(); - }); - } - function doDrop(e) { // Triggered when a user drops a file onto the editor. e.stopPropagation(); @@ -410,7 +372,7 @@ function web_editor() { setDescription('Extracted from a Python file'); reader.onload = function(e) { EDITOR.setCode(e.target.result); - } + }; reader.readAsText(file); EDITOR.ACE.gotoLine(EDITOR.ACE.session.getLength()); } else if (ext == 'hex') { @@ -421,7 +383,7 @@ function web_editor() { if (code.length < 8192) { EDITOR.setCode(code); } - } + }; reader.readAsText(file); EDITOR.ACE.gotoLine(EDITOR.ACE.session.getLength()); } @@ -430,24 +392,17 @@ function web_editor() { // Join up the buttons in the user interface with some functions for handling what to do when they're clicked. function setupButtons() { - $("#command-download").click(function () { - doDownload(); - }); - $("#command-save").click(function () { - doSave(); - }); - $("#command-snippet").click(function () { - doSnippets(); - }); - $("#command-share").click(function () { - doShare(); - }); + $("#command-download").click(doDownload); + $("#command-save").click(doSave); + $("#command-load").click(doLoad); + $("#command-explore").click(doExplore); + $("#command-snippet").click(doSnippets); } // Extracts the query string and turns it into an object of key/value pairs. function get_qs_context() { var query_string = window.location.search.substring(1); - if(window.location.href.indexOf("file://") == 0 ) { + if(window.location.href.indexOf("file://") === 0 ) { // Running from the local file system so switch off network share. $('#command-share').hide(); return {}; @@ -463,7 +418,7 @@ function web_editor() { setupEditor(get_qs_context()); setupButtons(); -}; +} // Call the web_editor function to start the editor running. web_editor(); diff --git a/templates/editor.html b/templates/editor.html index c99865fe..d0200464 100644 --- a/templates/editor.html +++ b/templates/editor.html @@ -111,14 +111,30 @@

Share Code

Download
- + title="Load some Python code from a gist">
+
Load
+
+ +
+ +
Save
+ +
+ +
+
Explore
+
@@ -127,7 +143,7 @@

Share Code

Snippets
-
@@ -135,14 +151,6 @@

Share Code

Help
- -
- -
-
Share
-
From 89ba349bbb8cf9c0640bdd9f0f3c6ee2d858bda5 Mon Sep 17 00:00:00 2001 From: William Mayor Date: Mon, 28 Nov 2016 12:40:59 +0000 Subject: [PATCH 10/38] Remove old share code --- static/js/python-main.js | 5 ----- templates/editor.html | 14 +++----------- 2 files changed, 3 insertions(+), 16 deletions(-) diff --git a/static/js/python-main.js b/static/js/python-main.js index e455ee0a..1c7d3ee3 100644 --- a/static/js/python-main.js +++ b/static/js/python-main.js @@ -402,11 +402,6 @@ function web_editor() { // Extracts the query string and turns it into an object of key/value pairs. function get_qs_context() { var query_string = window.location.search.substring(1); - if(window.location.href.indexOf("file://") === 0 ) { - // Running from the local file system so switch off network share. - $('#command-share').hide(); - return {}; - } var kv_pairs = query_string.split('&'); var result = {}; for (var i = 0; i < kv_pairs.length; i++) { diff --git a/templates/editor.html b/templates/editor.html index d0200464..87beb6ed 100644 --- a/templates/editor.html +++ b/templates/editor.html @@ -90,14 +90,6 @@

Code Snippets

{% endraw %} - -
@@ -105,9 +97,9 @@

Share Code

tabindex="1" title="Download a hex file to flash onto your micro:bit">
- - - + + +
Download
From 59914184581a26d436f1749356a0ae7bb62b5115 Mon Sep 17 00:00:00 2001 From: Alastair Flynn Date: Tue, 29 Nov 2016 16:53:37 +0000 Subject: [PATCH 11/38] Add files via upload From c9eb897447561ed3e968ff9afe9926c20a089a82 Mon Sep 17 00:00:00 2001 From: Ben Dent Date: Tue, 29 Nov 2016 16:54:57 +0000 Subject: [PATCH 12/38] Added load functionality from Gist and removed useless files --- static/js/python-main.js | 13 +++++++++++++ templates/editor.html | 5 ++++- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/static/js/python-main.js b/static/js/python-main.js index 1c7d3ee3..444cfc24 100644 --- a/static/js/python-main.js +++ b/static/js/python-main.js @@ -321,6 +321,19 @@ function web_editor() { // This function describes what to do when the load button is clicked. function doLoad() { // TODO: Display a modal that asks for a gist URL to load + var url = window.prompt("GIST URL"); + // var url = 'https://gist.github.com/ben-dent/8c8f0625d99fe2841d45ebe1b5d0b8c9'; + var id = url.split('/').pop(); + var githubAPI = 'https://api.github.com/gists/' + id; + + $.getJSON(githubAPI, function(data){ + var unsplit = data.files["microbit.py"].content; + var split = unsplit.split('#~*'); + EDITOR.setCode(split[0]); + var header = split[1].split(','); + setDescription(header[0]); + setName(header[1]); + }); } // This function describes what to do when the explore button is clicked. diff --git a/templates/editor.html b/templates/editor.html index 87beb6ed..276d6420 100644 --- a/templates/editor.html +++ b/templates/editor.html @@ -101,9 +101,10 @@

Code Snippets

-
Download
+
Billy
@@ -186,6 +187,8 @@

Code Snippets

charset="utf-8"> + From 607c13bf2cc649d07170417de831a9293d8a4458 Mon Sep 17 00:00:00 2001 From: Ben Dent Date: Tue, 29 Nov 2016 17:02:21 +0000 Subject: [PATCH 13/38] Revert "Added load functionality from Gist" This reverts commit 25c90a4054a229f2eb967b6d910107c7c09b2167. --- static/js/python-main.js | 13 ------------- templates/editor.html | 5 +---- 2 files changed, 1 insertion(+), 17 deletions(-) diff --git a/static/js/python-main.js b/static/js/python-main.js index 444cfc24..1c7d3ee3 100644 --- a/static/js/python-main.js +++ b/static/js/python-main.js @@ -321,19 +321,6 @@ function web_editor() { // This function describes what to do when the load button is clicked. function doLoad() { // TODO: Display a modal that asks for a gist URL to load - var url = window.prompt("GIST URL"); - // var url = 'https://gist.github.com/ben-dent/8c8f0625d99fe2841d45ebe1b5d0b8c9'; - var id = url.split('/').pop(); - var githubAPI = 'https://api.github.com/gists/' + id; - - $.getJSON(githubAPI, function(data){ - var unsplit = data.files["microbit.py"].content; - var split = unsplit.split('#~*'); - EDITOR.setCode(split[0]); - var header = split[1].split(','); - setDescription(header[0]); - setName(header[1]); - }); } // This function describes what to do when the explore button is clicked. diff --git a/templates/editor.html b/templates/editor.html index 276d6420..87beb6ed 100644 --- a/templates/editor.html +++ b/templates/editor.html @@ -101,10 +101,9 @@

Code Snippets

-
Billy
+
Download
@@ -187,8 +186,6 @@

Code Snippets

charset="utf-8"> - From 87b904fb863b2e9be942f197f6c801dc0e818ff8 Mon Sep 17 00:00:00 2001 From: Ben Dent Date: Tue, 29 Nov 2016 17:06:32 +0000 Subject: [PATCH 14/38] Ignoring extra files --- .gitignore | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitignore b/.gitignore index 94996699..536ffa97 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,5 @@ *.swp venv +.DS_Store +.spyproject/ +foundation-6.2.4-complete/ From da9417232ec9c82cc458ae0e70c2212c997932f4 Mon Sep 17 00:00:00 2001 From: Ben Dent Date: Tue, 29 Nov 2016 17:09:24 +0000 Subject: [PATCH 15/38] Added load functionality from gist --- static/js/python-main.js | 15 ++++++++++++++- templates/editor.html | 7 +++++-- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/static/js/python-main.js b/static/js/python-main.js index 1c7d3ee3..b1091748 100644 --- a/static/js/python-main.js +++ b/static/js/python-main.js @@ -321,6 +321,19 @@ function web_editor() { // This function describes what to do when the load button is clicked. function doLoad() { // TODO: Display a modal that asks for a gist URL to load + var url = window.prompt("GIST URL"); + // var url = 'https://gist.github.com/ben-dent/8c8f0625d99fe2841d45ebe1b5d0b8c9'; + var id = url.split('/').pop(); + var githubAPI = 'https://api.github.com/gists/' + id; + + $.getJSON(githubAPI, function(data){ + var unsplit = data.files["microbit.py"].content; + var split = unsplit.split('#~*'); + EDITOR.setCode(split[0]); + var header = split[1].split(','); + setDescription(header[0]); + setName(header[1]); + }); } // This function describes what to do when the explore button is clicked. @@ -416,4 +429,4 @@ function web_editor() { } // Call the web_editor function to start the editor running. -web_editor(); +web_editor(); \ No newline at end of file diff --git a/templates/editor.html b/templates/editor.html index 87beb6ed..d3275bad 100644 --- a/templates/editor.html +++ b/templates/editor.html @@ -101,9 +101,10 @@

Code Snippets

-
Download
+
Billy
@@ -186,6 +187,8 @@

Code Snippets

charset="utf-8"> + @@ -15355,4 +15358,4 @@

Code Snippets

:00000001FF
- + \ No newline at end of file From 32c4aff94be43043d6bb8f6f79891a9fbe4e3278 Mon Sep 17 00:00:00 2001 From: Alastair Flynn Date: Tue, 29 Nov 2016 17:09:46 +0000 Subject: [PATCH 16/38] added functionality to save python code to gist. --- static/js/python-main.js | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/static/js/python-main.js b/static/js/python-main.js index 1c7d3ee3..7ecf415a 100644 --- a/static/js/python-main.js +++ b/static/js/python-main.js @@ -315,7 +315,28 @@ function web_editor() { // This function describes what to do when the save button is clicked. function doSave() { + console.log("works"); + var content = EDITOR.getCode() + "#~*" + getDescription() + "," + getName(); + console.error(content); + var gistpush = { + "description": getDescription(), + "public": true, + "files": { + "microbit.py": { + "content": content + } + } + }; + $.ajax({ + type: 'POST', + url: 'https://api.github.com/gists', + data: JSON.stringify(gistpush), + success: function(gist,message,raw){alert(gist.html_url)} + }); + + // TODO: Push code into new gist, forking the current gist if available + } // This function describes what to do when the load button is clicked. From 6e2ddcddea4006ef690c8003fbf94e4a0696fecc Mon Sep 17 00:00:00 2001 From: William Mayor Date: Wed, 30 Nov 2016 13:05:44 +0000 Subject: [PATCH 17/38] Use python-gist to add authenticated requests to GitHub API --- .gitignore | 2 ++ README.rst | 13 +++++++++ app.py | 68 +++++++++++++++++++++++++++++++++++++++++++++++- requirements.txt | 5 ++++ 4 files changed, 87 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 536ffa97..ee156db6 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,5 @@ venv .DS_Store .spyproject/ foundation-6.2.4-complete/ +config.py +__pycache__ diff --git a/README.rst b/README.rst index 645e0c74..b65972f3 100644 --- a/README.rst +++ b/README.rst @@ -29,6 +29,19 @@ Easy peasy:: Then visit http://localhost:5000 to see the editor. +Enabling Cloud Save/Fork Features ++++++++++++++++++++++++++++++++++ + +The code in the editor can be saved into the "cloud" using GitHub Gists. In order for this to work you have to create a "Personal Access Token" that will be used to authenticate against the GitHub API. See you GitHub account's settings pages for how to do this, you'll need to give your token the "gist" permission. + +Once you have a token you can either save in the environment like this: + + (venv) $ export GITHUB_API_TOKEN=XXX + +Or you can save it into a file called `config.py` that contains: + + GITHUB_API_TOKEN = "XXX" + Tests +++++ diff --git a/app.py b/app.py index 505d7fd9..f67c4fe7 100644 --- a/app.py +++ b/app.py @@ -1,7 +1,23 @@ -from flask import Flask, render_template +import os +import json + +import requests +from flask import Flask, render_template, jsonify, request +from gist import GistAPI app = Flask(__name__) +try: + app.config.from_object('config') +except ImportError: + pass + +if "GITHUB_API_TOKEN" in os.environ: + app.config.update(GITHUB_API_TOKEN=os.environ["GITHUB_API_TOKEN"]) + + +api = GistAPI(app.config["GITHUB_API_TOKEN"]) + @app.route("/") def editor(): @@ -13,5 +29,55 @@ def help(): return render_template("help.html") +@app.route("/create/", methods=["POST"]) +def create(): + content = request.get_json()["content"] + html_url = api.create( + desc="Gist containing micro python micro:bit code", + public=True, + files={"microbit.py": {"content": content}}) + gist_id = html_url.split("/").pop() + return jsonify(id=gist_id), 201 + + +@app.route("/fork//", methods=["GET"]) +def fork(gist_id): + resp = api.fork(gist_id) + html_url = resp.json()["html_url"] + gist_id = html_url.split("/").pop() + return jsonify(id=gist_id), 201 + + +@app.route("/load//") +def load(gist_id): + content = api.content(gist_id)["microbit.py"] + return jsonify(content=content) + + +@app.route("/save//", methods=["POST"]) +def save(gist_id): + content = request.get_json()["content"] + # We have to call this request manually because the gist api assumes that + # edits happen in the terminal (e.g. using vim) and are then git pushed + # back to GitHub. This isn't true in our case :( + req = requests.Request( + "PATCH", + "https://api.github.com/gists", + headers={ + "Accept-Encoding": "identity, deflate, compress, gzip", + "User-Agent": "python-requests/1.2.0", + "Accept": "application/vnd.github.v3.base64", + }, + params={'access_token': api.token}, + data=json.dumps({ + "files": {"microbit.py": { + "content": content + }} + }) + ) + api.send(req, gist_id) + return jsonify(status="OK") + + if __name__ == "__main__": app.run(debug=True) diff --git a/requirements.txt b/requirements.txt index 24fe5722..906e7a79 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,6 +1,11 @@ click==6.6 +docopt==0.6.2 Flask==0.11.1 itsdangerous==0.24 Jinja2==2.8 MarkupSafe==0.23 +python-gist==0.4.1 +python-gnupg==0.3.9 +requests==2.12.1 +simplejson==3.10.0 Werkzeug==0.11.11 From 5cea1f78aa24ef0a34d5bebcf0ce63f8ef5b56f5 Mon Sep 17 00:00:00 2001 From: Ben Dent Date: Wed, 30 Nov 2016 22:24:43 +0000 Subject: [PATCH 18/38] Teachers can now start a session and their work is saved in microbit.py. Students can not edit this file once they have joined and their work is saved in .py. E.g. John Doe's work would be saved in 'John Doe.py' --- static/css/jquery.modal.min.css | 1 + static/js/jquery.modal.min.js | 5 +++++ 2 files changed, 6 insertions(+) create mode 100644 static/css/jquery.modal.min.css create mode 100644 static/js/jquery.modal.min.js diff --git a/static/css/jquery.modal.min.css b/static/css/jquery.modal.min.css new file mode 100644 index 00000000..cd1e6ef8 --- /dev/null +++ b/static/css/jquery.modal.min.css @@ -0,0 +1 @@ +.blocker{position:fixed;top:0;right:0;bottom:0;left:0;width:100%;height:100%;overflow:auto;z-index:1;padding:20px;box-sizing:border-box;background-color:#000;background-color:rgba(0,0,0,0.75);text-align:center}.blocker:before{content:"";display:inline-block;height:100%;vertical-align:middle;margin-right:-0.05em}.blocker.behind{background-color:transparent}.modal{display:inline-block;vertical-align:middle;position:relative;z-index:2;max-width:500px;box-sizing:border-box;width:90%;background:#fff;padding:15px 30px;-webkit-border-radius:8px;-moz-border-radius:8px;-o-border-radius:8px;-ms-border-radius:8px;border-radius:8px;-webkit-box-shadow:0 0 10px #000;-moz-box-shadow:0 0 10px #000;-o-box-shadow:0 0 10px #000;-ms-box-shadow:0 0 10px #000;box-shadow:0 0 10px #000;text-align:left}.modal a.close-modal{position:absolute;top:-12.5px;right:-12.5px;display:block;width:30px;height:30px;text-indent:-9999px;background:url("data:image/png;base64,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") no-repeat 0 0}.modal-spinner{display:none;width:64px;height:64px;position:fixed;top:50%;left:50%;margin-right:-32px;margin-top:-32px;background:url("data:image/gif;base64,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") #111 no-repeat center center;-webkit-border-radius:8px;-moz-border-radius:8px;-o-border-radius:8px;-ms-border-radius:8px;border-radius:8px} \ No newline at end of file diff --git a/static/js/jquery.modal.min.js b/static/js/jquery.modal.min.js new file mode 100644 index 00000000..44e2ddc2 --- /dev/null +++ b/static/js/jquery.modal.min.js @@ -0,0 +1,5 @@ +/* + A simple jQuery modal (http://github.com/kylefox/jquery-modal) + Version 0.8.0 +*/ +!function(o){"object"==typeof module&&"object"==typeof module.exports?o(require("jquery"),window,document):o(jQuery,window,document)}(function(o,t,e,i){var s=[],l=function(){return s.length?s[s.length-1]:null},n=function(){var o,t=!1;for(o=s.length-1;o>=0;o--)s[o].$blocker&&(s[o].$blocker.toggleClass("current",!t).toggleClass("behind",t),t=!0)};o.modal=function(t,e){var i,n;if(this.$body=o("body"),this.options=o.extend({},o.modal.defaults,e),this.options.doFade=!isNaN(parseInt(this.options.fadeDuration,10)),this.$blocker=null,this.options.closeExisting)for(;o.modal.isActive();)o.modal.close();if(s.push(this),t.is("a"))if(n=t.attr("href"),/^#/.test(n)){if(this.$elm=o(n),1!==this.$elm.length)return null;this.$body.append(this.$elm),this.open()}else this.$elm=o("
"),this.$body.append(this.$elm),i=function(o,t){t.elm.remove()},this.showSpinner(),t.trigger(o.modal.AJAX_SEND),o.get(n).done(function(e){if(o.modal.isActive()){t.trigger(o.modal.AJAX_SUCCESS);var s=l();s.$elm.empty().append(e).on(o.modal.CLOSE,i),s.hideSpinner(),s.open(),t.trigger(o.modal.AJAX_COMPLETE)}}).fail(function(){t.trigger(o.modal.AJAX_FAIL);var e=l();e.hideSpinner(),s.pop(),t.trigger(o.modal.AJAX_COMPLETE)});else this.$elm=t,this.$body.append(this.$elm),this.open()},o.modal.prototype={constructor:o.modal,open:function(){var t=this;this.block(),this.options.doFade?setTimeout(function(){t.show()},this.options.fadeDuration*this.options.fadeDelay):this.show(),o(e).off("keydown.modal").on("keydown.modal",function(o){var t=l();27==o.which&&t.options.escapeClose&&t.close()}),this.options.clickClose&&this.$blocker.click(function(t){t.target==this&&o.modal.close()})},close:function(){s.pop(),this.unblock(),this.hide(),o.modal.isActive()||o(e).off("keydown.modal")},block:function(){this.$elm.trigger(o.modal.BEFORE_BLOCK,[this._ctx()]),this.$body.css("overflow","hidden"),this.$blocker=o('
').appendTo(this.$body),n(),this.options.doFade&&this.$blocker.css("opacity",0).animate({opacity:1},this.options.fadeDuration),this.$elm.trigger(o.modal.BLOCK,[this._ctx()])},unblock:function(t){!t&&this.options.doFade?this.$blocker.fadeOut(this.options.fadeDuration,this.unblock.bind(this,!0)):(this.$blocker.children().appendTo(this.$body),this.$blocker.remove(),this.$blocker=null,n(),o.modal.isActive()||this.$body.css("overflow",""))},show:function(){this.$elm.trigger(o.modal.BEFORE_OPEN,[this._ctx()]),this.options.showClose&&(this.closeButton=o('
'+this.options.closeText+""),this.$elm.append(this.closeButton)),this.$elm.addClass(this.options.modalClass).appendTo(this.$blocker),this.options.doFade?this.$elm.css("opacity",0).show().animate({opacity:1},this.options.fadeDuration):this.$elm.show(),this.$elm.trigger(o.modal.OPEN,[this._ctx()])},hide:function(){this.$elm.trigger(o.modal.BEFORE_CLOSE,[this._ctx()]),this.closeButton&&this.closeButton.remove();var t=this;this.options.doFade?this.$elm.fadeOut(this.options.fadeDuration,function(){t.$elm.trigger(o.modal.AFTER_CLOSE,[t._ctx()])}):this.$elm.hide(0,function(){t.$elm.trigger(o.modal.AFTER_CLOSE,[t._ctx()])}),this.$elm.trigger(o.modal.CLOSE,[this._ctx()])},showSpinner:function(){this.options.showSpinner&&(this.spinner=this.spinner||o('
').append(this.options.spinnerHtml),this.$body.append(this.spinner),this.spinner.show())},hideSpinner:function(){this.spinner&&this.spinner.remove()},_ctx:function(){return{elm:this.$elm,$blocker:this.$blocker,options:this.options}}},o.modal.close=function(t){if(o.modal.isActive()){t&&t.preventDefault();var e=l();return e.close(),e.$elm}},o.modal.isActive=function(){return s.length>0},o.modal.getCurrent=l,o.modal.defaults={closeExisting:!0,escapeClose:!0,clickClose:!0,closeText:"Close",closeClass:"",modalClass:"modal",spinnerHtml:null,showSpinner:!0,showClose:!0,fadeDuration:null,fadeDelay:1},o.modal.BEFORE_BLOCK="modal:before-block",o.modal.BLOCK="modal:block",o.modal.BEFORE_OPEN="modal:before-open",o.modal.OPEN="modal:open",o.modal.BEFORE_CLOSE="modal:before-close",o.modal.CLOSE="modal:close",o.modal.AFTER_CLOSE="modal:after-close",o.modal.AJAX_SEND="modal:ajax:send",o.modal.AJAX_SUCCESS="modal:ajax:success",o.modal.AJAX_FAIL="modal:ajax:fail",o.modal.AJAX_COMPLETE="modal:ajax:complete",o.fn.modal=function(t){return 1===this.length&&new o.modal(this,t),this},o(e).on("click.modal",'a[rel~="modal:close"]',o.modal.close),o(e).on("click.modal",'a[rel~="modal:open"]',function(t){t.preventDefault(),o(this).modal()})}); \ No newline at end of file From 6b17e5154fdbfcb33ece58aed75265ae584d6882 Mon Sep 17 00:00:00 2001 From: Ben Dent Date: Wed, 30 Nov 2016 22:29:41 +0000 Subject: [PATCH 19/38] Adding the missing files to the last commit --- app.py | 30 +++++-------- static/css/style.css | 4 +- static/js/python-main.js | 94 ++++++++++++++++++++++++---------------- templates/editor.html | 14 +++--- 4 files changed, 74 insertions(+), 68 deletions(-) diff --git a/app.py b/app.py index f67c4fe7..d9144e94 100644 --- a/app.py +++ b/app.py @@ -24,38 +24,28 @@ def editor(): return render_template("editor.html") -@app.route("/help/") +@app.route("/help") def help(): return render_template("help.html") - -@app.route("/create/", methods=["POST"]) -def create(): +@app.route("/create/", methods=["POST"]) +def create(file_name): content = request.get_json()["content"] html_url = api.create( desc="Gist containing micro python micro:bit code", public=True, - files={"microbit.py": {"content": content}}) - gist_id = html_url.split("/").pop() - return jsonify(id=gist_id), 201 - - -@app.route("/fork//", methods=["GET"]) -def fork(gist_id): - resp = api.fork(gist_id) - html_url = resp.json()["html_url"] + files={file_name: {"content": content}}) gist_id = html_url.split("/").pop() return jsonify(id=gist_id), 201 - -@app.route("/load//") -def load(gist_id): - content = api.content(gist_id)["microbit.py"] +@app.route("/load///") +def load(gist_id, file_name): + content = api.content(gist_id)[file_name] return jsonify(content=content) -@app.route("/save//", methods=["POST"]) -def save(gist_id): +@app.route("/save//", methods=["POST"]) +def save(gist_id, file_name): content = request.get_json()["content"] # We have to call this request manually because the gist api assumes that # edits happen in the terminal (e.g. using vim) and are then git pushed @@ -70,7 +60,7 @@ def save(gist_id): }, params={'access_token': api.token}, data=json.dumps({ - "files": {"microbit.py": { + "files": {file_name: { "content": content }} }) diff --git a/static/css/style.css b/static/css/style.css index a46acd8c..ce7b0cc4 100644 --- a/static/css/style.css +++ b/static/css/style.css @@ -72,9 +72,7 @@ body, input { /* Script info box */ #script-box { margin-right: 1rem; - margin-left: 1rem; - text-align: right; - width: 100%; + margin-left: auto; } #script-name { diff --git a/static/js/python-main.js b/static/js/python-main.js index 01ad5f30..bcdb0472 100644 --- a/static/js/python-main.js +++ b/static/js/python-main.js @@ -177,24 +177,27 @@ function web_editor() { // Indicates if there are unsaved changes to the content of the editor. var dirty = false; + // Stores the latest gist link but this will be empty at start + var gistID = ""; + // Sets the description associated with the code displayed in the UI. function setDescription(x) { - $("#script-description").text(x); + $("#author").val(x); } // Sets the name associated with the code displayed in the UI. function setName(x) { - $("#script-name").text(x); + $("#name").val(x); } // Gets the description associated with the code displayed in the UI. function getDescription() { - return $("#script-description").text(); + return $("#author").val(); } // Gets the name associated with the code displayed in the UI. function getName() { - return $("#script-name").text(); + return $("#name").val(); } // Get the font size of the text currently displayed in the editor. @@ -233,13 +236,13 @@ function web_editor() { EDITOR = pythonEditor('editor'); if(!message.name) { // If there's no name, default to something sensible. - setName("microbit"); + setName("microbit.py"); } else { setName(message.name); } if (!message.comment) { // If there's no description, default to something sensible. - setDescription("A MicroPython script"); + setDescription("microbit"); } else { setDescription(message.comment); } @@ -315,54 +318,71 @@ function web_editor() { // This function describes what to do when the save button is clicked. function doSave() { - console.log("works"); - var content = EDITOR.getCode() + "#~*" + getDescription() + "," + getName(); - console.error(content); + var content = EDITOR.getCode() + "#~*" + getDescription(); var gistpush = { - "description": getDescription(), - "public": true, - "files": { - "microbit.py": { - "content": content - } - } + "content": content }; - $.ajax({ - type: 'POST', - url: 'https://api.github.com/gists', - data: JSON.stringify(gistpush), - success: function(gist,message,raw){alert(gist.html_url)} - }); + if (gistID === "") { + $.ajax({ + type: 'POST', + url: '/create/' + 'microbit' + '.py', + contentType: "application/json", + data: JSON.stringify(gistpush), + success: function(gist, message, raw) { + gistID = gist.id; + alert("Gist link" + '\n\n' + gistID); + } + }); + + } + + else { + + if (getDescription() !== "microbit"){ + $.ajax({ + type: 'POST', + url: '/save/' + gistID + '/' + getDescription() + '.py', + contentType: "application/json", + data: JSON.stringify(gistpush), + success: function(gist, message, raw) { + alert("Gist ID" + '\n\n' + gistID); + } + }) + } - // TODO: Push code into new gist, forking the current gist if available + else { + alert("File name is not permitted to be microbit") + } + } + } // This function describes what to do when the load button is clicked. function doLoad() { // TODO: Display a modal that asks for a gist URL to load var url = window.prompt("GIST URL"); - // var url = 'https://gist.github.com/ben-dent/8c8f0625d99fe2841d45ebe1b5d0b8c9'; - var id = url.split('/').pop(); - var githubAPI = 'https://api.github.com/gists/' + id; - - $.getJSON(githubAPI, function(data){ - var unsplit = data.files["microbit.py"].content; - var split = unsplit.split('#~*'); - EDITOR.setCode(split[0]); - var header = split[1].split(','); - setDescription(header[0]); - setName(header[1]); - }); + gistID = url; + if (url !== null){ + var id = url.split('/').pop(); + var githubAPI = '/load/' + id + '/' + 'microbit' + '.py'; + + $.getJSON(githubAPI, function(data){ + var unsplit = data.content; + var split = unsplit.split('#~*'); + EDITOR.setCode(split[0]); + var header = split[1].split(','); + setDescription(header[0]); + setName(header[1]); + }); + } } - // This function describes what to do when the explore button is clicked. function doExplore() { // TODO: Open a modal that shows the forks of the current gist // TODO: If no gist is loaded then show the load modal first } - // This function describes what to do when the snippets button is clicked. function doSnippets() { // Snippets are triggered by typing a keyword followed by pressing TAB. diff --git a/templates/editor.html b/templates/editor.html index d3275bad..e2e9fb8b 100644 --- a/templates/editor.html +++ b/templates/editor.html @@ -65,6 +65,7 @@ + @@ -101,7 +102,7 @@

Code Snippets

-
Billy
+
Download
Code Snippets
-
-
-
-
+ +
@@ -197,7 +194,8 @@

Code Snippets

- + +