nexforge-cli 1.0.1 → 1.0.2

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.
Files changed (2) hide show
  1. package/README.md +68 -29
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,60 +1,99 @@
1
1
  # NexForge CLI 🚀
2
2
 
3
- Welcome to the NexForge Command Line Interface. This tool allows you to deploy your local projects directly to the NexForge platform without pushing to GitHub.
3
+ The official Command Line Interface for **NexForge** - Your custom Platform as a Service (PaaS).
4
+ Deploy, manage, and scale your applications directly from your terminal with zero friction!
4
5
 
5
- ## Getting Started
6
+ ## Installation
6
7
 
7
- If you are developing this CLI locally you can link it so it's available globally on your computer
8
+ You can install the CLI globally via NPM:
8
9
 
9
10
  ```bash
10
- npm link
11
+ npm install -g nexforge-cli
11
12
  ```
12
13
 
13
- Now you can use the `nexforge` command from anywhere!
14
+ ## Available Commands
14
15
 
15
- ## Commands
16
+ Here is the complete list of commands available in the NexForge CLI:
16
17
 
17
- ### 1. Login
18
- Authenticate yourself with your NexForge Project ID.
18
+ ### 🔐 1. `nexforge login`
19
+ **Description:** Authenticate your local machine with your NexForge account.
20
+ **Usage:**
19
21
  ```bash
20
22
  nexforge login
21
23
  ```
22
- This saves your configuration in your home directory `~/.nexforge/config.json`.
24
+ **Details:**
25
+ - Prompts you for your personal **CLI Token** (which you can generate from your NexForge Dashboard Settings).
26
+ - Prompts you for your **Project ID**.
27
+ - Saves your credentials securely in `~/.nexforge/config.json`.
23
28
 
24
- ### 2. Deploy
25
- Package your current directory and upload it to NexForge.
29
+ ---
30
+
31
+ ### ✨ 2. `nexforge init`
32
+ **Description:** Initialize a new NexForge project right from your terminal without opening the browser.
33
+ **Usage:**
26
34
  ```bash
27
- nexforge deploy
35
+ nexforge init
28
36
  ```
29
- This command automatically zips your project (ignoring `node_modules` and `.env`) and sends it to the deployment queue.
37
+ **Details:**
38
+ - Asks for your **Project Name**.
39
+ - Asks for the **Framework** you are using (e.g., React, Vue, Express, Node.js).
40
+ - Automatically registers the project on NexForge servers and links your current directory to the new Project ID.
41
+
42
+ ---
30
43
 
31
- ### 3. Rollback
32
- Revert your live site to the previous stable deployment.
44
+ ### 🚀 3. `nexforge deploy`
45
+ **Description:** Package and deploy your current directory to NexForge.
46
+ **Usage:**
33
47
  ```bash
34
- nexforge rollback
48
+ nexforge deploy
35
49
  ```
36
- *Note: This feature is currently in active development.*
50
+ **Details:**
51
+ - Instantly zips your source code (ignoring `node_modules`, `.git`, and `.env`).
52
+ - Uploads the code to NexForge backend servers.
53
+ - Automatically connects to the live **WebSocket log stream** so you can watch your build progress in real-time.
54
+ - Returns your live deployment URL upon success.
37
55
 
38
56
  ---
39
57
 
40
- ## 📦 How to Publish to NPM
58
+ ### 🌐 4. `nexforge env`
59
+ **Description:** Manage your environment variables securely.
60
+
61
+ #### Push Variables
62
+ ```bash
63
+ nexforge env push
64
+ ```
65
+ - Reads your local `.env` file and securely pushes all variables to your NexForge project.
41
66
 
42
- Once you are satisfied with this CLI and want to share it with the world you can publish it to the NPM registry. This allows anyone to install it by running `npm install -g nexforge-cli`.
67
+ #### Pull Variables
68
+ ```bash
69
+ nexforge env pull
70
+ ```
71
+ - Fetches all environment variables from your live NexForge project and saves them into a local `.env` file.
43
72
 
44
- ### Step 1: Create an NPM Account
45
- If you don't have one go to [npmjs.com](https://www.npmjs.com/) and create an account.
73
+ ---
46
74
 
47
- ### Step 2: Login via Terminal
48
- Run the following command in your terminal and enter your NPM credentials
75
+ ### 📜 5. `nexforge logs`
76
+ **Description:** Stream live build and deployment logs for your project.
77
+ **Usage:**
49
78
  ```bash
50
- npm login
79
+ nexforge logs
51
80
  ```
81
+ **Details:**
82
+ - Connects to the NexForge WebSocket server and streams real-time logs for any ongoing deployment pipelines.
52
83
 
53
- ### Step 3: Publish
54
- Ensure your `package.json` has a unique name (e.g. `nexforge-cli`). Then simply run
84
+ ---
85
+
86
+ ### ⏪ 6. `nexforge rollback`
87
+ **Description:** Instantly revert your live website to a previous stable deployment.
88
+ **Usage:**
55
89
  ```bash
56
- npm publish
90
+ nexforge rollback
57
91
  ```
92
+ **Details:**
93
+ - Fetches a list of your recent successful and failed deployments.
94
+ - Prompts you to select a version.
95
+ - Instantly updates the symbolic links on the server to serve the older version with **zero downtime** and **no rebuild required**.
96
+
97
+ ---
58
98
 
59
- If everything is successful your package is now live on NPM!
60
- Every time you make updates to the code you need to bump the version number in `package.json` (e.g. `"version": "1.0.1"`) before running `npm publish` again.
99
+ ### Built With ❤️ by Manav Sharma
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nexforge-cli",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "Custom Deployment CLI for NexForge",
5
5
  "main": "index.js",
6
6
  "bin": {