railpack 1.3.4 → 1.3.5
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +38 -0
- data/README.md +29 -0
- data/lib/railpack/bundlers/esbuild_bundler.rb +2 -2
- data/lib/railpack/config.rb +2 -1
- data/lib/railpack/version.rb +1 -1
- data/test/bundler_test.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 5df574f3f72d49cb9a0573f982b8342a4b054e58bd61f0a94c6f257aec700ecc
|
|
4
|
+
data.tar.gz: 67f8b57938595f81fa791fa9f59c9eb269da746dd559db3458eb920ebf593855
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 17d6073b430368114f1bc28b2abb7bde42365bb374a0782af38b7a9f8e72f587e48d37d60614d0c15d6ed204cc6da0e7e3267bb2f94a9f8b4c28e7bbbf148ab7
|
|
7
|
+
data.tar.gz: be7f8bf435883a0d59604b1e7aa646ad5e93c40178fe7980e29a871b46c40e46ab89a4074030bf54922fd843b3487591afc3a2f7360dd0d29ac0e1d514789f7f
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,43 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [1.3.5] - 2026-01-28
|
|
4
|
+
|
|
5
|
+
### 🚀 **Config-Driven Watch Flags - Ultimate Watch Mode Flexibility**
|
|
6
|
+
|
|
7
|
+
This patch release addresses final review feedback, making watch flags fully configurable and adding comprehensive documentation for advanced configuration options.
|
|
8
|
+
|
|
9
|
+
#### ✨ **Config-Driven Watch Flags**
|
|
10
|
+
- **Removed Hardcoded Flags**: Eliminated hardcoded `--watch` from esbuild bundler
|
|
11
|
+
- **YAML Configuration**: Watch behavior now configurable via `watch_flags` in config
|
|
12
|
+
- **Default Watch Config**: Added `watch_flags: ["--watch"]` to esbuild defaults
|
|
13
|
+
- **Flexible Watch Modes**: Support custom watch flags like `--serve=3000` for dev servers
|
|
14
|
+
|
|
15
|
+
#### 🛠️ **Configuration Syntax**
|
|
16
|
+
```yaml
|
|
17
|
+
# Custom watch flags for esbuild
|
|
18
|
+
esbuild:
|
|
19
|
+
target: browser
|
|
20
|
+
format: esm
|
|
21
|
+
watch_flags: ["--watch", "--serve=3000"] # Custom watch behavior
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
#### 📚 **Enhanced Documentation**
|
|
25
|
+
- **Advanced Configuration Section**: Added comprehensive examples for per-bundler overrides
|
|
26
|
+
- **Watch Flags Examples**: Clear documentation for custom watch configurations
|
|
27
|
+
- **Command Override Examples**: Detailed syntax for custom build commands
|
|
28
|
+
- **Developer Guidance**: Step-by-step advanced configuration guide
|
|
29
|
+
|
|
30
|
+
#### 🔧 **Technical Implementation**
|
|
31
|
+
- **Clean Architecture**: Watch commands now use base command + config flags
|
|
32
|
+
- **Backward Compatible**: Existing configurations work unchanged
|
|
33
|
+
- **Test Updates**: Updated test expectations to match new watch command behavior
|
|
34
|
+
- **Zero Breaking Changes**: All existing APIs preserved
|
|
35
|
+
|
|
36
|
+
#### 📊 **Quality Assurance**
|
|
37
|
+
- **All Tests Pass**: 75 tests with 244 assertions continue to pass
|
|
38
|
+
- **Comprehensive Coverage**: Watch flag configuration fully tested
|
|
39
|
+
- **Documentation Complete**: README includes all advanced configuration options
|
|
40
|
+
|
|
3
41
|
## [1.3.4] - 2026-01-28
|
|
4
42
|
|
|
5
43
|
### 🚀 **Per-Bundler Command Overrides - Ultimate Customization**
|
data/README.md
CHANGED
|
@@ -60,6 +60,35 @@ production:
|
|
|
60
60
|
analyze_bundle: true # Production bundle analysis
|
|
61
61
|
```
|
|
62
62
|
|
|
63
|
+
### Advanced Configuration
|
|
64
|
+
|
|
65
|
+
#### Per-Bundler Command Overrides
|
|
66
|
+
|
|
67
|
+
Override default commands for specific bundlers:
|
|
68
|
+
|
|
69
|
+
```yaml
|
|
70
|
+
bundlers:
|
|
71
|
+
esbuild:
|
|
72
|
+
commands:
|
|
73
|
+
build: "esbuild-custom --special-flag"
|
|
74
|
+
watch: "esbuild-custom --watch --dev-mode"
|
|
75
|
+
version: "esbuild-custom --version-check"
|
|
76
|
+
bun:
|
|
77
|
+
commands:
|
|
78
|
+
build: "bunx custom-build"
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
#### Watch Flags Configuration
|
|
82
|
+
|
|
83
|
+
Configure watch-specific flags (different from build flags):
|
|
84
|
+
|
|
85
|
+
```yaml
|
|
86
|
+
esbuild:
|
|
87
|
+
target: browser
|
|
88
|
+
format: esm
|
|
89
|
+
watch_flags: ["--watch", "--serve=3000"] # Custom watch flags
|
|
90
|
+
```
|
|
91
|
+
|
|
63
92
|
## Usage
|
|
64
93
|
|
|
65
94
|
### Basic Commands
|
|
@@ -7,7 +7,7 @@ module Railpack
|
|
|
7
7
|
def default_commands
|
|
8
8
|
{
|
|
9
9
|
build: base_command,
|
|
10
|
-
watch:
|
|
10
|
+
watch: base_command,
|
|
11
11
|
install: "#{package_manager} install",
|
|
12
12
|
version: "#{base_command} --version"
|
|
13
13
|
}
|
|
@@ -20,7 +20,7 @@ module Railpack
|
|
|
20
20
|
|
|
21
21
|
def watch(args = [])
|
|
22
22
|
full_args = build_command_args(:watch, args)
|
|
23
|
-
execute([base_command,
|
|
23
|
+
execute([base_command, *full_args])
|
|
24
24
|
end
|
|
25
25
|
end
|
|
26
26
|
end
|
data/lib/railpack/config.rb
CHANGED
data/lib/railpack/version.rb
CHANGED
data/test/bundler_test.rb
CHANGED
|
@@ -40,7 +40,7 @@ class BundlerTest < Minitest::Test
|
|
|
40
40
|
commands = bundler.send(:commands)
|
|
41
41
|
|
|
42
42
|
assert_equal 'esbuild', commands[:build]
|
|
43
|
-
assert_equal 'esbuild
|
|
43
|
+
assert_equal 'esbuild', commands[:watch]
|
|
44
44
|
assert_equal 'npm install', commands[:install]
|
|
45
45
|
end
|
|
46
46
|
|