Skip to content

A web application that compares different computers based on specs

Notifications You must be signed in to change notification settings

D3FAU4T/Computer-Comparer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Computer Comparer

Computer Comparer is a web application that allows users to compare different computer specifications. The application is built using Flask for the backend and HTML, CSS, and JavaScript for the frontend.

Warning

This is a practice project and is not recommended for production use

Download

Try out already pre-built applications from the release section of this Github Repositry. Otherwise if you prefer to manually build the project, follow the guide below.

Installation

  1. Clone the repository:

    git clone https://github.com/D3FAU4T/Computer-Comparer.git
    cd Computer-Comparer
  2. Create a virtual environment and activate it:

    python -m venv .venv # Use `python3` for Linux
    
    # On Linux use
    source .venv/bin/activate
    
    # On Windows use
    .venv\Scripts\activate

Note

On Linux, you may need to install python3.12-venv library before running the command, if it gives any error

sudo apt install python3.12-venv

Or if you use another package-manager, install with that.

  1. Install the required packages:

    pip install -r requirements.txt

Note

On Linux, you may need to install python3-pip library before running the command, if it gives any error

sudo apt install python3-pip

Or if you use another package-manager, install with that

Usage

To use the application as-is from the code, follow the given instructions:

  1. Run the Flask application:

    python main.py # Use `python3` for Linux
  2. Open your web browser and navigate to http://127.0.0.1:5000.

Build

To build the project into an executable or a linux binary, run the following command:

python build.py # Use `python3` for Linux

The output should be in the dist folder in the project's root directory

Project Files

  • main.py: The main Flask application file. It sets up the routes and handles the backend logic.
  • color.py: Contains utility functions for colored terminal output.
  • build.py: Contains OS-specific instructions to build the application
  • data.json: The JSON file that stores the computer specifications.
  • static/:
    • script.js: JavaScript file for frontend logic.
    • style.css: CSS file for styling the web pages.
  • templates/:
    • index.html: The main HTML template for the application.

API Endpoints

  • GET /api/data: Fetches the computer specifications from data.json.
  • POST /api/data/update: Updates the computer specifications in data.json.

License

This project is licensed under the MIT License.

About

A web application that compares different computers based on specs

Resources

Stars

Watchers

Forks

Packages

No packages published