nalet 0.1.0 → 0.1.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.
- package/README.md +127 -0
- package/package.json +1 -1
package/README.md
ADDED
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
<p align="center">
|
|
2
|
+
<img src="apps/desktop/public/nalet.png" width="80" alt="Nalet" />
|
|
3
|
+
</p>
|
|
4
|
+
|
|
5
|
+
<h1 align="center">Nalet</h1>
|
|
6
|
+
|
|
7
|
+
<p align="center">
|
|
8
|
+
<strong>Valet for Node.js</strong> — effortless local dev environments for Next.js, Nuxt, Remix, Astro, and more.
|
|
9
|
+
</p>
|
|
10
|
+
|
|
11
|
+
<p align="center">
|
|
12
|
+
<a href="https://github.com/MohmmedAshraf/nalet/releases"><img src="https://img.shields.io/github/v/release/MohmmedAshraf/nalet?style=flat-square&color=7C3AED" alt="Release" /></a>
|
|
13
|
+
<a href="https://www.npmjs.com/package/nalet"><img src="https://img.shields.io/npm/v/nalet?style=flat-square&color=7C3AED" alt="npm" /></a>
|
|
14
|
+
<a href="https://github.com/MohmmedAshraf/nalet/blob/main/LICENSE"><img src="https://img.shields.io/github/license/MohmmedAshraf/nalet?style=flat-square" alt="License" /></a>
|
|
15
|
+
</p>
|
|
16
|
+
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
Park a directory, get `.test` domains with HTTPS — automatically. No config files, no Docker, no port juggling.
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
nalet park ~/Sites
|
|
23
|
+
nalet start
|
|
24
|
+
# https://my-app.test is live
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Install
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
# Homebrew (recommended)
|
|
31
|
+
brew install MohmmedAshraf/tap/nalet
|
|
32
|
+
|
|
33
|
+
# npm
|
|
34
|
+
npm install -g nalet
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## Quick Start
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
# One-time setup — installs dnsmasq, Caddy, and generates a local CA certificate
|
|
41
|
+
nalet install
|
|
42
|
+
|
|
43
|
+
# Park a directory — auto-detects all Node.js projects inside
|
|
44
|
+
nalet park ~/Sites
|
|
45
|
+
|
|
46
|
+
# Start all dev servers
|
|
47
|
+
nalet start
|
|
48
|
+
|
|
49
|
+
# Open in your browser
|
|
50
|
+
open https://my-app.test
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
## Supported Frameworks
|
|
54
|
+
|
|
55
|
+
| Framework | Detected By |
|
|
56
|
+
|-----------|-------------|
|
|
57
|
+
| **Next.js** | `next.config.{js,mjs,ts,mts}` |
|
|
58
|
+
| **Nuxt** | `nuxt.config.{js,ts}` |
|
|
59
|
+
| **Remix** | `remix.config.{js,ts}` |
|
|
60
|
+
| **Astro** | `astro.config.{mjs,js,ts}` |
|
|
61
|
+
| **SvelteKit** | `svelte.config.{js,ts}` |
|
|
62
|
+
| **Gatsby** | `gatsby-config.{js,ts,mjs}` |
|
|
63
|
+
| **Eleventy** | `.eleventy.js`, `eleventy.config.{js,cjs,mjs}` |
|
|
64
|
+
| **Vite** | `vite.config.{js,ts,mjs}` |
|
|
65
|
+
|
|
66
|
+
## How It Works
|
|
67
|
+
|
|
68
|
+
```
|
|
69
|
+
Browser → *.test DNS (dnsmasq) → Caddy reverse proxy → nalet-managed dev server
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
1. **dnsmasq** resolves all `*.test` domains to `127.0.0.1`
|
|
73
|
+
2. **Caddy** reverse-proxies each domain to the correct port with auto-HTTPS
|
|
74
|
+
3. **Nalet** manages dev server processes, assigns stable ports, and generates TLS certificates signed by a local CA
|
|
75
|
+
|
|
76
|
+
## CLI
|
|
77
|
+
|
|
78
|
+
```
|
|
79
|
+
nalet install Set up dnsmasq, Caddy, and CA cert
|
|
80
|
+
nalet uninstall Remove all nalet system config
|
|
81
|
+
|
|
82
|
+
nalet park [dir] Park a directory (default: cwd)
|
|
83
|
+
nalet unpark [dir] Stop watching a parked directory
|
|
84
|
+
nalet link [dir] Link a single project
|
|
85
|
+
nalet unlink <name> Remove a linked site
|
|
86
|
+
|
|
87
|
+
nalet start Start all dev servers + proxy
|
|
88
|
+
nalet stop Stop everything
|
|
89
|
+
nalet restart [name] Restart a site or all sites
|
|
90
|
+
|
|
91
|
+
nalet list Show all sites with status
|
|
92
|
+
nalet logs <name> Tail logs for a site
|
|
93
|
+
nalet open <name> Open site in browser
|
|
94
|
+
|
|
95
|
+
nalet secure <name> Enable HTTPS for a site
|
|
96
|
+
nalet unsecure <name> Disable HTTPS for a site
|
|
97
|
+
|
|
98
|
+
nalet gui Launch the desktop app
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
## Desktop App
|
|
102
|
+
|
|
103
|
+
Nalet ships with a Tauri v2 desktop app for managing everything from your menu bar.
|
|
104
|
+
|
|
105
|
+
- Site dashboard with start/stop controls
|
|
106
|
+
- Log viewer per site
|
|
107
|
+
- Settings panel
|
|
108
|
+
- System tray with quick access
|
|
109
|
+
|
|
110
|
+
> **Note:** If you downloaded the `.dmg` manually (not via Homebrew) and macOS blocks it:
|
|
111
|
+
> ```bash
|
|
112
|
+
> xattr -cr /Applications/Nalet.app
|
|
113
|
+
> ```
|
|
114
|
+
|
|
115
|
+
## Requirements
|
|
116
|
+
|
|
117
|
+
- macOS 12+ (Monterey or later)
|
|
118
|
+
- Node.js 18+
|
|
119
|
+
- [Caddy](https://caddyserver.com/) and [dnsmasq](https://thekelleys.org.uk/dnsmasq/doc.html) (installed automatically via `nalet install`)
|
|
120
|
+
|
|
121
|
+
## Contributing
|
|
122
|
+
|
|
123
|
+
See [CONTRIBUTING.md](CONTRIBUTING.md) for setup instructions and guidelines.
|
|
124
|
+
|
|
125
|
+
## License
|
|
126
|
+
|
|
127
|
+
[MIT](LICENSE)
|