@riflo/ryte 1.0.1 → 1.1.0
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/README.md +23 -5
- package/package.json +1 -1
- package/src/index.js +18 -8
- package/src/prompt.js +1 -0
package/README.md
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
> **Write it right.** AI-powered Git workflow CLI for developers who care about clean history and velocity.
|
|
4
4
|
|
|
5
|
+
*Turn messy git logs into structured, semantic history — instantly.*
|
|
6
|
+
|
|
5
7
|
[](https://www.npmjs.com/package/@riflo/ryte)
|
|
6
8
|
[](https://opensource.org/licenses/MIT)
|
|
7
9
|
[](https://nodejs.org)
|
|
@@ -12,7 +14,7 @@
|
|
|
12
14
|
|
|
13
15
|
Writing meaningful commit messages and well-structured Pull Requests is critical for team collaboration, but it’s often a friction point in a fast-paced development cycle.
|
|
14
16
|
|
|
15
|
-
**ryte** is your CLI companion that
|
|
17
|
+
**ryte** is your CLI companion that **bridges** the gap between "coding" and "documenting". It reads your git diffs, understands the context of your changes, and generates professional, semantic-compliant messages in seconds.
|
|
16
18
|
|
|
17
19
|
### Core Value
|
|
18
20
|
- **Zero Friction**: Stay in the terminal. No Web UI, no heavy extensions.
|
|
@@ -29,7 +31,10 @@ Writing meaningful commit messages and well-structured Pull Requests is critical
|
|
|
29
31
|
npm install -g @riflo/ryte
|
|
30
32
|
|
|
31
33
|
# 2. Set your free AI key (get one at console.groq.com)
|
|
34
|
+
# Mac/Linux:
|
|
32
35
|
export GROQ_API_KEY="gsk_..."
|
|
36
|
+
# Windows (PowerShell):
|
|
37
|
+
$env:GROQ_API_KEY="gsk_..."
|
|
33
38
|
|
|
34
39
|
# 3. Stage your changes and go
|
|
35
40
|
git add .
|
|
@@ -56,7 +61,19 @@ With `ryte c`, it looks like this:
|
|
|
56
61
|
✅ chore: update dependencies to remove security vulnerabilities
|
|
57
62
|
```
|
|
58
63
|
|
|
59
|
-
|
|
64
|
+
### See the Magic
|
|
65
|
+
|
|
66
|
+
**What RYTE sees (`git diff --staged`):**
|
|
67
|
+
```diff
|
|
68
|
+
+ const refreshToken = generateToken(user.id)
|
|
69
|
+
+ await saveTokenToDB(refreshToken)
|
|
70
|
+
+ return res.cookie('refresh_token', refreshToken, { httpOnly: true })
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
**What RYTE writes:**
|
|
74
|
+
> `feat(auth): implement JWT refresh token rotation via HTTP-only cookies`
|
|
75
|
+
|
|
76
|
+
One command. Same diff. Clean history.
|
|
60
77
|
|
|
61
78
|
---
|
|
62
79
|
|
|
@@ -141,7 +158,8 @@ Fair question. Here's an honest comparison:
|
|
|
141
158
|
| Free tier available | ❌ | ✅ (via Groq) |
|
|
142
159
|
| BYOK (Bring Your Own Key) | ❌ | ✅ |
|
|
143
160
|
|
|
144
|
-
Copilot
|
|
161
|
+
*Copilot helps you write code.*
|
|
162
|
+
**RYTE helps your future self understand it.**
|
|
145
163
|
|
|
146
164
|
---
|
|
147
165
|
|
|
@@ -165,7 +183,7 @@ We understand that sending code to an external API is a sensitive decision. Here
|
|
|
165
183
|
|
|
166
184
|
## Configuration
|
|
167
185
|
|
|
168
|
-
**ryte** requires an API key to function. We support
|
|
186
|
+
**ryte** requires an API key to function. We support high-performance LLM providers like Groq and OpenAI.
|
|
169
187
|
|
|
170
188
|
### Groq (Recommended - Free & Instant)
|
|
171
189
|
Get your free key at [console.groq.com](https://console.groq.com/keys).
|
|
@@ -205,7 +223,7 @@ We believe that **every commit should be written right**. A clean git history is
|
|
|
205
223
|
|
|
206
224
|
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are **greatly appreciated**.
|
|
207
225
|
|
|
208
|
-
Please see [
|
|
226
|
+
Please see our [Contributing Guide](https://github.com/Rifuroo/ryte/blob/main/CONTRIBUTING.md) for details on our code of conduct and the process for submitting pull requests.
|
|
209
227
|
|
|
210
228
|
---
|
|
211
229
|
|
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -128,14 +128,24 @@ async function main() {
|
|
|
128
128
|
await handlePR();
|
|
129
129
|
} else {
|
|
130
130
|
console.log(`
|
|
131
|
-
\x1b[
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
131
|
+
\x1b[1;38;5;39m██████╗ \x1b[1;38;5;63m██╗ ██╗\x1b[1;38;5;129m████████╗\x1b[1;38;5;161m███████╗\x1b[0m
|
|
132
|
+
\x1b[1;38;5;39m██╔══██╗\x1b[1;38;5;63m╚██╗ ██╔╝\x1b[1;38;5;129m╚══██╔══╝\x1b[1;38;5;161m██╔════╝\x1b[0m
|
|
133
|
+
\x1b[1;38;5;39m██████╔╝\x1b[1;38;5;63m ╚████╔╝ \x1b[1;38;5;129m ██║ \x1b[1;38;5;161m█████╗ \x1b[0m
|
|
134
|
+
\x1b[1;38;5;39m██╔══██╗\x1b[1;38;5;63m ╚██╔╝ \x1b[1;38;5;129m ██║ \x1b[1;38;5;161m██╔══╝ \x1b[0m
|
|
135
|
+
\x1b[1;38;5;39m██║ ██║\x1b[1;38;5;63m ██║ \x1b[1;38;5;129m ██║ \x1b[1;38;5;161m███████╗\x1b[0m
|
|
136
|
+
\x1b[1;38;5;39m╚═╝ ╚═╝\x1b[1;38;5;63m ╚═╝ \x1b[1;38;5;129m ╚═╝ \x1b[1;38;5;161m╚══════╝\x1b[0m
|
|
137
|
+
|
|
138
|
+
\x1b[90mAI-Powered Git Workflow Assistant\x1b[0m
|
|
139
|
+
\x1b[90mv1.0.4 | by Riflo\x1b[0m
|
|
140
|
+
|
|
141
|
+
\x1b[33mCOMMANDS:\x1b[0m
|
|
142
|
+
\x1b[32mryte c\x1b[0m Generate semantic commit from diff
|
|
143
|
+
\x1b[32mryte pr\x1b[0m Generate PR markdown from branch commits
|
|
144
|
+
|
|
145
|
+
\x1b[33mGETTING STARTED:\x1b[0m
|
|
146
|
+
Set either environment variable to unleash the AI:
|
|
147
|
+
• \x1b[36mGROQ_API_KEY\x1b[0m (Recommended / Free tier)
|
|
148
|
+
• \x1b[36mOPENAI_API_KEY\x1b[0m (OpenAI API key)
|
|
139
149
|
`);
|
|
140
150
|
}
|
|
141
151
|
|
package/src/prompt.js
CHANGED
|
@@ -15,6 +15,7 @@ RULES:
|
|
|
15
15
|
6. Scope: If the diff is localized, infer a scope (e.g., "auth", "ui", "config").
|
|
16
16
|
7. Body (Optional): If the change is complex, add a brief body after 1 blank line to explain technical nuances.
|
|
17
17
|
8. Context: If a branch name or ticket is provided, incorporate it into the scope or footer if applicable.
|
|
18
|
+
9. Anti-Plagiarism: If the diff shows documentation changes containing example commit messages, DO NOT copy those examples. Always synthesize a new message describing the actual change.
|
|
18
19
|
|
|
19
20
|
Example:
|
|
20
21
|
feat(ui): add loading state to checkout button
|