Skip to content

Commit c077232

Browse files
committed
Document how the path substitutions can be used
1 parent a37d663 commit c077232

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,3 +38,21 @@ And a `COMMITHASH` such as:
3838
```
3939
7c16d8b1abeced419c14eb9908baeb4229ac0542
4040
```
41+
42+
### Path Substitutions
43+
44+
It is also possible to use two [path substituitions](http://webpack.github.io/docs/configuration.html#output-filename) on build to get either the revision or version as part of output paths.
45+
46+
- `[git-revision-version]`
47+
- `[git-revision-hash]`
48+
49+
Example:
50+
51+
```javascript
52+
module.exports = {
53+
output: {
54+
publicPath: 'http://my-fancy-cdn.com/[git-revision-version]/',
55+
filename: '[name]-[git-revision-hash].js'
56+
}
57+
}
58+
```

0 commit comments

Comments
 (0)