Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/electron/events/interfaceCreateProject.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const { app } = require("electron");
const createProject = require("../createProject");

// Examples
/*
let project1 = {
Expand Down
17 changes: 17 additions & 0 deletions app/electron/events/launcher.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,17 @@
/* eslint-disable consistent-return */
const { exec } = require("child_process");

// Opening to Projects folder
const { app } = require("electron");

exports.launchCodeEdiitor = (preferredEdittor, path) => {

// Default Path to Projects Folder
path = app.getPath("userData");
path+="/Projects";
// To open specific project in later versions
// path+=`/Projects/${name_of_project}`

if (preferredEdittor === "Eclipse") {
return new Promise((resolve, reject) => {
exec(`eclipse "${path}"`, (error) => {
Expand Down Expand Up @@ -58,6 +68,13 @@ exports.launchCodeEdiitor = (preferredEdittor, path) => {
};

exports.launchFileManager = (path) => {

// Default Path to Projects Folder
path = app.getPath("userData");
path+="/Projects";
// To open specific project in later versions
// path+=`/Projects/${name_of_project}`

if (process.platform === "linux") {
return new Promise((resolve, reject) => {
exec(`xdg-open "${path}"`, (error) => {
Expand Down
2 changes: 1 addition & 1 deletion app/electron/initial.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const { app } = require("electron");
const sh = require("shelljs");

// Path of config.json file : C:\Users\[USER_NAME]\AppData\Roaming\[APP_NAME]

const ElectronStore = require("electron-store");

const log = require("electron-log");
Expand Down
10 changes: 8 additions & 2 deletions app/src/pages/ProjectInfo/Actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,10 @@ function Actions() {
onClick: () => {
window.api.api.send("Launch File Manager", {
launchmanager: {
path: "C:\\Users\\shahj\\Desktop",
// path: "C:\\Users\\shahj\\Desktop",
// Storing in Projects Folder
// Might use user path in future
path:"",
},
});
window.api.api.onReceive("Launch File Manager Reply", (args) =>
Expand All @@ -67,7 +70,10 @@ function Actions() {
window.api.api.send("Launch Default Editor", {
launcheditor: {
preferredEdittor: "VSCode",
path: "C:\\Users\\shahj\\Desktop",
// path: "C:\\Users\\shahj\\Desktop",
// Storing in Projects Folder
// Might use user path in future
path:"",
},
});
window.api.api.onReceive("Launch Default Editor Reply", (args) =>
Expand Down