update readme
This commit is contained in:
parent
532e512b4c
commit
9de12cc571
195
README.md
195
README.md
@ -1,41 +1,179 @@
|
||||
# Folder Installer Tool (Embedded Version)
|
||||
# 🐍 **Python Requirements**
|
||||
|
||||
This tool creates an executable that **contains all your folders within itself**. When users run it, they can choose where to install all the folders.
|
||||
### **For Users Running Scripts**:
|
||||
- **Python 3.6 or higher** must be installed
|
||||
- Download from: https://www.python.org/downloads/
|
||||
|
||||
## ✅ **Your executable is ready: `dist\ScriptsInstaller.exe`**
|
||||
### **For Developers Building the Executable**:
|
||||
```bash
|
||||
pip install pyinstaller
|
||||
```
|
||||
|
||||
## 🛠️ **Development Instructions**
|
||||
|
||||
### **Building the Executable**:
|
||||
```bash
|
||||
python build.py
|
||||
```
|
||||
|
||||
This will:
|
||||
1. Create a zip file with all folders
|
||||
2. Encode it as base64
|
||||
3. Build the executable with PyInstaller
|
||||
4. Output: `dist/ScriptsInstaller.exe`
|
||||
|
||||
# Scripts Installer Tool
|
||||
|
||||
This tool creates an executable that **contains all your scripts within itself**. When users run it, they can choose where to install all the scripts and tools.
|
||||
|
||||
## ✅ **Your executable will be ready at: `dist\ScriptsInstaller.exe`**
|
||||
|
||||
## How it works:
|
||||
|
||||
1. **All folders are embedded inside the exe** - The executable contains all your folders (PLACE DPMS, PLACE DPM DEVICES, OTHER SCRIPTS, RESET IGNITION, TAGS) as compressed data
|
||||
1. **All scripts are embedded inside the exe** - The executable contains all your scripts and tools as compressed data
|
||||
2. **Users only need the exe file** - No other files needed
|
||||
3. **Users run the exe anywhere** - They can place it on desktop, downloads, etc.
|
||||
4. **Users select installation location** - A folder selection dialog opens
|
||||
5. **Folders get extracted and installed** - All folders are extracted to their chosen location
|
||||
4. **Scripts get extracted and installed** - All scripts are extracted to their chosen location
|
||||
|
||||
## User Experience:
|
||||
|
||||
### What users get:
|
||||
- **Single file**: `ScriptsInstaller.exe` (12MB)
|
||||
- **Single file**: `ScriptsInstaller.exe` (11MB)
|
||||
- **No installation required**: Just run the exe
|
||||
- **Choose any location**: Install folders wherever they want
|
||||
|
||||
### What happens when they run it:
|
||||
1. User double-clicks `ScriptsInstaller.exe`
|
||||
2. A folder selection dialog opens: "Select destination folder for installing folders"
|
||||
3. User chooses where to install (e.g., `C:\Users\John\Desktop\`)
|
||||
4. User sees confirmation: "Install all folders to: [selected path]"
|
||||
5. User clicks "Yes" to proceed
|
||||
6. A `SCRIPTS` folder gets created with all tools inside
|
||||
7. Success message shows: "Successfully installed 1 folder to: [path]"
|
||||
- **Choose any location**: Install scripts wherever they want
|
||||
|
||||
## What gets installed:
|
||||
|
||||
When users run the executable, a single `SCRIPTS` folder will be installed to their chosen location, containing:
|
||||
- `SCRIPTS/PLACE DPMS/` (with all subfolders and files)
|
||||
- `SCRIPTS/PLACE DPM DEVICES/` (with all subfolders and files)
|
||||
- `SCRIPTS/OTHER SCRIPTS/` (with all subfolders and files)
|
||||
- `SCRIPTS/RESET IGNITION/` (with all subfolders and files)
|
||||
- `SCRIPTS/TAGS/` (with all subfolders and files)
|
||||
- `SCRIPTS/PLACE DPMS/`
|
||||
- `SCRIPTS/PLACE DPM DEVICES/`
|
||||
- `SCRIPTS/OTHER SCRIPTS/`
|
||||
- `SCRIPTS/RESET IGNITION/`
|
||||
- `SCRIPTS/TAGS/`
|
||||
|
||||
# 📁 **Detailed Folder Descriptions**
|
||||
|
||||
### **PLACE DPMS/**
|
||||
**Purpose**: Creates MCM views with DPM configurations.
|
||||
|
||||
**What it does**:
|
||||
- Reads DPM mapping from `dpm_mapping.txt`
|
||||
- Creates MCM folders with proper view.json files
|
||||
- Configures DPM names and IP addresses in the views
|
||||
- Applies bindings to every DPM/MCM
|
||||
- Generates resource.json and thumbnail.png files
|
||||
- MISSING: tagProps generation in root (not enough information)
|
||||
|
||||
**How to use**:
|
||||
1. Edit `dpm_mapping.txt` with your MCM and DPM information
|
||||
2. Run `python main.py`
|
||||
3. Check the `MCMs/` output folder for generated files
|
||||
|
||||
**File format for dpm_mapping.txt**:
|
||||
```
|
||||
MCM_NAME
|
||||
DPM_NAME1 DPM_IP1
|
||||
DPM_NAME2 DPM_IP2
|
||||
...
|
||||
DPM_NAMEN DPM_IPN
|
||||
MCM_NAMEN
|
||||
...
|
||||
```
|
||||
|
||||
### **PLACE DPM DEVICES/**
|
||||
**Purpose**: Creates DPM device configurations with VFD and FIO/SIO device layouts.
|
||||
|
||||
**What it does**:
|
||||
- Reads device mapping from `device_mapping.txt`
|
||||
- Creates DPM folders with device configurations
|
||||
- Positions VFD and FIO/SIO devices on the layout
|
||||
- Generates view.json with proper device positioning
|
||||
- Applies bindings to every VFD/FIO/SIO
|
||||
- MISSING: tagProps generation in root (not enough information)
|
||||
|
||||
**How to use**:
|
||||
1. Edit `device_mapping.txt` with your DPM and device information
|
||||
2. Run `python main.py`
|
||||
3. Check the `MCM/` output folder for generated files
|
||||
|
||||
**File format for device_mapping.txt**:
|
||||
```
|
||||
DPM_NAME
|
||||
DEVICE_NAME1 DEVICE_IP1
|
||||
DEVICE_NAME2 DEVICE_IP2
|
||||
...
|
||||
DEVICE_NAMEN DEVICE_IPN
|
||||
DPM_NAMEN
|
||||
...
|
||||
```
|
||||
|
||||
### **OTHER SCRIPTS/**
|
||||
**Purpose**: Contains various utility scripts for DPM and MCM management.
|
||||
|
||||
**Subfolders**:
|
||||
- **CHANGE DPM NAMES TO DEFAULT/**: Resets DPM names to default values
|
||||
- **CHANGE EXISTING DPM VIEW NAMES/**: Modifies existing DPM view names
|
||||
- **CREATE MCM VIEWS/**: Creates new MCM view configurations
|
||||
|
||||
**How to use**:
|
||||
1. Navigate to the specific subfolder
|
||||
2. Open `main.py` and follow the steps
|
||||
3. Run `python main.py` in each folder as needed
|
||||
|
||||
### **RESET IGNITION/**
|
||||
**Purpose**: Resets Ignition every 1 minute.
|
||||
|
||||
**How to use**:
|
||||
1. Run `python main.py`
|
||||
2. Keep your console open so it will be running constantly
|
||||
|
||||
### **TAGS/**
|
||||
**Purpose**: Manages tag configurations for MCM systems.
|
||||
|
||||
**What it does**:
|
||||
- Generates tag configurations
|
||||
- Applies tags to MCM systems
|
||||
- Keeps unique tag entries
|
||||
- Manages MCM tag mappings
|
||||
|
||||
**Scripts included**:
|
||||
- `generate-tags.py`
|
||||
-- Creates tag configurations, picks devices from view.json and generates tags
|
||||
- `apply-tags.py`
|
||||
-- Applies already generated tags to already existing view.json files to tagProps
|
||||
- `keep-unique.py`
|
||||
-- Removes duplicate tags (not necessary)
|
||||
|
||||
**How to use**:
|
||||
1. Run `python generate-tags.py` to create tags
|
||||
2. Run `python apply-tags.py` to apply them
|
||||
3. Run `python keep-unique.py` to clean duplicates
|
||||
|
||||
### **Project Structure**:
|
||||
```
|
||||
SCRIPTS/
|
||||
├── build.py # Build script for executable
|
||||
├── README.md # This documentation
|
||||
├── .gitignore # Git ignore rules
|
||||
├── PLACE DPMS/ # DPM configuration tool
|
||||
├── PLACE DPM DEVICES/ # Device layout tool
|
||||
├── OTHER SCRIPTS/ # Utility scripts
|
||||
├── RESET IGNITION/ # Ignition reset tool
|
||||
└── TAGS/ # Tag management tools
|
||||
```
|
||||
|
||||
## 📋 **Quick Start Guide for Users**
|
||||
|
||||
1. **Install Python** (if not already installed)
|
||||
2. **Run ScriptsInstaller.exe** to install all tools
|
||||
3. **Navigate to the SCRIPTS folder** where you installed
|
||||
4. **Choose the tool you need**:
|
||||
- For DPM configuration: Use `PLACE DPMS/`
|
||||
- For device layout: Use `PLACE DPM DEVICES/`
|
||||
- For tag management: Use `TAGS/`
|
||||
- For Ignition reset: Use `RESET IGNITION/`
|
||||
5. **Edit the configuration files** (txt files) with your data
|
||||
6. **Run `python main.py`** in the respective folder
|
||||
|
||||
## Distribution:
|
||||
|
||||
@ -49,18 +187,7 @@ When users run the executable, a single `SCRIPTS` folder will be installed to th
|
||||
|
||||
## Technical Details:
|
||||
|
||||
- **File size**: ~12MB (contains all your folders compressed)
|
||||
- **File size**: ~11MB (contains all your scripts compressed)
|
||||
- **Dependencies**: None (self-contained)
|
||||
- **Requirements**: Windows 7 or later
|
||||
- **Method**: Uses base64 encoding to embed zip data within the executable
|
||||
|
||||
## Example User Workflow:
|
||||
|
||||
1. User downloads `ScriptsInstaller.exe`
|
||||
2. User places it on desktop
|
||||
3. User double-clicks the exe
|
||||
4. User selects: `C:\Users\John\Desktop\`
|
||||
5. User confirms installation
|
||||
6. Result: A `SCRIPTS` folder is created at `C:\Users\John\Desktop\SCRIPTS\` containing all tools
|
||||
|
||||
This is exactly what you wanted - users get a single exe file that installs all your folders wherever they choose!
|
||||
Loading…
x
Reference in New Issue
Block a user