loclaude 0.0.4 → 0.0.6
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/CHANGELOG.md +21 -0
- package/README.md +4 -0
- package/docker/docker-compose.yml +1 -1
- package/package.json +5 -3
- package/post-install.js +97 -0
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,27 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.0.6] - 2025-02-18
|
|
11
|
+
|
|
12
|
+
### Changed
|
|
13
|
+
|
|
14
|
+
- Default docker volume directory changed from `{{cwd}}/models` to `$HOME/.loclaude/models` to allow for cross-workspace model caching
|
|
15
|
+
|
|
16
|
+
### Added
|
|
17
|
+
|
|
18
|
+
- Adds `models#path` configuration options to `.loclaude/config.json`
|
|
19
|
+
- Adds support for setting `models#path` via environment variable `LOCLAUDE_MODELS_PATH`
|
|
20
|
+
|
|
21
|
+
## [0.0.5] - 2025-01-22
|
|
22
|
+
|
|
23
|
+
### Added
|
|
24
|
+
|
|
25
|
+
- Adds post-install.js ASCII art
|
|
26
|
+
|
|
27
|
+
### Changed
|
|
28
|
+
|
|
29
|
+
- Updates dependency on `@loclaude-internal/cli` from v0.0.3 to v0.0.4
|
|
30
|
+
|
|
10
31
|
## [0.0.4] - 2025-01-22
|
|
11
32
|
|
|
12
33
|
### Changed
|
package/README.md
CHANGED
|
@@ -212,6 +212,9 @@ Example config:
|
|
|
212
212
|
"url": "http://localhost:11434",
|
|
213
213
|
"defaultModel": "qwen3-coder:30b"
|
|
214
214
|
},
|
|
215
|
+
"models": {
|
|
216
|
+
"path": "./models"
|
|
217
|
+
},
|
|
215
218
|
"docker": {
|
|
216
219
|
"composeFile": "./docker-compose.yml",
|
|
217
220
|
"gpu": true
|
|
@@ -230,6 +233,7 @@ Example config:
|
|
|
230
233
|
| `OLLAMA_MODEL` | Default model name | `qwen3-coder:30b` |
|
|
231
234
|
| `LOCLAUDE_COMPOSE_FILE` | Path to docker-compose.yml | `./docker-compose.yml` |
|
|
232
235
|
| `LOCLAUDE_GPU` | Enable GPU (`true`/`false`) | `true` |
|
|
236
|
+
| `LOCLAUDE_MODELS_PATH` | Path to ollama models docker volume | `$HOME/.loclaude/models` |
|
|
233
237
|
|
|
234
238
|
### Priority
|
|
235
239
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "loclaude",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.6",
|
|
4
4
|
"description": "Claude Code with local Ollama LLMs - Zero API costs, no rate limits, complete privacy",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "./LICENSE",
|
|
@@ -48,6 +48,7 @@
|
|
|
48
48
|
"bin",
|
|
49
49
|
"dist",
|
|
50
50
|
"docker/docker-compose.yml",
|
|
51
|
+
"post-install.js",
|
|
51
52
|
"README.md",
|
|
52
53
|
"CHANGELOG.md",
|
|
53
54
|
"LICENSE"
|
|
@@ -64,6 +65,7 @@
|
|
|
64
65
|
},
|
|
65
66
|
"packageManager": "bun@1.3.6",
|
|
66
67
|
"scripts": {
|
|
68
|
+
"postinstall": "node post-install.js",
|
|
67
69
|
"docs": "bunx serve ./docs",
|
|
68
70
|
"lint": "eslint libs",
|
|
69
71
|
"format": "prettier --write libs",
|
|
@@ -76,10 +78,10 @@
|
|
|
76
78
|
"release:rc": "npm publish --tag rc --access public",
|
|
77
79
|
"release:alpha": "npm publish --tag alpha --access public",
|
|
78
80
|
"release:beta": "npm publish --tag beta --access public",
|
|
79
|
-
"postrelease": "export LOCLAUDE_RELEASE_VERSION
|
|
81
|
+
"postrelease": "export LOCLAUDE_RELEASE_VERSION=\"$(jq -r .version package.json)\" && ./scripts/release-commit.sh $LOCLAUDE_RELEASE_VERSION && ./scripts/tag.sh $LOCLAUDE_RELEASE_VERSION"
|
|
80
82
|
},
|
|
81
83
|
"dependencies": {
|
|
82
|
-
"@loclaude-internal/cli": "^0.0.
|
|
84
|
+
"@loclaude-internal/cli": "^0.0.5"
|
|
83
85
|
},
|
|
84
86
|
"peerDependencies": {
|
|
85
87
|
"typescript": "^5"
|
package/post-install.js
ADDED
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
if (process.env.LOCLAUDE_SKIP_POSTINSTALL === 'true') {
|
|
4
|
+
process.exit(0);
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
// ANSI color codes
|
|
8
|
+
const colors = {
|
|
9
|
+
reset: '\x1b[0m',
|
|
10
|
+
bold: '\x1b[1m',
|
|
11
|
+
dim: '\x1b[2m',
|
|
12
|
+
|
|
13
|
+
// Foreground
|
|
14
|
+
black: '\x1b[30m',
|
|
15
|
+
red: '\x1b[31m',
|
|
16
|
+
green: '\x1b[32m',
|
|
17
|
+
yellow: '\x1b[33m',
|
|
18
|
+
blue: '\x1b[34m',
|
|
19
|
+
magenta: '\x1b[35m',
|
|
20
|
+
cyan: '\x1b[36m',
|
|
21
|
+
white: '\x1b[37m',
|
|
22
|
+
|
|
23
|
+
// Bright foreground
|
|
24
|
+
brightRed: '\x1b[91m',
|
|
25
|
+
brightGreen: '\x1b[92m',
|
|
26
|
+
brightYellow: '\x1b[93m',
|
|
27
|
+
brightBlue: '\x1b[94m',
|
|
28
|
+
brightMagenta: '\x1b[95m',
|
|
29
|
+
brightCyan: '\x1b[96m',
|
|
30
|
+
brightWhite: '\x1b[97m',
|
|
31
|
+
|
|
32
|
+
// Background
|
|
33
|
+
bgBlue: '\x1b[44m',
|
|
34
|
+
bgMagenta: '\x1b[45m',
|
|
35
|
+
bgCyan: '\x1b[46m',
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
const c = colors;
|
|
39
|
+
|
|
40
|
+
// ASCII Art Logo
|
|
41
|
+
const logo = `
|
|
42
|
+
${c.brightCyan} ╦ ╔═╗╔═╗╦ ╔═╗╦ ╦╔╦╗╔═╗${c.reset}
|
|
43
|
+
${c.cyan} ║ ║ ║║ ║ ╠═╣║ ║ ║║║╣ ${c.reset}
|
|
44
|
+
${c.brightBlue} ╩═╝╚═╝╚═╝╩═╝╩ ╩╚═╝═╩╝╚═╝${c.reset}
|
|
45
|
+
`;
|
|
46
|
+
|
|
47
|
+
const box = (content, title = '') => {
|
|
48
|
+
const lines = content.split('\n').filter(l => l);
|
|
49
|
+
const width = Math.max(...lines.map(l => l.replace(/\x1b\[[0-9;]*m/g, '').length), title.length + 4);
|
|
50
|
+
|
|
51
|
+
const top = `${c.dim}╭${'─'.repeat(width + 2)}╮${c.reset}`;
|
|
52
|
+
const bottom = `${c.dim}╰${'─'.repeat(width + 2)}╯${c.reset}`;
|
|
53
|
+
const titleLine = title ? `${c.dim}│${c.reset} ${c.bold}${c.brightCyan}${title}${c.reset}${' '.repeat(width - title.length)} ${c.dim}│${c.reset}` : '';
|
|
54
|
+
const separator = title ? `${c.dim}├${'─'.repeat(width + 2)}┤${c.reset}` : '';
|
|
55
|
+
|
|
56
|
+
const body = lines.map(line => {
|
|
57
|
+
const plainLength = line.replace(/\x1b\[[0-9;]*m/g, '').length;
|
|
58
|
+
const padding = ' '.repeat(Math.max(0, width - plainLength));
|
|
59
|
+
return `${c.dim}│${c.reset} ${line}${padding} ${c.dim}│${c.reset}`;
|
|
60
|
+
}).join('\n');
|
|
61
|
+
|
|
62
|
+
return [top, titleLine, separator, body, bottom].filter(Boolean).join('\n');
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
const sparkles = `${c.brightYellow}✨${c.reset}`;
|
|
66
|
+
const rocket = `${c.brightCyan}🚀${c.reset}`;
|
|
67
|
+
const check = `${c.brightGreen}✓${c.reset}`;
|
|
68
|
+
const llama_emoji = `${c.yellow}🦙${c.reset}`;
|
|
69
|
+
|
|
70
|
+
console.log();
|
|
71
|
+
console.log(logo);
|
|
72
|
+
console.log();
|
|
73
|
+
|
|
74
|
+
const installMessage = box([
|
|
75
|
+
`${check} ${c.brightGreen}Successfully installed!${c.reset}`,
|
|
76
|
+
'',
|
|
77
|
+
`${c.dim}Run local LLMs with Claude Code${c.reset}`,
|
|
78
|
+
'',
|
|
79
|
+
`${c.brightWhite}Quick Start:${c.reset}`,
|
|
80
|
+
` ${c.cyan}$${c.reset} ${c.brightWhite}loclaude init${c.reset} ${c.dim}# Set up project${c.reset}`,
|
|
81
|
+
` ${c.cyan}$${c.reset} ${c.brightWhite}loclaude docker-up${c.reset} ${c.dim}# Start Ollama${c.reset}`,
|
|
82
|
+
` ${c.cyan}$${c.reset} ${c.brightWhite}loclaude run${c.reset} ${c.dim}# Launch Claude${c.reset}`,
|
|
83
|
+
'',
|
|
84
|
+
`${c.brightWhite}Commands:${c.reset}`,
|
|
85
|
+
` ${c.yellow}doctor${c.reset} ${c.dim}Check system requirements${c.reset}`,
|
|
86
|
+
` ${c.yellow}models${c.reset} ${c.dim}List available models${c.reset}`,
|
|
87
|
+
` ${c.yellow}models-pull${c.reset} ${c.dim}Download a model${c.reset}`,
|
|
88
|
+
` ${c.yellow}config${c.reset} ${c.dim}Show configuration${c.reset}`,
|
|
89
|
+
'',
|
|
90
|
+
'',
|
|
91
|
+
`${c.dim}Docs: ${c.brightBlue}https://www.npmjs.com/package/loclaude${c.reset}`,
|
|
92
|
+
].join('\n'), `${llama_emoji} loclaude`);
|
|
93
|
+
|
|
94
|
+
console.log(installMessage);
|
|
95
|
+
console.log();
|
|
96
|
+
console.log(` ${sparkles} ${c.brightMagenta}Happy hacking!${c.reset} ${rocket}`);
|
|
97
|
+
console.log();
|