prime for update (bc i still don't know how to use npm ver)

toast
Kit Kasune 3 years ago
parent 155ffc7c41
commit f445d52b23
  1. 1
      json/changelogs/1.4.0.json
  2. 2
      main.js
  3. 2
      newversion.js
  4. 16
      scripts/fileview/checkdir.js

@ -0,0 +1 @@
{"log":{"Changelog":["Current version no longer displays on every version","Styling fixes like making changelog container a flexbox"],"QOL":["Clicking the toast that appears when a new folder is made will now copy its path to your clipboard and open the folder in the app"],"External Folder Monitoring":["FileKade now periodically checks if the folder you're viewing still exists","If the folder you're viewing is deleted externally, the app automatically navigates to the nearest existing folder in hierarchy"]},"version":{"name":"Alpha","semver":"1.4.0"}}

@ -1,5 +1,5 @@
// Modules to control application life and create native browser window // Modules to control application life and create native browser window
const {app, BrowserWindow} = require('electron') const {app, BrowserWindow} = require('electron');
const path = require('path') const path = require('path')
let mainWindow; let mainWindow;

@ -39,7 +39,7 @@ const ask = async () => {
cp.exec('git add .', () => { cp.exec('git add .', () => {
console.log('Staged working directory.\n'); console.log('Staged working directory.\n');
cp.exec(`npm version ${v.trim().toLowerCase()} -m %s -> ${msg}`, function(error, stdout, stderr) { cp.exec(`npm version ${v.trim().toLowerCase()} -m "%s -> ${msg}"`, function(error, stdout, stderr) {
if (error) {console.error(error);} if (error) {console.error(error);}
if (stdout) {console.log(stdout);} if (stdout) {console.log(stdout);}
if (stdout) {console.log(stderr);} if (stdout) {console.log(stderr);}

@ -1,9 +1,23 @@
const path = require('path');
const fs = require('fs');
const load = require('./load/load'); const load = require('./load/load');
const sort = require('./load/sort'); const sort = require('./load/sort');
const lightRefresh = require("./lightrefresh"); const lightRefresh = require("./lightrefresh");
const refresh = require('../fileview/refresh');
const newToast = require("../toast/createtoast");
module.exports = () => { module.exports = () => {
if (!window.kade.cpath.length || !window.kade.cdir.length) {return;} if (!window.kade.cpath.length) {return;}
if (!fs.existsSync(window.kade.cpath)) {
let cp = window.kade.cpath;
while (true) {
if (!fs.existsSync(cp)) {cp = path.join(cp, '..');}
else {break;}
}
refresh(cp);
newToast("Folder Deleted", `The folder you were viewing no longer exists (this usually means it was removed from another app) so you were automatically moved to the nearest existing folder in hierarchy: <em>${cp}</em>`, '#b24355', false, 10);
}
window.kade.chdir = []; window.kade.chdir = [];
load(true); load(true);
sort(undefined, true); sort(undefined, true);

Loading…
Cancel
Save