@skyreve/reve 1.0.3 → 1.0.4
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 +84 -24
- package/bin/darwin/reve +0 -0
- package/bin/linux/reve +0 -0
- package/bin/reve +0 -0
- package/bin/windows/reve.exe +0 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Reve - SkyReve Platform Command Line Tool
|
|
2
2
|
|
|
3
|
-
Reve is a command line tool that connects the SkyReve platform with GitHub repositories to manage projects and
|
|
3
|
+
Reve is a comprehensive command line tool that connects the SkyReve platform with GitHub repositories to manage projects, environments, and deployments seamlessly. It provides a complete workflow for syncing local development with cloud environments.
|
|
4
4
|
|
|
5
5
|
## 📋 Table of Contents
|
|
6
6
|
|
|
@@ -11,6 +11,7 @@ Reve is a command line tool that connects the SkyReve platform with GitHub repos
|
|
|
11
11
|
5. [Using Reve CLI](#5-using-reve-cli)
|
|
12
12
|
6. [Development Tools](#6-development-tools)
|
|
13
13
|
7. [Publishing to npm](#7-publishing-to-npm)
|
|
14
|
+
8. [Project Structure](#8-project-structure)
|
|
14
15
|
|
|
15
16
|
---
|
|
16
17
|
|
|
@@ -302,6 +303,30 @@ reve env deploy
|
|
|
302
303
|
reve env deploy --force
|
|
303
304
|
```
|
|
304
305
|
|
|
306
|
+
### **5.6 Advanced Features**
|
|
307
|
+
|
|
308
|
+
#### **🔹 File Generation**
|
|
309
|
+
|
|
310
|
+
The `reve env sync` command automatically generates the following files in your project:
|
|
311
|
+
|
|
312
|
+
- **Settings**: `src/settings.yaml` - Project configuration
|
|
313
|
+
- **Tables**: `src/tables/*.yaml` - Database table definitions
|
|
314
|
+
- **APIs**: `src/apis/*.yaml` + `src/apis/*.apy` - API endpoint definitions and view code
|
|
315
|
+
- **Libraries**: `src/libs/*.apy` - Code library implementations
|
|
316
|
+
|
|
317
|
+
#### **🔹 Environment Management**
|
|
318
|
+
|
|
319
|
+
- **Multiple Environments**: Support for dev, staging, production environments
|
|
320
|
+
- **Branch Linking**: Link specific Git branches to Reve environments
|
|
321
|
+
- **Auto Deploy**: Configure automatic deployment on Git push
|
|
322
|
+
- **Conflict Resolution**: Handle deployment conflicts with force option
|
|
323
|
+
|
|
324
|
+
#### **🔹 GitHub Integration**
|
|
325
|
+
|
|
326
|
+
- **Device Flow Authentication**: Secure GitHub login without storing passwords
|
|
327
|
+
- **GitHub App Installation**: Automated GitHub App setup for repositories
|
|
328
|
+
- **Repository Linking**: Connect GitHub repositories to SkyReve projects
|
|
329
|
+
|
|
305
330
|
---
|
|
306
331
|
|
|
307
332
|
## **6. Development Tools**
|
|
@@ -394,6 +419,7 @@ npm version major
|
|
|
394
419
|
```
|
|
395
420
|
|
|
396
421
|
3. **Publish to npm**:
|
|
422
|
+
|
|
397
423
|
```bash
|
|
398
424
|
npm publish
|
|
399
425
|
```
|
|
@@ -488,39 +514,73 @@ npm unpublish @skyreve/reve@version
|
|
|
488
514
|
```
|
|
489
515
|
reve-cli/
|
|
490
516
|
├── cmd/ # Command definitions
|
|
491
|
-
│ ├── root.go # Root command
|
|
492
|
-
│ ├── start.go # Complete setup start command
|
|
493
|
-
│ ├── login.go #
|
|
494
|
-
│ ├── project.go # Project selection
|
|
495
|
-
│ ├── env.go # Environment management command
|
|
496
|
-
│ ├── github.go # GitHub related commands
|
|
517
|
+
│ ├── root.go # Root command with logging and config
|
|
518
|
+
│ ├── start.go # Complete setup start command (6-step process)
|
|
519
|
+
│ ├── login.go # SkyReve platform login with email/password
|
|
520
|
+
│ ├── project.go # Project selection/creation
|
|
521
|
+
│ ├── env.go # Environment management command group
|
|
522
|
+
│ ├── github.go # GitHub related commands group
|
|
497
523
|
│ ├── env/ # Environment management sub-commands
|
|
498
|
-
│ │ ├── start.go #
|
|
499
|
-
│ │ ├── info.go # Project
|
|
500
|
-
│ │ ├── list.go #
|
|
501
|
-
│ │ ├── link.go #
|
|
502
|
-
│ │ ├── sync.go #
|
|
503
|
-
│ │ ├── deploy.go #
|
|
504
|
-
│ │ └── common.go # Common functions
|
|
524
|
+
│ │ ├── start.go # Interactive environment management
|
|
525
|
+
│ │ ├── info.go # Project and environment information
|
|
526
|
+
│ │ ├── list.go # List all environments with branch info
|
|
527
|
+
│ │ ├── link.go # Link GitHub branch to environment
|
|
528
|
+
│ │ ├── sync.go # Sync files (settings, tables, APIs, libs)
|
|
529
|
+
│ │ ├── deploy.go # Deploy to environment
|
|
530
|
+
│ │ └── common.go # Common environment functions
|
|
505
531
|
│ └── github/ # GitHub sub-commands
|
|
506
|
-
│ ├── login.go # GitHub
|
|
532
|
+
│ ├── login.go # GitHub Device Flow authentication
|
|
507
533
|
│ └── install.go # GitHub App installation
|
|
508
534
|
├── internal/ # Internal packages
|
|
509
|
-
│ ├──
|
|
510
|
-
│ ├──
|
|
511
|
-
│ ├──
|
|
512
|
-
│ ├──
|
|
513
|
-
│ ├──
|
|
514
|
-
│
|
|
535
|
+
│ ├── api/ # SkyReve API client and data structures
|
|
536
|
+
│ ├── config/ # Configuration management (.reve directory)
|
|
537
|
+
│ ├── constants/ # Application constants
|
|
538
|
+
│ ├── gen/ # File generation (YAML files for tables, APIs, etc.)
|
|
539
|
+
│ ├── git/ # Git repository operations
|
|
540
|
+
│ ├── github/ # GitHub API client
|
|
541
|
+
│ ├── http/ # HTTP client utilities
|
|
542
|
+
│ ├── logger/ # Logging system
|
|
543
|
+
│ ├── reve/ # SkyReve platform utilities
|
|
544
|
+
│ └── cmd_common/ # Common command utilities
|
|
515
545
|
├── scripts/ # Node.js wrapper scripts
|
|
516
|
-
│ └── reve.js #
|
|
517
|
-
├── bin/ # Built binaries
|
|
518
|
-
├──
|
|
546
|
+
│ └── reve.js # Cross-platform binary launcher
|
|
547
|
+
├── bin/ # Built binaries (platform-specific)
|
|
548
|
+
├── samples/ # Example files and configurations
|
|
549
|
+
├── tests/ # Test files
|
|
550
|
+
├── main.go # Application entry point
|
|
519
551
|
├── package.json # npm package configuration
|
|
520
552
|
├── go.mod # Go module definition
|
|
553
|
+
├── Makefile # Build and development commands
|
|
521
554
|
└── README.md # This file
|
|
522
555
|
```
|
|
523
556
|
|
|
557
|
+
### **8.1 Key Components**
|
|
558
|
+
|
|
559
|
+
#### **🔹 Command Structure**
|
|
560
|
+
|
|
561
|
+
- **Cobra Framework**: Modern CLI framework with subcommands and flags
|
|
562
|
+
- **Persistent Flags**: Global logging and configuration options
|
|
563
|
+
- **Command Groups**: Organized commands (`env`, `github`)
|
|
564
|
+
|
|
565
|
+
#### **🔹 Configuration Management**
|
|
566
|
+
|
|
567
|
+
- **`.reve` Directory**: Local configuration storage
|
|
568
|
+
- **Multi-Environment**: Support for dev/staging/production configs
|
|
569
|
+
- **Secure Storage**: Encrypted token storage
|
|
570
|
+
|
|
571
|
+
#### **🔹 File Generation System**
|
|
572
|
+
|
|
573
|
+
- **YAML Configuration**: Human-readable configuration files for settings, tables, and API definitions
|
|
574
|
+
- **APY Implementation**: Actual implementation code files for APIs and libraries
|
|
575
|
+
- **Modular Structure**: Separate files for tables, APIs, libraries
|
|
576
|
+
- **Template System**: Consistent file generation across environments
|
|
577
|
+
|
|
578
|
+
#### **🔹 GitHub Integration**
|
|
579
|
+
|
|
580
|
+
- **Device Flow**: Secure OAuth without password storage
|
|
581
|
+
- **App Installation**: Automated GitHub App setup
|
|
582
|
+
- **Repository Linking**: Connect repos to SkyReve projects
|
|
583
|
+
|
|
524
584
|
---
|
|
525
585
|
|
|
526
586
|
## **9. Requirements**
|
package/bin/darwin/reve
CHANGED
|
Binary file
|
package/bin/linux/reve
CHANGED
|
Binary file
|
package/bin/reve
CHANGED
|
Binary file
|
package/bin/windows/reve.exe
CHANGED
|
Binary file
|