Skip to content

Commit 6fac6b7

Browse files
committed
docs: Reorganize installation instructions with clearer alternatives
1 parent cb65a79 commit 6fac6b7

File tree

1 file changed

+46
-3
lines changed

1 file changed

+46
-3
lines changed

README.md

Lines changed: 46 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,12 +58,30 @@ graph TD
5858
- Xcode 15+
5959
- Administrative privileges for SMC access
6060

61-
## Installation
61+
## Installation
6262

63-
DMG image can be downloaded in Releases, after drag it into your application folder, it is expected to work by simply clicking the icon.
63+
### DMG Installation
64+
1. Download the latest `.dmg` package from our [Releases page](https://github.com/yourrepo/releases)
65+
2. Open the downloaded DMG file
66+
3. Drag the application to your `Applications` folder
6467

68+
### Manual Installation (From Source)
69+
1. Build the application:
70+
```bash
71+
# Clone repository
72+
git clone https://github.com/clzoc/BattGUI.git
73+
cd power-suite
74+
xcodebuild -workspace app.xcodeproj/project.xcworkspace -scheme app
75+
```
76+
77+
2. Install required components:
78+
```bash
79+
sudo batt install --allow-non-root-access
80+
```
81+
82+
### Alternative Installation
6583
1. **GateKeeper Configuration**
66-
If you encounter security warnings when running the application:
84+
If you encounter security warnings:
6785
- Go to `System Settings``Privacy & Security` → scroll down to `Security`
6886
- Click "Open Anyway" next to the BattGUI warning
6987
- Confirm execution in the dialog
@@ -91,6 +109,31 @@ open app/build/Release/app.app
91109
- Historical data trending
92110
- Customizable power profiles
93111

112+
- **GUI Charge Limit Adjustment Permission Denied**: When attempting to adjust battery charge limit through the GUI, users encounter permission errors depending on installation method.
113+
114+
## Affected Components
115+
- `powerInfo.m` (Objective-C)
116+
- Unix domain socket: `/var/run/batt.sock`
117+
- GUI slider control
118+
119+
## Symptoms
120+
| Installation Method | Behavior | Command |
121+
|---------------------|----------|---------|
122+
| With `--allow-non-root-access` | ✅ Works correctly | `sudo batt install --allow-non-root-access` |
123+
| Default installation | ❌ "Permission denied" error | `sudo batt install` |
124+
125+
## Technical Details
126+
### Root Cause
127+
The Unix domain socket (`/var/run/batt.sock`) implements strict permission controls:
128+
- Default mode: 600 (root-only)
129+
- With flag: 666 (world-readable/writable)
130+
131+
### Error Reproduction
132+
1. Install without special flags
133+
2. Launch GUI application
134+
3. Attempt to move charge limit slider
135+
4. Observe error in system logs:
136+
94137
## Contributing
95138
See [CONTRIBUTING.md](CONTRIBUTING.md) for development setup and guidelines.
96139

0 commit comments

Comments
 (0)