Ensure mods dir exists on file drop.
This commit is contained in:
parent
d779eacf61
commit
f5ce7734b8
@ -71,6 +71,8 @@ exports.scanForDropinMods = function(modsDir, version) {
|
|||||||
*/
|
*/
|
||||||
exports.addDropinMods = function(files, modsdir) {
|
exports.addDropinMods = function(files, modsdir) {
|
||||||
|
|
||||||
|
exports.validateModsDir(modsdir)
|
||||||
|
|
||||||
for(let f of files) {
|
for(let f of files) {
|
||||||
if(MOD_REGEX.exec(f.name) != null) {
|
if(MOD_REGEX.exec(f.name) != null) {
|
||||||
fs.moveSync(f.path, path.join(modsdir, f.name))
|
fs.moveSync(f.path, path.join(modsdir, f.name))
|
||||||
|
18
package-lock.json
generated
18
package-lock.json
generated
@ -855,11 +855,11 @@
|
|||||||
"integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk="
|
"integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk="
|
||||||
},
|
},
|
||||||
"discord-rpc": {
|
"discord-rpc": {
|
||||||
"version": "github:discordjs/RPC#a80e457d3aa9969a6134693ca2102ffc731ebc04",
|
"version": "github:discordjs/RPC#1bd83d3b895766e25c457b031079d783678875ff",
|
||||||
"from": "github:discordjs/RPC",
|
"from": "github:discordjs/RPC",
|
||||||
"requires": {
|
"requires": {
|
||||||
"node-fetch": "^2.1.2",
|
"node-fetch": "^2.3.0",
|
||||||
"ws": "^5.2.1"
|
"ws": "^6.1.1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"dmg-builder": {
|
"dmg-builder": {
|
||||||
@ -2198,9 +2198,9 @@
|
|||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"node-fetch": {
|
"node-fetch": {
|
||||||
"version": "2.2.0",
|
"version": "2.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.2.0.tgz",
|
"resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.3.0.tgz",
|
||||||
"integrity": "sha512-OayFWziIxiHY8bCUyLX6sTpDH8Jsbp4FfYd1j1f7vZyfgkcOnAyM4oQR16f8a0s7Gl/viMGRey8eScYk4V4EZA=="
|
"integrity": "sha512-MOd8pV3fxENbryESLgVIeaGKrdl+uaYhCSSVkjeOb/31/njTpcis5aWfdqgNlHIrKOLRbMnfPINPOML2CIFeXA=="
|
||||||
},
|
},
|
||||||
"normalize-package-data": {
|
"normalize-package-data": {
|
||||||
"version": "2.4.0",
|
"version": "2.4.0",
|
||||||
@ -3555,9 +3555,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ws": {
|
"ws": {
|
||||||
"version": "5.2.2",
|
"version": "6.1.2",
|
||||||
"resolved": "https://registry.npmjs.org/ws/-/ws-5.2.2.tgz",
|
"resolved": "https://registry.npmjs.org/ws/-/ws-6.1.2.tgz",
|
||||||
"integrity": "sha512-jaHFD6PFv6UgoIVda6qZllptQsMlDEJkTQcybzzXDYM1XO9Y8em691FGMPmM46WGyLU4z9KMgQN+qrux/nhlHA==",
|
"integrity": "sha512-rfUqzvz0WxmSXtJpPMX2EeASXabOrSMk1ruMOV3JBTBjo4ac2lDjGGsbQSyxj8Odhw5fBib8ZKEjDNvgouNKYw==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"async-limiter": "~1.0.0"
|
"async-limiter": "~1.0.0"
|
||||||
}
|
}
|
||||||
|
@ -27,7 +27,7 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"adm-zip": "^0.4.13",
|
"adm-zip": "^0.4.13",
|
||||||
"async": "^2.6.1",
|
"async": "^2.6.1",
|
||||||
"discord-rpc": "discordjs/RPC",
|
"discord-rpc": "github:discordjs/RPC",
|
||||||
"ejs": "^2.6.1",
|
"ejs": "^2.6.1",
|
||||||
"ejs-electron": "^2.0.3",
|
"ejs-electron": "^2.0.3",
|
||||||
"electron-updater": "^4.0.5",
|
"electron-updater": "^4.0.5",
|
||||||
@ -94,7 +94,7 @@
|
|||||||
},
|
},
|
||||||
"compression": "maximum",
|
"compression": "maximum",
|
||||||
"files": [
|
"files": [
|
||||||
"!{dist,.gitignore,.vscode,docs,dev-app-update.yml,.travis.yml,.nvmrc,.eslintrc.scripts.json,.eslintrc.json}"
|
"!{dist,.gitignore,.vscode,docs,dev-app-update.yml,.travis.yml,.nvmrc,.eslintrc.json}"
|
||||||
],
|
],
|
||||||
"extraResources": [
|
"extraResources": [
|
||||||
"libraries"
|
"libraries"
|
||||||
|
Loading…
Reference in New Issue
Block a user