eckra 1.0.2 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CONTRIBUTING.md +12 -3
- package/README.md +1 -1
- package/package.json +1 -1
- package/src/index.js +1 -1
- package/src/ui/modules/tag.js +1 -1
package/CONTRIBUTING.md
CHANGED
|
@@ -5,14 +5,16 @@ Thank you for your interest in contributing to eckra! This guide will help you g
|
|
|
5
5
|
## 🚀 Getting Started
|
|
6
6
|
|
|
7
7
|
### Prerequisites
|
|
8
|
+
|
|
8
9
|
- **Node.js**: Version 14.0.0 or higher.
|
|
9
10
|
- **Git**: Installed and configured on your system.
|
|
10
11
|
- **LM Studio** (Optional): For AI-powered features, ensure LM Studio is running and accessible (default: `http://localhost:1234`).
|
|
11
12
|
|
|
12
13
|
### Setup
|
|
14
|
+
|
|
13
15
|
1. Clone the repository:
|
|
14
16
|
```bash
|
|
15
|
-
git clone https://github.com/
|
|
17
|
+
git clone https://github.com/sudoeren/eckra.git
|
|
16
18
|
cd eckra
|
|
17
19
|
```
|
|
18
20
|
2. Install dependencies:
|
|
@@ -39,32 +41,39 @@ Please ensure that all tests pass before submitting a pull request. Adding new t
|
|
|
39
41
|
The project is structured into three main layers:
|
|
40
42
|
|
|
41
43
|
### 1. Entry Point (`src/index.js`)
|
|
44
|
+
|
|
42
45
|
Handles CLI command definitions using `commander`. It routes commands to the appropriate UI or helper functions.
|
|
43
46
|
|
|
44
47
|
### 2. UI Layer (`src/ui/`)
|
|
48
|
+
|
|
45
49
|
Responsible for all user interactions.
|
|
50
|
+
|
|
46
51
|
- **`app.js`**: The main application loop and dashboard menu.
|
|
47
52
|
- **`common.js`**: Shared styles, icons, and UI utility functions (like `clear`, `header`, `box`).
|
|
48
53
|
- **`modules/`**: Contains individual feature modules. Each module (e.g., `commit.js`, `status.js`) handles a specific git flow.
|
|
49
54
|
|
|
50
55
|
#### UI Module Pattern
|
|
56
|
+
|
|
51
57
|
Most UI modules follow this pattern:
|
|
58
|
+
|
|
52
59
|
```javascript
|
|
53
60
|
async function doFeature(info) {
|
|
54
61
|
// 1. Clear screen and show header
|
|
55
62
|
clear();
|
|
56
63
|
header();
|
|
57
|
-
|
|
64
|
+
|
|
58
65
|
// 2. Perform logic or ask questions via inquirer
|
|
59
66
|
const { choice } = await inquirer.prompt([...]);
|
|
60
|
-
|
|
67
|
+
|
|
61
68
|
// 3. Execute git/helper operations
|
|
62
69
|
// 4. Show results/feedback
|
|
63
70
|
}
|
|
64
71
|
```
|
|
65
72
|
|
|
66
73
|
### 3. Helpers (`src/helpers/`)
|
|
74
|
+
|
|
67
75
|
Core business logic separated from the UI.
|
|
76
|
+
|
|
68
77
|
- **`git.js`**: Wraps `simple-git` for all Git operations.
|
|
69
78
|
- **`ai.js`**: Handles communication with AI providers (like LM Studio) for suggestions.
|
|
70
79
|
- **`config.js`**: Manages user configuration.
|
package/README.md
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
</p>
|
|
10
10
|
|
|
11
11
|
<p align="center">
|
|
12
|
-
<a href="https://www.npmjs.com/package/eckra"><img src="https://img.shields.io/badge/npm-v1.0.
|
|
12
|
+
<a href="https://www.npmjs.com/package/eckra"><img src="https://img.shields.io/badge/npm-v1.0.3-blue.svg?style=flat-square" alt="NPM Version"></a>
|
|
13
13
|
<a href="LICENSE"><img src="https://img.shields.io/npm/l/eckra.svg?style=flat-square" alt="License"></a>
|
|
14
14
|
</p>
|
|
15
15
|
|
package/package.json
CHANGED
package/src/index.js
CHANGED