1.4.1 Alpha

This commit is contained in:
Theenoro 2017-09-08 00:06:24 +02:00
parent 12db3c4599
commit bb905111ec
4 changed files with 54 additions and 1 deletions

View File

@ -0,0 +1,26 @@
// ==UserScript==
// @name Cyber Downloader ADD
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @require http://code.jquery.com/jquery-latest.js
// @match https://www.youtube.com/watch?v=*
// @grant none
// ==/UserScript==
(function() {
'use strict';
var s = jQuery.noConflict();
console.log('loaded');
setTimeout(function(){
s('#end').prepend('<button id="cb3_send">Send To Cyber</button>');
},1000);
// Your code here...
s('body').delegate('#cb3_send','click',function(){
var sy = window.location;
s.post( "http://127.0.0.1:54167/download?url="+encodeURI(sy),function() {
});
});
})();

View File

@ -47,8 +47,11 @@
} }
}, },
"dependencies": { "dependencies": {
"body-parser": "^1.17.2",
"cors": "^2.8.4",
"electron": "^1.6.11", "electron": "^1.6.11",
"electron-compile": "^6.4.1", "electron-compile": "^6.4.1",
"express": "^4.15.4",
"fs": "0.0.1-security", "fs": "0.0.1-security",
"mkdirp": "^0.5.1", "mkdirp": "^0.5.1",
"path": "^0.12.7", "path": "^0.12.7",

View File

@ -0,0 +1,22 @@
const app = require('express')();
var cors = require('cors')
app.use(cors())
const bodyParser = require('body-parser');
app.use( bodyParser.json() ); // to support JSON-encoded bodies
app.use(bodyParser.urlencoded({ // to support URL-encoded bodies
extended: true
}));
app.post('/download', function(req, res) {
var log = req.query.url;
console.log(log)
// ...
});
app.listen(54167, "127.0.0.1");
module.exports = app;

View File

@ -2,7 +2,9 @@ const { spawn } = require('child_process');
const ipcMain = require('electron').ipcMain; const ipcMain = require('electron').ipcMain;
const dl_routine = require('./youtube-dl.routine') const dl_routine = require('./youtube-dl.routine')
const pot = require('./player_onTop') const web = require('./webLoader/router');
const pot = require('./player_onTop');
const folderWatchr = require('./watchr') const folderWatchr = require('./watchr')
console.log(global.dir); console.log(global.dir);