@skyreve/reve 1.0.1 → 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/README.md CHANGED
@@ -1,254 +1,549 @@
1
- # Reve CLI - Command Line Interface
1
+ # Reve - SkyReve Platform Command Line Tool
2
2
 
3
- Reve CLI는 Reve 프로젝트를 위한 커맨드라인 도구입니다.
4
- 이 문서는 Reve CLI를 설치하고 사용하는 방법을 설명합니다.
3
+ Reve is a command line tool that connects the SkyReve platform with GitHub repositories to manage projects and environments seamlessly.
4
+
5
+ ## 📋 Table of Contents
6
+
7
+ 1. [Installation](#1-installation)
8
+ 2. [Development Setup](#2-development-setup)
9
+ 3. [Build](#3-build)
10
+ 4. [Environment Configuration](#4-environment-configuration)
11
+ 5. [Using Reve CLI](#5-using-reve-cli)
12
+ 6. [Development Tools](#6-development-tools)
13
+ 7. [Publishing to npm](#7-publishing-to-npm)
5
14
 
6
15
  ---
7
16
 
8
- ## **1. 설치 방법 (Installation)**
17
+ ## **1. Installation**
18
+
19
+ ### **1.1 Install via npm (Recommended)**
20
+
21
+ To use Reve CLI in other npm projects:
9
22
 
10
- ### **1.1 npm을 통한 설치 (권장)**
11
- 다른 npm 프로젝트에서 Reve CLI를 사용하려면:
12
23
  ```bash
13
24
  npm install @skyreve/reve
14
25
  ```
15
26
 
16
- 설치 `npx reve` 명령어로 실행할 있습니다:
27
+ After installation, you can run it using `npx reve`:
28
+
17
29
  ```bash
18
30
  npx reve --help
19
- npx reve status
20
- npx reve init
31
+ npx reve start
21
32
  ```
22
33
 
23
- ### **1.2 글로벌 설치**
24
- 전역적으로 설치하려면:
34
+ ### **1.2 Global Installation**
35
+
36
+ To install globally:
37
+
25
38
  ```bash
26
39
  npm install -g @skyreve/reve
27
40
  ```
28
41
 
29
- 설치 `reve` 명령어로 직접 실행할 있습니다:
42
+ After installation, you can run it directly with the `reve` command:
43
+
30
44
  ```bash
31
45
  reve --help
32
- reve status
33
- reve init
46
+ reve start
34
47
  ```
35
48
 
36
49
  ---
37
50
 
38
- ## **2. 개발 환경 설정 (Development Setup)**
51
+ ## **2. Development Setup**
52
+
53
+ ### **2.1 Install Go**
54
+
55
+ Reve CLI requires **Go**. If Go is not installed, install it using the following commands:
56
+
57
+ **macOS:**
39
58
 
40
- ### **1.1 Go 설치**
41
- Reve CLI는 **Go**를 필요로 합니다. Go가 설치되지 않았다면 아래 명령어로 설치하세요:
42
59
  ```bash
43
60
  brew install go
44
61
  ```
45
62
 
46
- ### **1.2 프로젝트 초기화**
47
- 프로젝트를 클론하고 의존성을 설치합니다:
63
+ **Linux:**
64
+
48
65
  ```bash
49
- git clone git@github.com:SkyReve/reve-cli.git
50
- cd reve-cli
51
- go mod tidy
66
+ # Ubuntu/Debian
67
+ sudo apt update
68
+ sudo apt install golang-go
69
+
70
+ # CentOS/RHEL
71
+ sudo yum install golang
52
72
  ```
53
73
 
54
- ---
74
+ **Windows:**
75
+ Download and install from the [official Go website](https://golang.org/dl/).
55
76
 
56
- ## **2. 빌드 (Build)**
77
+ ### **2.2 Initialize Project**
57
78
 
58
- ### **2.1 npm 스크립트를 통한 빌드 (권장)**
59
- npm을 통해 다양한 환경별로 빌드할 수 있습니다:
79
+ Clone the project and install dependencies:
60
80
 
61
- #### **개발 환경 빌드**
62
81
  ```bash
63
- npm run build-dev
82
+ git clone git@github.com:SkyReve/reve-cli.git
83
+ cd reve-cli
84
+ go mod tidy
64
85
  ```
65
86
 
66
- #### **스테이징 환경 빌드**
67
- ```bash
68
- npm run build-staging
69
- ```
87
+ ---
70
88
 
71
- #### **운영 환경 빌드**
72
- ```bash
73
- npm run build
74
- ```
89
+ ## **3. Build**
75
90
 
76
- #### **정리**
77
- ```bash
78
- npm run clean
79
- ```
91
+ ### **3.1 Basic Build**
80
92
 
81
- ### **2.2 Makefile을 통한 빌드**
93
+ To build a binary for the current OS:
82
94
 
83
- #### **현재 OS에서 환경별 바이너리 빌드**
84
- 현재 OS에서 **개발(debug), 스테이징(staging), 운영(release)** 환경별로 바이너리를 생성하려면:
85
95
  ```bash
86
96
  make
87
97
  ```
88
- 또는 개별 환경별로:
98
+
99
+ or:
100
+
89
101
  ```bash
90
- make build-dev # 개발 환경
91
- make build-stag # 스테이징 환경
92
- make build-prod # 운영 환경
102
+ make build
93
103
  ```
94
104
 
95
- 빌드가 완료되면, `bin/` 디렉토리에 아래 구조로 파일들이 생성됩니다:
105
+ After building, the `reve` binary will be created in the `bin/` directory:
106
+
96
107
  ```bash
97
108
  bin/
98
- ├── debug/reve
99
- ├── staging/reve
100
- └── release/reve
109
+ └── reve
101
110
  ```
102
111
 
103
- #### **모든 OS(Linux, macOS, Windows)용 바이너리 빌드**
112
+ ### **3.2 Build for All Operating Systems**
113
+
114
+ To build binaries for all platforms (Linux, macOS, Windows):
115
+
104
116
  ```bash
105
117
  make build-all
106
118
  ```
107
- 또는 개별 환경별로:
108
- ```bash
109
- make build-all-dev # 개발 환경 (모든 OS)
110
- make build-all-stg # 스테이징 환경 (모든 OS)
111
- make build-all-release # 운영 환경 (모든 OS)
112
- ```
113
119
 
114
- 모든 OS 대한 바이너리를 빌드하면 아래와 같은 구조로 파일이 생성됩니다:
120
+ Building for all OS will create files in the following structure:
121
+
115
122
  ```bash
116
123
  bin/
117
- ├── debug/
118
- ├── linux/reve
119
- │ ├── darwin/reve
120
- │ └── windows/reve.exe
121
- ├── staging/
122
- │ ├── linux/reve
123
- │ ├── darwin/reve
124
- │ └── windows/reve.exe
125
- └── release/
126
- ├── linux/reve
127
- ├── darwin/reve
128
- └── windows/reve.exe
129
- ```
130
-
131
- ### **2.3 빌드된 바이너리 확인**
132
- 빌드된 바이너리는 `bin/` 디렉토리에 저장됩니다. 확인하려면:
124
+ ├── linux/reve
125
+ ├── darwin/reve
126
+ └── windows/reve.exe
127
+ ```
128
+
129
+ ### **3.3 Verify Built Binaries**
130
+
131
+ Built binaries are stored in the `bin/` directory. To check:
132
+
133
133
  ```bash
134
134
  ls -la bin/
135
- # 또는
135
+ # or
136
136
  tree bin/
137
137
  ```
138
138
 
139
139
  ---
140
140
 
141
- ## **3. 환경별 바이너리 설명**
142
- Reve CLI는 환경별로 다른 API 서버를 사용하도록 빌드됩니다.
141
+ ## **4. Environment Configuration**
142
+
143
+ Reve CLI uses the `REVE_ENV` environment variable to connect to different API servers.
144
+
145
+ ### **🔹 Development Environment (dev)**
143
146
 
144
- ### **🔹 debug 환경 (개발)**
145
- - **바이너리 경로:** `bin/debug/reve` (단일 OS) 또는 `bin/debug/{os}/reve` (모든 OS)
146
- - **BaseURL:** `http://127.0.0.1:8000` (기본값)
147
- - **설명:** 개발 환경용 바이너리입니다. 새로운 기능을 테스트하고 디버깅할 때 사용합니다.
147
+ ```bash
148
+ make run-dev
149
+ # or
150
+ REVE_ENV=dev ./bin/reve
151
+ ```
152
+
153
+ - **BaseURL:** `http://localhost:8000`
154
+ - **GitHub App:** [https://github.com/apps/skyreve-staging](https://github.com/apps/skyreve-staging)
155
+ - **Description:** For development environment. Used for testing new features and debugging.
156
+
157
+ ### **🔹 Staging Environment (staging)**
158
+
159
+ ```bash
160
+ make run-staging
161
+ # or
162
+ REVE_ENV=staging ./bin/reve
163
+ ```
148
164
 
149
- ### **🔹 staging 환경 (스테이징)**
150
- - **바이너리 경로:** `bin/staging/reve` (단일 OS) 또는 `bin/staging/{os}/reve` (모든 OS)
151
165
  - **BaseURL:** `https://api.hellreve.world`
152
- - **설명:** 스테이징 환경용 바이너리입니다. 운영 환경과 유사한 조건에서 최종 QA 및 검증에 사용됩니다.
166
+ - **GitHub App:** [https://github.com/apps/skyreve-staging](https://github.com/apps/skyreve-staging)
167
+ - **Description:** For staging environment. Used for final QA and validation under conditions similar to production.
168
+
169
+ ### **🔹 Production Environment (production)**
170
+
171
+ ```bash
172
+ make run-production
173
+ # or
174
+ ./bin/reve
175
+ ```
153
176
 
154
- ### **🔹 release 환경 (운영)**
155
- - **바이너리 경로:** `bin/release/reve` (단일 OS) 또는 `bin/release/{os}/reve` (모든 OS)
156
177
  - **BaseURL:** `https://api.skyreve.cloud`
157
- - **GitHub Client ID:** `Iv23liCYhwlznxTEETKo`
158
- - **설명:** 운영(프로덕션) 환경용 바이너리입니다. 실제 사용자에게 제공되는 서비스 환경에서 사용됩니다.
178
+ - **GitHub App:** [https://github.com/apps/skyreve](https://github.com/apps/skyreve)
179
+ - **Description:** For production environment. Used in the actual service environment provided to real users.
159
180
 
160
181
  ---
161
182
 
162
- ## **4. Reve CLI 사용법 (Using `reve`)**
183
+ ## **5. Using Reve CLI**
184
+
185
+ ### **5.1 Running via npm (Recommended)**
186
+
187
+ When installed via npm:
163
188
 
164
- ### **4.1 npm을 통한 실행 (권장)**
165
- npm으로 설치한 경우:
166
189
  ```bash
167
190
  npx reve [COMMAND] [OPTIONS]
168
- # 또는 글로벌 설치한 경우
191
+ # or if installed globally
169
192
  reve [COMMAND] [OPTIONS]
170
193
  ```
171
194
 
172
- ### **4.2 바이너리 직접 실행**
173
- 빌드된 바이너리를 직접 실행하는 경우:
195
+ ### **5.2 Running Binary Directly**
196
+
197
+ When running the built binary directly:
198
+
174
199
  ```bash
175
- # 개발 환경
176
- ./bin/debug/reve [COMMAND] [OPTIONS]
200
+ # Development environment
201
+ REVE_ENV=dev ./bin/reve [COMMAND] [OPTIONS]
177
202
 
178
- # 스테이징 환경
179
- ./bin/staging/reve [COMMAND] [OPTIONS]
203
+ # Staging environment
204
+ REVE_ENV=staging ./bin/reve [COMMAND] [OPTIONS]
180
205
 
181
- # 운영 환경
182
- ./bin/release/reve [COMMAND] [OPTIONS]
206
+ # Production environment (default)
207
+ ./bin/reve [COMMAND] [OPTIONS]
183
208
  ```
184
209
 
185
- ### **4.3 도움말 확인**
210
+ ### **5.3 Getting Help**
211
+
186
212
  ```bash
187
213
  reve --help
188
- # 또는
214
+ # or
189
215
  npx reve --help
190
216
  ```
191
217
 
192
- ### **4.4 주요 명령어**
193
- | 명령어 | 설명 |
194
- |--------|------|
195
- | `reve init` | SkyReve 프로젝트 초기화 |
196
- | `reve sync` | 원격 데이터와 동기화 |
197
- | `reve status` | 프로젝트 상태 확인 |
198
- | `reve deploy` | 프로젝트 배포 |
199
- | `reve switch` | 프로젝트 및 브랜치 전환 |
200
- | `reve github-init` | GitHub 연동 초기화 |
201
- | `reve github-link` | GitHub 저장소 연결 |
202
- | `reve github-unlink` | GitHub 저장소 연결 해제 |
218
+ ### **5.4 Main Commands**
203
219
 
204
- ---
220
+ #### **🔹 Basic Commands**
221
+
222
+ | Command | Description |
223
+ | -------------------- | ------------------------------------------------------------------------------- |
224
+ | `reve start` | **Quick Start**: Complete 6-step setup process and start environment management |
225
+ | `reve login [email]` | Login to SkyReve platform |
226
+ | `reve project` | Select/create SkyReve project to work with |
227
+
228
+ #### **🔹 Environment Management Commands (`reve env`)**
229
+
230
+ | Command | Description |
231
+ | -------------------------- | --------------------------------------------------------------------------- |
232
+ | `reve env` | Start interactive environment management (same as `reve env start`) |
233
+ | `reve env start` | Start interactive environment management |
234
+ | `reve env info` | Check project info, Git repository info, and GitHub App installation status |
235
+ | `reve env list` | List all Reve environments with linked GitHub branch information |
236
+ | `reve env link <reve_env>` | Link GitHub branch to specific Reve environment |
237
+ | `reve env sync` | Sync current repository branch with Reve environment |
238
+ | `reve env deploy` | Deploy current repository branch to Reve environment |
239
+
240
+ #### **🔹 GitHub Commands (`reve github`)**
205
241
 
206
- ## **5. 기타 (Additional Information)**
242
+ | Command | Description |
243
+ | --------------------- | ----------------------------------------- |
244
+ | `reve github login` | Login to GitHub using Device Flow |
245
+ | `reve github install` | Install GitHub App for current repository |
246
+
247
+ ### **5.5 Usage Examples**
248
+
249
+ #### **First-time Setup (Recommended)**
207
250
 
208
- ### **5.1 실행 방법**
209
- 빌드된 바이너리를 실행하려면:
210
251
  ```bash
211
- # 개발 환경
212
- ./bin/debug/reve --help
252
+ # 1. Complete 6-step setup process (Quick Start)
253
+ reve start
254
+ ```
255
+
256
+ This **Quick Start** command automatically performs the following 6 steps:
257
+
258
+ 1. **🔐 Step 1/6**: Login to SkyReve platform
259
+ 2. **📁 Step 2/6**: Select/create a project
260
+ 3. **🐙 Step 3/6**: Login to GitHub
261
+ 4. **🔧 Step 4/6**: Install GitHub App
262
+ 5. **📦 Step 5/6**: Link GitHub branch to Reve environment
263
+ 6. **🚀 Step 6/6**: Start syncing Reve environment
264
+
265
+ After completion, you'll see: `🎉 All setup steps completed successfully!`
266
+
267
+ #### **Individual Setup**
268
+
269
+ ```bash
270
+ # 1. Login to SkyReve platform
271
+ reve login your-email@example.com
272
+
273
+ # 2. Select project
274
+ reve project
275
+
276
+ # 3. Login to GitHub
277
+ reve github login
213
278
 
214
- # 스테이징 환경
215
- ./bin/staging/reve --help
279
+ # 4. Install GitHub App
280
+ reve github install
216
281
 
217
- # 운영 환경
218
- ./bin/release/reve --help
282
+ # 5. Start environment management
283
+ reve env start
219
284
  ```
220
285
 
221
- ### **5.2 정리 (Clean)**
222
- 불필요한 빌드 파일을 정리하려면:
286
+ #### **Daily Usage**
287
+
223
288
  ```bash
224
- # npm 스크립트 사용
225
- npm run clean
289
+ # Check environment list
290
+ reve env list
291
+
292
+ # Link branch to specific environment
293
+ reve env link main
294
+
295
+ # Sync current branch
296
+ reve env sync
297
+
298
+ # Deploy current branch
299
+ reve env deploy
300
+
301
+ # Force deploy (even with conflicts)
302
+ reve env deploy --force
303
+ ```
304
+
305
+ ---
306
+
307
+ ## **6. Development Tools**
308
+
309
+ ### **6.1 Clean**
226
310
 
227
- # 또는 Makefile 사용
311
+ To clean up unnecessary build files:
312
+
313
+ ```bash
228
314
  make clean
229
315
  ```
230
316
 
231
- ### **5.3 테스트 린트**
317
+ ### **6.2 Test and Lint**
318
+
232
319
  ```bash
233
- # 테스트 실행
320
+ # Run tests
234
321
  make test
235
322
 
236
- # 린트 실행
323
+ # Run linter
237
324
  make lint
238
325
  ```
239
326
 
240
- ### **5.4 개발 모드 실행**
241
- 개발 중 빠른 테스트를 위해:
327
+ ### **6.3 Development Mode**
328
+
329
+ For quick testing during development:
330
+
242
331
  ```bash
243
332
  make run
244
333
  ```
245
334
 
246
- ### **5.5 npm 패키지 배포**
247
- npm에 패키지를 배포하려면:
335
+ ---
336
+
337
+ ## **7. Publishing to npm**
338
+
339
+ ### **7.1 Prerequisites**
340
+
341
+ Before publishing to npm, ensure you have:
342
+
343
+ 1. **npm account**: Create an account at [npmjs.com](https://www.npmjs.com/)
344
+ 2. **npm CLI**: Install npm CLI globally if not already installed
345
+ 3. **Authentication**: Login to npm using `npm login`
346
+
347
+ ### **7.2 Build Process**
348
+
349
+ Before publishing, you need to build the binaries for all platforms:
350
+
351
+ ```bash
352
+ # Build binaries for all platforms
353
+ npm run build
354
+ # or
355
+ make build-all
356
+ ```
357
+
358
+ This creates binaries in the following structure:
359
+
360
+ ```
361
+ bin/
362
+ ├── linux/reve
363
+ ├── darwin/reve
364
+ └── windows/reve.exe
365
+ ```
366
+
367
+ ### **7.3 Version Management**
368
+
369
+ Update the version in `package.json` before publishing:
370
+
371
+ ```bash
372
+ # Patch version (1.0.0 -> 1.0.1)
373
+ npm version patch
374
+
375
+ # Minor version (1.0.0 -> 1.1.0)
376
+ npm version minor
377
+
378
+ # Major version (1.0.0 -> 2.0.0)
379
+ npm version major
380
+ ```
381
+
382
+ ### **7.4 Publishing Steps**
383
+
384
+ 1. **Login to npm**:
385
+
386
+ ```bash
387
+ npm login
388
+ ```
389
+
390
+ 2. **Build binaries**:
391
+
392
+ ```bash
393
+ npm run build
394
+ ```
395
+
396
+ 3. **Publish to npm**:
397
+ ```bash
398
+ npm publish
399
+ ```
400
+
401
+ ### **7.5 Publishing to Different Registries**
402
+
403
+ #### **Publishing to npm (Public)**
404
+
405
+ ```bash
406
+ npm publish
407
+ ```
408
+
409
+ #### **Publishing to npm (Private)**
410
+
411
+ ```bash
412
+ npm publish --access private
413
+ ```
414
+
415
+ #### **Publishing to Custom Registry**
416
+
417
+ ```bash
418
+ npm publish --registry https://your-registry.com
419
+ ```
420
+
421
+ ### **7.6 Verification**
422
+
423
+ After publishing, verify the package:
424
+
425
+ ```bash
426
+ # Check package info
427
+ npm info @skyreve/reve
428
+
429
+ # Test installation
430
+ npm install @skyreve/reve
431
+ npx reve --help
432
+ ```
433
+
434
+ ### **7.7 Automated Publishing**
435
+
436
+ For automated publishing, you can use GitHub Actions or similar CI/CD tools:
437
+
438
+ ```yaml
439
+ # .github/workflows/publish.yml
440
+ name: Publish to npm
441
+
442
+ on:
443
+ release:
444
+ types: [published]
445
+
446
+ jobs:
447
+ publish:
448
+ runs-on: ubuntu-latest
449
+ steps:
450
+ - uses: actions/checkout@v2
451
+ - uses: actions/setup-node@v2
452
+ with:
453
+ node-version: "16"
454
+ registry-url: "https://registry.npmjs.org"
455
+ - run: npm ci
456
+ - run: npm run build
457
+ - run: npm publish
458
+ env:
459
+ NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
460
+ ```
461
+
462
+ ### **7.8 Troubleshooting**
463
+
464
+ #### **Common Issues:**
465
+
466
+ 1. **"Package already exists"**: Update version number
467
+ 2. **"Authentication failed"**: Run `npm login` again
468
+ 3. **"Binary not found"**: Ensure `npm run build` completed successfully
469
+ 4. **"Permission denied"**: Check npm permissions for the package
470
+
471
+ #### **Useful Commands:**
472
+
248
473
  ```bash
249
- npm publish --access public
474
+ # Check who you're logged in as
475
+ npm whoami
476
+
477
+ # Check package permissions
478
+ npm access ls-packages
479
+
480
+ # Unpublish (only within 24 hours)
481
+ npm unpublish @skyreve/reve@version
250
482
  ```
251
483
 
252
484
  ---
253
485
 
254
- ### **🛠 이제 SkyReve CLI를 사용할 준비가 완료되었습니다! 🚀**
486
+ ## **8. Project Structure**
487
+
488
+ ```
489
+ reve-cli/
490
+ ├── cmd/ # Command definitions
491
+ │ ├── root.go # Root command
492
+ │ ├── start.go # Complete setup start command
493
+ │ ├── login.go # Login command
494
+ │ ├── project.go # Project selection command
495
+ │ ├── env.go # Environment management command
496
+ │ ├── github.go # GitHub related commands
497
+ │ ├── env/ # Environment management sub-commands
498
+ │ │ ├── start.go # Environment management start
499
+ │ │ ├── info.go # Project info check
500
+ │ │ ├── list.go # Environment list
501
+ │ │ ├── link.go # Branch linking
502
+ │ │ ├── sync.go # Synchronization
503
+ │ │ ├── deploy.go # Deployment
504
+ │ │ └── common.go # Common functions
505
+ │ └── github/ # GitHub sub-commands
506
+ │ ├── login.go # GitHub login
507
+ │ └── install.go # GitHub App installation
508
+ ├── internal/ # Internal packages
509
+ │ ├── config/ # Configuration management
510
+ │ ├── constants/ # Constant definitions
511
+ │ ├── git/ # Git related functionality
512
+ │ ├── github/ # GitHub API
513
+ │ ├── logger/ # Logging
514
+ │ └── reve/ # Reve API and utilities
515
+ ├── scripts/ # Node.js wrapper scripts
516
+ │ └── reve.js # Main wrapper script
517
+ ├── bin/ # Built binaries
518
+ ├── main.go # Main entry point
519
+ ├── package.json # npm package configuration
520
+ ├── go.mod # Go module definition
521
+ └── README.md # This file
522
+ ```
523
+
524
+ ---
525
+
526
+ ## **9. Requirements**
527
+
528
+ - **Node.js**: 14.0.0 or higher
529
+ - **Go**: Latest stable version
530
+ - **Supported OS**: macOS, Linux, Windows
531
+ - **Supported Architectures**: x64, arm64
532
+
533
+ ---
534
+
535
+ ## **10. License**
536
+
537
+ MIT
538
+
539
+ ---
540
+
541
+ ## **11. Support**
542
+
543
+ For issues or questions, please contact us through [GitHub Issues](https://github.com/SkyReve/reve-cli/issues).
544
+
545
+ ---
546
+
547
+ ### **🛠 You're now ready to use the SkyReve command line tool: `reve`! 🚀**
548
+
549
+ For more detailed information or help, please refer to [GitHub Issues](https://github.com/SkyReve/reve-cli/issues).
package/README.npm.md CHANGED
@@ -1,70 +1,123 @@
1
- # Reve CLI
1
+ # Reve
2
2
 
3
- Reve CLI는 Reve 플랫폼을 위한 커맨드라인 도구입니다.
3
+ Reve is a command line tool for the SkyReve platform that connects your GitHub repositories with SkyReve projects and environments.
4
4
 
5
- ## 설치 방법
5
+ ## Installation
6
6
 
7
- ### npm을 통한 설치 (권장)
7
+ ### Install via npm (Recommended)
8
+
9
+ To use Reve in your npm project:
8
10
 
9
- 다른 npm 프로젝트에서 Reve CLI를 사용하려면:
10
11
  ```bash
11
12
  npm install @skyreve/reve
12
13
  ```
13
14
 
14
- 설치 `npx reve` 명령어로 실행할 있습니다:
15
+ After installation, you can run it using `npx reve`:
16
+
15
17
  ```bash
16
18
  npx reve --help
17
- npx reve status
18
- npx reve init
19
+ npx reve start
19
20
  ```
20
21
 
21
- ### 글로벌 설치
22
+ ### Global Installation
23
+
24
+ To install globally:
22
25
 
23
- 전역적으로 설치하려면:
24
26
  ```bash
25
27
  npm install -g @skyreve/reve
26
28
  ```
27
29
 
28
- 설치 `reve` 명령어로 직접 실행할 있습니다:
30
+ After installation, you can run it directly with the `reve` command:
31
+
29
32
  ```bash
30
33
  reve --help
31
- reve status
32
- reve init
34
+ reve start
35
+ ```
36
+
37
+ ## Quick Start
38
+
39
+ The easiest way to get started with Reve is using the **Quick Start** command:
40
+
41
+ ```bash
42
+ reve start
33
43
  ```
34
44
 
35
- ## 사용법
45
+ This command will guide you through a complete 6-step setup process:
46
+
47
+ 1. **🔐 Step 1/6**: Login to SkyReve platform
48
+ 2. **📁 Step 2/6**: Select/create a project
49
+ 3. **🐙 Step 3/6**: Login to GitHub
50
+ 4. **🔧 Step 4/6**: Install GitHub App
51
+ 5. **📦 Step 5/6**: Link GitHub branch to Reve environment
52
+ 6. **🚀 Step 6/6**: Start syncing Reve environment
53
+
54
+ After completion, you'll see: `🎉 All setup steps completed successfully!`
55
+
56
+ ## Usage
36
57
 
37
- ### 기본 명령어
58
+ ### Main Commands
38
59
 
39
- | 명령어 | 설명 |
40
- |--------|------|
41
- | `reve init` | SkyReve 프로젝트 초기화 |
42
- | `reve sync` | 원격 데이터와 동기화 |
43
- | `reve status` | 프로젝트 상태 확인 |
44
- | `reve deploy` | 프로젝트 배포 |
45
- | `reve switch` | 프로젝트 브랜치 전환 |
46
- | `reve github-init` | GitHub 연동 초기화 |
47
- | `reve github-link` | GitHub 저장소 연결 |
48
- | `reve github-unlink` | GitHub 저장소 연결 해제 |
60
+ | Command | Description |
61
+ | --------------------- | ---------------------------------------------- |
62
+ | `reve start` | **Quick Start**: Complete 6-step setup process |
63
+ | `reve login [email]` | Login to SkyReve platform |
64
+ | `reve project` | Select/create SkyReve project |
65
+ | `reve env` | Start interactive environment management |
66
+ | `reve env list` | List all Reve environments |
67
+ | `reve env link <env>` | Link GitHub branch to Reve environment |
68
+ | `reve env sync` | Sync current branch with Reve environment |
69
+ | `reve env deploy` | Deploy current branch to Reve environment |
70
+ | `reve github login` | Login to GitHub using Device Flow |
71
+ | `reve github install` | Install GitHub App for current repository |
49
72
 
50
- ### 도움말 확인
73
+ ### Getting Help
51
74
 
52
75
  ```bash
53
76
  reve --help
54
- # 또는
77
+ # or
55
78
  npx reve --help
56
79
  ```
57
80
 
58
- ## 요구사항
81
+ ### Daily Usage Examples
59
82
 
60
- - Node.js 14.0.0 이상
61
- - 지원 OS: macOS, Linux, Windows
62
- - 지원 아키텍처: x64, arm64
83
+ ```bash
84
+ # Check environment list
85
+ reve env list
86
+
87
+ # Link branch to specific environment
88
+ reve env link main
89
+
90
+ # Sync current branch
91
+ reve env sync
92
+
93
+ # Deploy current branch
94
+ reve env deploy
95
+
96
+ # Force deploy (even with conflicts)
97
+ reve env deploy --force
98
+ ```
63
99
 
64
- ## 라이선스
100
+ ## Requirements
101
+
102
+ - Node.js 14.0.0 or higher
103
+ - Supported OS: macOS, Linux, Windows
104
+ - Supported Architectures: x64, arm64
105
+
106
+ ## License
65
107
 
66
108
  MIT
67
109
 
68
- ## 지원
110
+ ## Support
111
+
112
+ If you encounter any issues or have questions, please report them through [GitHub Issues](https://github.com/skyreve/reve-cli/issues).
113
+
114
+ ## What is SkyReve?
115
+
116
+ SkyReve is a platform that allows you to manage projects and environments by linking them with GitHub repositories and branches. Reve CLI makes it easy to:
117
+
118
+ - Connect your GitHub repositories to SkyReve projects
119
+ - Manage different environments (development, staging, production)
120
+ - Deploy your code to various environments
121
+ - Sync your local development with cloud environments
69
122
 
70
- 문제가 있거나 질문이 있으시면 [GitHub Issues](https://github.com/skyreve/reve-cli/issues)를 통해 문의해주세요.
123
+ Get started today with `reve start`! 🚀
Binary file
Binary file
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@skyreve/reve",
3
- "version": "1.0.1",
4
- "description": "Reve CLI - A command line tool for Reve platform",
3
+ "version": "1.0.3",
4
+ "description": "Reve - A command line tool for Reve platform",
5
5
  "main": "index.js",
6
6
  "scripts": {
7
7
  "reve": "node scripts/reve.js",
package/scripts/reve.js CHANGED
@@ -9,21 +9,21 @@ const os = require('os');
9
9
  const getBinaryPath = () => {
10
10
  const platform = os.platform();
11
11
  const arch = os.arch();
12
-
12
+
13
13
  // 플랫폼별 디렉토리 매핑
14
14
  const platformMap = {
15
15
  'darwin': 'darwin',
16
- 'linux': 'linux',
16
+ 'linux': 'linux',
17
17
  'win32': 'windows'
18
18
  };
19
-
19
+
20
20
  const platformDir = platformMap[platform] || 'linux';
21
- const binDir = path.join(__dirname, '..', 'bin', 'release', platformDir);
22
-
21
+ const binDir = path.join(__dirname, '..', 'bin', platformDir);
22
+
23
23
  // Windows의 경우 .exe 확장자 추가
24
24
  const binaryName = platform === 'win32' ? 'reve.exe' : 'reve';
25
25
  const binaryPath = path.join(binDir, binaryName);
26
-
26
+
27
27
  return binaryPath;
28
28
  };
29
29
 
@@ -42,14 +42,14 @@ const runBinary = (binaryPath, args) => {
42
42
  stdio: 'inherit',
43
43
  cwd: process.cwd()
44
44
  };
45
-
45
+
46
46
  const child = spawn(binaryPath, args, options);
47
-
47
+
48
48
  child.on('error', (error) => {
49
49
  console.error(`❌ Reve binary execution error: ${error.message}`);
50
50
  process.exit(1);
51
51
  });
52
-
52
+
53
53
  child.on('exit', (code) => {
54
54
  process.exit(code);
55
55
  });
@@ -58,17 +58,17 @@ const runBinary = (binaryPath, args) => {
58
58
  // 메인 실행 함수
59
59
  const main = () => {
60
60
  const binaryPath = getBinaryPath();
61
-
61
+
62
62
  // 바이너리 존재 확인
63
63
  if (!checkBinaryExists(binaryPath)) {
64
64
  console.error(`❌ Reve binary not found: ${binaryPath}`);
65
65
  console.error('Please run build first: npm run build');
66
66
  process.exit(1);
67
67
  }
68
-
68
+
69
69
  // 명령행 인수 전달 (node와 스크립트 이름 제외)
70
70
  const args = process.argv.slice(2);
71
-
71
+
72
72
  // 바이너리 실행
73
73
  runBinary(binaryPath, args);
74
74
  };
Binary file
Binary file
Binary file
Binary file
Binary file
package/bin/revecli-dev DELETED
Binary file
Binary file
Binary file
Binary file
package/bin/revecli-prod DELETED
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file