docs: update README for install.sh and Electron launcher
This commit is contained in:
44
README.md
44
README.md
@@ -24,10 +24,18 @@ LazyUpdateManager is a small update helper for Arch Linux and Hyprland. It check
|
|||||||
|
|
||||||
## Build
|
## Build
|
||||||
|
|
||||||
|
Build the Go backend:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
make build
|
make build
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Full install (recommended):
|
||||||
|
|
||||||
|
```sh
|
||||||
|
./install.sh
|
||||||
|
```
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
@@ -72,20 +80,38 @@ Install the Electron dependencies once:
|
|||||||
npm install
|
npm install
|
||||||
```
|
```
|
||||||
|
|
||||||
Start the desktop app:
|
Start the desktop app (development):
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
make desktop
|
make desktop
|
||||||
```
|
```
|
||||||
|
|
||||||
Build desktop packages:
|
Or use the installed launcher directly:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
lazy-update-manager-electron
|
||||||
|
```
|
||||||
|
|
||||||
|
Build distribution packages (AppImage, Pacman):
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
make desktop-dist
|
make desktop-dist
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Desktop Launcher
|
||||||
|
|
||||||
|
After installation, a launcher script `lazy-update-manager-electron` is placed in `~/.local/bin/`. It sets the project directory and starts Electron directly. This is also what the desktop entry (wofi/rofi) uses.
|
||||||
|
|
||||||
|
When running `lazy-update-manager gui` from the terminal, the Go backend tries to start the Electron app automatically when `prefer_electron` is enabled (default after installation). You can force the web interface with `lazy-update-manager gui web`.
|
||||||
|
|
||||||
## Install
|
## Install
|
||||||
|
|
||||||
|
```sh
|
||||||
|
./install.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
Or with `make`:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
make install
|
make install
|
||||||
```
|
```
|
||||||
@@ -93,12 +119,17 @@ make install
|
|||||||
This installs:
|
This installs:
|
||||||
|
|
||||||
- the binary to `~/.local/bin/lazy-update-manager`
|
- the binary to `~/.local/bin/lazy-update-manager`
|
||||||
- the desktop launcher to `~/.local/share/applications/lazy-update-manager.desktop`
|
- the Electron app launcher to `~/.local/bin/lazy-update-manager-electron`
|
||||||
|
- a desktop entry to `~/.local/share/applications/lazy-update-manager.desktop`
|
||||||
- the user service and timer to `~/.config/systemd/user/`
|
- the user service and timer to `~/.config/systemd/user/`
|
||||||
|
|
||||||
When a user systemd session is available, the timer is enabled immediately so update notifications work after install.
|
The installer also runs `npm install`, builds the Go backend, sets `prefer_electron: true` in the config, and enables the systemd timer.
|
||||||
|
|
||||||
The install target now preserves the previous binary by backing it up when it differs, so installations are safe and reversible.
|
### Build Electron distribution packages
|
||||||
|
|
||||||
|
```sh
|
||||||
|
./install.sh electron-dist
|
||||||
|
```
|
||||||
|
|
||||||
### Check version and update
|
### Check version and update
|
||||||
|
|
||||||
@@ -112,8 +143,7 @@ To update to the latest version from this repository:
|
|||||||
|
|
||||||
```sh
|
```sh
|
||||||
git pull --ff-only
|
git pull --ff-only
|
||||||
make build
|
./install.sh
|
||||||
make install
|
|
||||||
```
|
```
|
||||||
|
|
||||||
If you prefer to test the local build without installing, run the bundled binary directly:
|
If you prefer to test the local build without installing, run the bundled binary directly:
|
||||||
|
|||||||
Reference in New Issue
Block a user