@ludeo/cli 1.4.9 → 1.4.10
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 +6 -32
- package/README.npm.md +7 -40
- package/dist/ludeo-darwin-amd64 +0 -0
- package/dist/ludeo-darwin-arm64 +0 -0
- package/dist/ludeo-linux-amd64 +0 -0
- package/dist/ludeo-linux-arm64 +0 -0
- package/dist/ludeo-windows-amd64.exe +0 -0
- package/dist/ludeo-windows-arm64.exe +0 -0
- package/package.json +2 -2
- package/scripts/build-readme.js +83 -68
- package/scripts/release.js +0 -17
package/README.md
CHANGED
|
@@ -16,21 +16,19 @@ ludeo version
|
|
|
16
16
|
## Quick Start
|
|
17
17
|
|
|
18
18
|
### Getting Your Game ID and Access Token
|
|
19
|
-
Both your **Game ID** and **Access Token** are available in the [Studio
|
|
19
|
+
Both your **Game ID** and **Access Token** are available in the [Studio Labs](https://studio.ludeo.com) under **Environments**.
|
|
20
20
|
|
|
21
|
-
- **Access Token:** In Environments, click **Create Token**, name it, then copy and save the token (you won
|
|
22
|
-
- **Game ID:** In Environments, it
|
|
21
|
+
- **Access Token:** In Environments, click **Create Token**, name it, then copy and save the token (you won't be able to see it again).
|
|
22
|
+
- **Game ID:** In Environments, it's shown at the top of the page next to the API key.
|
|
23
|
+
|
|
24
|
+
> **Windows note:** All commands below work in Command Prompt, PowerShell, and terminal emulators. For multi-line commands, replace `\` with `^` in Command Prompt.
|
|
23
25
|
|
|
24
26
|
### 1. Authentication
|
|
25
27
|
Save your access token:
|
|
26
|
-
|
|
27
|
-
**macOS / Linux:**
|
|
28
28
|
```bash
|
|
29
29
|
ludeo auth set-token --access-token YOUR_ACCESS_TOKEN
|
|
30
30
|
```
|
|
31
31
|
|
|
32
|
-
**Windows (Command Prompt):** use the same command; for multi-line commands use `^` at the end of each line instead of `\`.
|
|
33
|
-
|
|
34
32
|
You can also check if a token is saved:
|
|
35
33
|
```bash
|
|
36
34
|
ludeo auth status
|
|
@@ -40,20 +38,13 @@ ludeo auth status
|
|
|
40
38
|
|
|
41
39
|
#### Interactive Mode (Recommended for First-Time Users)
|
|
42
40
|
Simply run the upload command without flags to start the interactive wizard:
|
|
43
|
-
|
|
44
|
-
**macOS / Linux:**
|
|
45
41
|
```bash
|
|
46
42
|
ludeo builds upload
|
|
47
43
|
```
|
|
48
44
|
|
|
49
|
-
**Windows (Command Prompt):**
|
|
50
|
-
```cmd
|
|
51
|
-
ludeo builds upload
|
|
52
|
-
```
|
|
53
|
-
|
|
54
45
|
The interactive mode will guide you through:
|
|
55
46
|
1. **Game ID** - Enter your game's unique identifier
|
|
56
|
-
2. **Build Creation Type** - Choose between `new
|
|
47
|
+
2. **Build Creation Type** - Choose between `new` or `sdkFree`
|
|
57
48
|
3. **Build Type** - Select `major` or `minor` (with warning for major builds)
|
|
58
49
|
4. **Major Version Selection** - If creating a minor build, select from existing major versions
|
|
59
50
|
5. **Game Version** - Enter the version number (e.g., 1.2.3)
|
|
@@ -73,8 +64,6 @@ ludeo builds upload --no-interactive [flags...]
|
|
|
73
64
|
Upload your game build with a simple command. The CLI supports two build creation types (**modification builds are not supported from the CLI—use [Studio Labs](https://studio.ludeo.com) for those**):
|
|
74
65
|
|
|
75
66
|
#### New Build (Complete build from scratch) - DEFAULT
|
|
76
|
-
|
|
77
|
-
**macOS / Linux:**
|
|
78
67
|
```bash
|
|
79
68
|
# With explicit build-creation-type
|
|
80
69
|
ludeo builds upload \
|
|
@@ -97,18 +86,6 @@ ludeo builds upload \
|
|
|
97
86
|
--sdk-version "2.0.0"
|
|
98
87
|
```
|
|
99
88
|
|
|
100
|
-
**Windows (Command Prompt):** use `^` at the end of each line for continuation:
|
|
101
|
-
```cmd
|
|
102
|
-
ludeo builds upload ^
|
|
103
|
-
--game-id YOUR_GAME_ID ^
|
|
104
|
-
--exec-path "game.exe" ^
|
|
105
|
-
--local-directory "C:\path\to\your\builds" ^
|
|
106
|
-
--build-creation-type new ^
|
|
107
|
-
--build-type major ^
|
|
108
|
-
--game-version "1.2.3" ^
|
|
109
|
-
--sdk-version "2.0.0"
|
|
110
|
-
```
|
|
111
|
-
|
|
112
89
|
#### SDK Free Build (Performance testing without Ludeo SDK)
|
|
113
90
|
```bash
|
|
114
91
|
ludeo builds upload \
|
|
@@ -227,7 +204,6 @@ The test suite includes:
|
|
|
227
204
|
|
|
228
205
|
## Updating
|
|
229
206
|
|
|
230
|
-
**npm:**
|
|
231
207
|
```bash
|
|
232
208
|
npm update -g @ludeo/cli
|
|
233
209
|
```
|
|
@@ -300,5 +276,3 @@ Need help? Here's how to get support:
|
|
|
300
276
|
1. Check this README and troubleshooting section
|
|
301
277
|
2. **npm:** run `npm rebuild @ludeo/cli` if you encounter issues. **Windows (standalone):** ensure `ludeo.exe` is in your PATH and see the troubleshooting section above.
|
|
302
278
|
3. Contact the Ludeo platform team for additional assistance
|
|
303
|
-
|
|
304
|
-
For detailed documentation and advanced usage, visit the [Ludeo Developer Portal](https://developers.ludeo.com) or [Ludeo CLI Documentation](https://docs.ludeo.com/cli).
|
package/README.npm.md
CHANGED
|
@@ -16,21 +16,19 @@ ludeo version
|
|
|
16
16
|
## Quick Start
|
|
17
17
|
|
|
18
18
|
### Getting Your Game ID and Access Token
|
|
19
|
-
Both your **Game ID** and **Access Token** are available in the [Studio
|
|
19
|
+
Both your **Game ID** and **Access Token** are available in the [Studio Labs](https://studio.ludeo.com) under **Environments**.
|
|
20
20
|
|
|
21
|
-
- **Access Token:** In Environments, click **Create Token**, name it, then copy and save the token (you won
|
|
22
|
-
- **Game ID:** In Environments, it
|
|
21
|
+
- **Access Token:** In Environments, click **Create Token**, name it, then copy and save the token (you won't be able to see it again).
|
|
22
|
+
- **Game ID:** In Environments, it's shown at the top of the page next to the API key.
|
|
23
|
+
|
|
24
|
+
> **Windows note:** All commands below work in Command Prompt, PowerShell, and terminal emulators. For multi-line commands, replace `\` with `^` in Command Prompt.
|
|
23
25
|
|
|
24
26
|
### 1. Authentication
|
|
25
27
|
Save your access token:
|
|
26
|
-
|
|
27
|
-
**macOS / Linux:**
|
|
28
28
|
```bash
|
|
29
29
|
ludeo auth set-token --access-token YOUR_ACCESS_TOKEN
|
|
30
30
|
```
|
|
31
31
|
|
|
32
|
-
**Windows (Command Prompt):** use the same command; for multi-line commands use `^` at the end of each line instead of `\`.
|
|
33
|
-
|
|
34
32
|
You can also check if a token is saved:
|
|
35
33
|
```bash
|
|
36
34
|
ludeo auth status
|
|
@@ -40,20 +38,13 @@ ludeo auth status
|
|
|
40
38
|
|
|
41
39
|
#### Interactive Mode (Recommended for First-Time Users)
|
|
42
40
|
Simply run the upload command without flags to start the interactive wizard:
|
|
43
|
-
|
|
44
|
-
**macOS / Linux:**
|
|
45
41
|
```bash
|
|
46
42
|
ludeo builds upload
|
|
47
43
|
```
|
|
48
44
|
|
|
49
|
-
**Windows (Command Prompt):**
|
|
50
|
-
```cmd
|
|
51
|
-
ludeo builds upload
|
|
52
|
-
```
|
|
53
|
-
|
|
54
45
|
The interactive mode will guide you through:
|
|
55
46
|
1. **Game ID** - Enter your game's unique identifier
|
|
56
|
-
2. **Build Creation Type** - Choose between `new
|
|
47
|
+
2. **Build Creation Type** - Choose between `new` or `sdkFree`
|
|
57
48
|
3. **Build Type** - Select `major` or `minor` (with warning for major builds)
|
|
58
49
|
4. **Major Version Selection** - If creating a minor build, select from existing major versions
|
|
59
50
|
5. **Game Version** - Enter the version number (e.g., 1.2.3)
|
|
@@ -73,8 +64,6 @@ ludeo builds upload --no-interactive [flags...]
|
|
|
73
64
|
Upload your game build with a simple command. The CLI supports two build creation types (**modification builds are not supported from the CLI—use [Studio Labs](https://studio.ludeo.com) for those**):
|
|
74
65
|
|
|
75
66
|
#### New Build (Complete build from scratch) - DEFAULT
|
|
76
|
-
|
|
77
|
-
**macOS / Linux:**
|
|
78
67
|
```bash
|
|
79
68
|
# With explicit build-creation-type
|
|
80
69
|
ludeo builds upload \
|
|
@@ -97,18 +86,6 @@ ludeo builds upload \
|
|
|
97
86
|
--sdk-version "2.0.0"
|
|
98
87
|
```
|
|
99
88
|
|
|
100
|
-
**Windows (Command Prompt):** use `^` at the end of each line for continuation:
|
|
101
|
-
```cmd
|
|
102
|
-
ludeo builds upload ^
|
|
103
|
-
--game-id YOUR_GAME_ID ^
|
|
104
|
-
--exec-path "game.exe" ^
|
|
105
|
-
--local-directory "C:\path\to\your\builds" ^
|
|
106
|
-
--build-creation-type new ^
|
|
107
|
-
--build-type major ^
|
|
108
|
-
--game-version "1.2.3" ^
|
|
109
|
-
--sdk-version "2.0.0"
|
|
110
|
-
```
|
|
111
|
-
|
|
112
89
|
#### SDK Free Build (Performance testing without Ludeo SDK)
|
|
113
90
|
```bash
|
|
114
91
|
ludeo builds upload \
|
|
@@ -183,13 +160,10 @@ ludeo auth logout
|
|
|
183
160
|
|
|
184
161
|
## Updating
|
|
185
162
|
|
|
186
|
-
**npm:**
|
|
187
163
|
```bash
|
|
188
164
|
npm update -g @ludeo/cli
|
|
189
165
|
```
|
|
190
166
|
|
|
191
|
-
**Windows (standalone exe):** download the latest release from the [GitHub releases](https://github.com/ludeo/cli/releases) page and replace your existing executable.
|
|
192
|
-
|
|
193
167
|
## CI/CD Integration
|
|
194
168
|
|
|
195
169
|
### GitHub Actions
|
|
@@ -228,11 +202,6 @@ sudo npm install -g @ludeo/cli
|
|
|
228
202
|
- Run PowerShell as Administrator
|
|
229
203
|
- Ensure Node.js is properly installed
|
|
230
204
|
|
|
231
|
-
**Windows (standalone exe):**
|
|
232
|
-
- **"ludeo is not recognized"** — Add the folder containing `ludeo.exe` to your PATH.
|
|
233
|
-
- **"Access denied" / "Permission denied"** — Right-click the executable → Properties → Unblock → OK, or run Command Prompt as Administrator.
|
|
234
|
-
- **Antivirus blocking** — Add an exception for the executable in your antivirus software.
|
|
235
|
-
|
|
236
205
|
### Common Issues
|
|
237
206
|
|
|
238
207
|
**Authentication errors:**
|
|
@@ -254,7 +223,5 @@ sudo npm install -g @ludeo/cli
|
|
|
254
223
|
Need help? Here's how to get support:
|
|
255
224
|
|
|
256
225
|
1. Check this README and troubleshooting section
|
|
257
|
-
2.
|
|
226
|
+
2. Run `npm rebuild @ludeo/cli` if you encounter issues
|
|
258
227
|
3. Contact the Ludeo platform team for additional assistance
|
|
259
|
-
|
|
260
|
-
For detailed documentation and advanced usage, visit the [Ludeo Developer Portal](https://developers.ludeo.com) or [Ludeo CLI Documentation](https://docs.ludeo.com/cli).
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ludeo/cli",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.10",
|
|
4
4
|
"description": "Ludeo CLI - Upload game builds and manage content on the Ludeo platform",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"bin": {
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"scripts": {
|
|
10
10
|
"build": "make build-all",
|
|
11
11
|
"postinstall": "node scripts/postinstall.js",
|
|
12
|
-
"prepublishOnly": "npm
|
|
12
|
+
"prepublishOnly": "make npm-build",
|
|
13
13
|
"release": "node scripts/release.js",
|
|
14
14
|
"release:patch": "node scripts/release.js patch",
|
|
15
15
|
"release:minor": "node scripts/release.js minor",
|
package/scripts/build-readme.js
CHANGED
|
@@ -1,9 +1,20 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
/**
|
|
3
|
-
* Build README variants from docs/
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
3
|
+
* Build README variants from docs/README.template.md.
|
|
4
|
+
*
|
|
5
|
+
* Outputs:
|
|
6
|
+
* README.md — GitHub repo (includes Testing)
|
|
7
|
+
* README.npm.md — npm package page (no Testing, no standalone exe refs)
|
|
8
|
+
* windows-releases/template/README.md — Windows ZIP release (exe install, file info)
|
|
9
|
+
*
|
|
10
|
+
* Conditional markers in the template:
|
|
11
|
+
* <!-- #if VARIANT --> Include block only for that variant
|
|
12
|
+
* <!-- #if !VARIANT --> Include block for all variants EXCEPT that one
|
|
13
|
+
* <!-- #else --> Opposite of preceding #if
|
|
14
|
+
* <!-- #endif --> End conditional block
|
|
15
|
+
*
|
|
16
|
+
* Supported variant names: repo, npm, windows
|
|
17
|
+
* Template variable: {{VERSION}} (replaced from package.json)
|
|
7
18
|
*
|
|
8
19
|
* Run: node scripts/build-readme.js
|
|
9
20
|
*/
|
|
@@ -12,86 +23,90 @@ const fs = require('fs');
|
|
|
12
23
|
const path = require('path');
|
|
13
24
|
|
|
14
25
|
const ROOT = path.resolve(__dirname, '..');
|
|
15
|
-
const
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
const
|
|
32
|
-
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
const
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
for (const name of order) {
|
|
40
|
-
if (excludeSet && excludeSet.has(name)) continue;
|
|
41
|
-
const file = path.join(dir, name);
|
|
42
|
-
if (!fs.existsSync(file)) {
|
|
43
|
-
console.warn(`Warning: fragment missing: ${name}`);
|
|
26
|
+
const TEMPLATE = path.join(ROOT, 'docs', 'README.template.md');
|
|
27
|
+
|
|
28
|
+
const VARIANTS = {
|
|
29
|
+
repo: { flags: { repo: true, npm: false, windows: false } },
|
|
30
|
+
npm: { flags: { repo: false, npm: true, windows: false } },
|
|
31
|
+
windows: { flags: { repo: false, npm: false, windows: true } },
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
function processTemplate(template, flags, vars) {
|
|
35
|
+
const lines = template.split('\n');
|
|
36
|
+
const output = [];
|
|
37
|
+
const stack = []; // { include: boolean, hadElse: boolean }
|
|
38
|
+
|
|
39
|
+
for (const line of lines) {
|
|
40
|
+
const trimmed = line.trim();
|
|
41
|
+
|
|
42
|
+
const ifMatch = trimmed.match(/^<!--\s*#if\s+(!?)(\w+)\s*-->$/);
|
|
43
|
+
if (ifMatch) {
|
|
44
|
+
const negated = ifMatch[1] === '!';
|
|
45
|
+
const flag = ifMatch[2];
|
|
46
|
+
const value = !!flags[flag];
|
|
47
|
+
const include = negated ? !value : value;
|
|
48
|
+
const parentInclude = stack.length === 0 || stack[stack.length - 1].include;
|
|
49
|
+
stack.push({ include: parentInclude && include, hadElse: false });
|
|
44
50
|
continue;
|
|
45
51
|
}
|
|
46
|
-
parts.push(fs.readFileSync(file, 'utf8').trim());
|
|
47
|
-
}
|
|
48
|
-
return parts.join('\n\n');
|
|
49
|
-
}
|
|
50
52
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
53
|
+
if (trimmed === '<!-- #else -->') {
|
|
54
|
+
if (stack.length > 0) {
|
|
55
|
+
const top = stack[stack.length - 1];
|
|
56
|
+
const parentInclude = stack.length <= 1 || stack[stack.length - 2].include;
|
|
57
|
+
top.include = parentInclude && !top.include;
|
|
58
|
+
top.hadElse = true;
|
|
59
|
+
}
|
|
57
60
|
continue;
|
|
58
61
|
}
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
const file = path.join(README_DIR, name);
|
|
63
|
-
if (!fs.existsSync(file)) {
|
|
64
|
-
console.warn(`Warning: fragment missing: ${name}`);
|
|
62
|
+
|
|
63
|
+
if (trimmed === '<!-- #endif -->') {
|
|
64
|
+
stack.pop();
|
|
65
65
|
continue;
|
|
66
66
|
}
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
if (!fs.existsSync(file)) {
|
|
72
|
-
console.warn(`Warning: Windows fragment missing: ${name}`);
|
|
73
|
-
continue;
|
|
67
|
+
|
|
68
|
+
const shouldInclude = stack.length === 0 || stack[stack.length - 1].include;
|
|
69
|
+
if (shouldInclude) {
|
|
70
|
+
output.push(line);
|
|
74
71
|
}
|
|
75
|
-
parts.push(fs.readFileSync(file, 'utf8').trim());
|
|
76
72
|
}
|
|
77
|
-
|
|
73
|
+
|
|
74
|
+
let result = output.join('\n');
|
|
75
|
+
|
|
76
|
+
for (const [key, value] of Object.entries(vars)) {
|
|
77
|
+
result = result.replace(new RegExp(`\\{\\{${key}\\}\\}`, 'g'), value);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
// Collapse 3+ consecutive blank lines into 2
|
|
81
|
+
result = result.replace(/\n{3,}/g, '\n\n');
|
|
82
|
+
|
|
83
|
+
return result.trim() + '\n';
|
|
78
84
|
}
|
|
79
85
|
|
|
80
86
|
function main() {
|
|
81
|
-
const
|
|
82
|
-
const
|
|
83
|
-
const
|
|
87
|
+
const template = fs.readFileSync(TEMPLATE, 'utf8');
|
|
88
|
+
const version = require(path.join(ROOT, 'package.json')).version;
|
|
89
|
+
const vars = { VERSION: `v${version}` };
|
|
84
90
|
|
|
85
|
-
|
|
86
|
-
|
|
91
|
+
// Build each variant
|
|
92
|
+
for (const [name, config] of Object.entries(VARIANTS)) {
|
|
93
|
+
const content = processTemplate(template, config.flags, vars);
|
|
94
|
+
|
|
95
|
+
let outputPath;
|
|
96
|
+
if (name === 'repo') {
|
|
97
|
+
outputPath = path.join(ROOT, 'README.md');
|
|
98
|
+
} else if (name === 'npm') {
|
|
99
|
+
outputPath = path.join(ROOT, 'README.npm.md');
|
|
100
|
+
} else if (name === 'windows') {
|
|
101
|
+
const dir = path.join(ROOT, 'windows-releases', 'template');
|
|
102
|
+
fs.mkdirSync(dir, { recursive: true });
|
|
103
|
+
outputPath = path.join(dir, 'README.md');
|
|
104
|
+
}
|
|
87
105
|
|
|
88
|
-
|
|
89
|
-
if (!fs.existsSync(windowsTemplateDir)) {
|
|
90
|
-
fs.mkdirSync(windowsTemplateDir, { recursive: true });
|
|
106
|
+
fs.writeFileSync(outputPath, content, 'utf8');
|
|
91
107
|
}
|
|
92
|
-
fs.writeFileSync(path.join(windowsTemplateDir, 'README.md'), windowsReadme + '\n', 'utf8');
|
|
93
108
|
|
|
94
|
-
console.log('Built README.md (repo), README.npm.md (npm), windows-releases/template/README.md (
|
|
109
|
+
console.log('Built README.md (repo), README.npm.md (npm), windows-releases/template/README.md (windows)');
|
|
95
110
|
}
|
|
96
111
|
|
|
97
112
|
main();
|
package/scripts/release.js
CHANGED
|
@@ -84,8 +84,6 @@ function createWindowsRelease(version) {
|
|
|
84
84
|
function updateWindowsDocumentation(version, releaseDir) {
|
|
85
85
|
const files = [
|
|
86
86
|
'README.md',
|
|
87
|
-
'INSTALL.txt',
|
|
88
|
-
'install.bat',
|
|
89
87
|
'PACKAGE_CONTENTS.txt'
|
|
90
88
|
];
|
|
91
89
|
|
|
@@ -127,21 +125,6 @@ function getBasicFileContent(filename, version) {
|
|
|
127
125
|
## Support
|
|
128
126
|
- Email: support@ludeo.com
|
|
129
127
|
- Documentation: https://docs.ludeo.com/cli
|
|
130
|
-
`;
|
|
131
|
-
case 'INSTALL.txt':
|
|
132
|
-
return `LUDEO CLI v${version} - WINDOWS INSTALLATION
|
|
133
|
-
|
|
134
|
-
1. Choose the right executable:
|
|
135
|
-
- ludeo-windows-amd64.exe (Intel/AMD)
|
|
136
|
-
- ludeo-windows-arm64.exe (ARM)
|
|
137
|
-
|
|
138
|
-
2. Rename to "ludeo.exe"
|
|
139
|
-
|
|
140
|
-
3. Add to PATH:
|
|
141
|
-
- Copy to C:\\ludeo-cli\\
|
|
142
|
-
- Add C:\\ludeo-cli\\ to PATH
|
|
143
|
-
|
|
144
|
-
4. Test: ludeo --version
|
|
145
128
|
`;
|
|
146
129
|
default:
|
|
147
130
|
return `# Ludeo CLI v${version} - ${filename}`;
|