Remixer

Auto remixes a project!

  1. // ==UserScript==
  2. // @name Remixer
  3. // @namespace http://tampermonkey.net/
  4. // @version 0.1
  5. // @description Auto remixes a project!
  6. // @author You
  7. // @match https://studio.code.org/projects/*/*/*
  8. // @icon data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==
  9. // @grant none
  10. // @license MIT
  11. // ==/UserScript==
  12.  
  13. (function() {
  14. 'use strict';
  15. function q(s) {
  16. return document.querySelector(s);
  17. }
  18. var int = setInterval(function() {
  19. if (q(".project_share") != null) {
  20. clearInterval(int);
  21. q(".project_share").click();
  22. setTimeout(function() {
  23. q("#share-dialog-publish-button").click();
  24. setTimeout(function() {
  25. q("#publish-dialog-publish-button").click();
  26. var int = setInterval(function() {
  27. if (q("#publish-dialog-publish-button") == null) {
  28. clearInterval(int);
  29. q(".project_remix").click();
  30. }
  31. }, 100);
  32. });
  33. }, 500);
  34. }
  35. }, 100);
  36. })();