Git Product home page Git Product logo

ergo's People

Contributors

adithaker avatar dependabot[bot] avatar fasterthanlime avatar kewde avatar namandangi avatar raj2729 avatar rezach avatar rishidesai17 avatar shahjigar556 avatar vedant-5 avatar yjdoc2 avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

ergo's Issues

Create a function to launch shell and run commands

Create a function that will launch respective shell in a separate process , and then run the given command. Make sure that this run in both windows and Linux. Currently let's first implement this for Debian based distros, so that x-terminal-emulator will be mapped to default terminal emulator of the system (check out https://vitux.com/how-to-set-the-gnome-default-terminal-emulator-on-ubuntu/). For windows this should launch cmd/powershell. Make sure to test this on both platform for launching terminal as well as running the command and appropriately write tests for checking terminal has been launched and command is run
Also make sure that only respective tests are run on given platform (Tests for Windows on Windows and tests for Linux on Linux).

Set up files to export platform dependent values

Create individual files which will export platform-specific values, one for Windows and one for Linux.

Make index.js for that folder which will conditionally export values depending on which platform it is run.

Some examples for the values would be path to save log files, path for user data etc.

Also set up the conditional tests for these exports to verify correct values are being exported on platforms.

Set up exporting of backend functions api to renderer process

We will need to export all of the 'backend' functions to the renderer process, so we can call them from the GUI. Create appropriate folders to define the backend functions, and create index.js file to exports all functions. One would need to import this in the preload.js and export in the preload. Make sure to read the docs of template to know the security aspects of preload.js nad requirements.

Set up logger

Set up a logger to log various information when the application will run/ error occurs.
check out electron-log which provides a simple interface for logging, without needing to specify log path.
Make sure the logger is working in both the main.js file for electron and int the render process itself. For working with logger in renderer process, one needs to export the logger in preload.js. Read the docs of the template to understand the security aspects and requirements for preload.

Connect Backend funtions to Frontend events

Connect the backend functions exposed through ipcbridge to frontend, and call them appropriately on appropriate events such as onClick etc.
This might consist of multiple PRs for multiple fucntions such as launching editor and file manager, project creation etc.

Expose backend functions through ipcbridge using events

Shift individual function js files to events folders, import them in the index js, and export those appropriately from it. Also create appropriate event strings in events.js. This will export this functions securely to frontend, and allow calling them. Make sure to test they are working correctly and that they can be called from frontend before making PR.

Create funtion to launch file manager and preffered/default code editor

Write a function that will take appropriate parameters and launch the default file manager and code editor in the specified directory.
For Linux, this can be done using xdg-open (check https://itsfoss.com/install-nemo-file-manager-ubuntu/), which will launch file navigator in specified folder. For Windows the function should launch the windows default file manager in given directory.
Write tests to check if file manager and code editors are actually launched or not, also make sure that either the preferred (global or language-specific) or default code editor is launched.
Make sure to test on both platforms, and write mocha tests for both platforms.

Set up the initialization function

Set up initialization function to get various information about the host system, such as if various programs are installed : node, npm python, etc., which terminal emulator is existing, check for option depending on which platform it is running.

Create project creation function

Create a function that will take required parameters such as project name, type of project (Node,python etc.) and will create a folder as well as run appropriate initialization function, such as npm init or cargo init etc. This folder should be created in a centralized space, particular to our app.
Make sure that you test this function, and create mocha tests for making sure that this runs, with proper harness and mocking of required data.

Connect backend and frontend for initial data read

When application will be launched, each time, it will check stored data for existing projects data, and that should be given to frontend, so that it can render the project list. Create appropriate function, and pass on the required data to frontend.

The data might include project name, path, description, tags, stack, project specific commands, common commands for all projects etc.

This should be then used by frontend to render the project list, and when clicked on specific project, render the correct details as well as commands etc, which should be then connected to appropriate backend function using ipcbridge events, so that they can run in backend when clicked etc.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.