Skip to content

Commit

Permalink
chore: Add bundlemon config for transpiled folder
Browse files Browse the repository at this point in the history
Following the update of some subdependencies,
the `baseDir` parameter of the bundlemon
configuration no longer works if it is not filled in
or simply with `"."` or `"./"`.

As on `cozy-ui` we want to monitor 2 folders at
the root of the project, the trick is to modify the main
config file to only take care of one folder and create a
second one running in parallel to take care of the second folder.
  • Loading branch information
Merkur39 committed Aug 3, 2023
1 parent 48182a1 commit 3eafcc2
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 13 deletions.
15 changes: 15 additions & 0 deletions .bundlemon_transpiled
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"baseDir": "./transpiled",
"files": [
{
"path": "react/stylesheet.css",
"maxPercentIncrease": 10
}
],
"groups": [
{
"path": "react/**"
}
],
"reportOutput": ["github"]
}
15 changes: 3 additions & 12 deletions .bundlemonrc
Original file line number Diff line number Diff line change
@@ -1,23 +1,14 @@
{
"baseDir": ".",
"baseDir": "./dist",
"files": [
{
"path": "dist/cozy-ui.min.css",
"path": "cozy-ui.min.css",
"maxPercentIncrease": 10
},
{
"path": "dist/cozy-ui.utils.min.css",
"maxPercentIncrease": 10
},
{
"path": "transpiled/react/stylesheet.css",
"path": "cozy-ui.utils.min.css",
"maxPercentIncrease": 10
}
],
"groups": [
{
"path": "transpiled/react/**"
}
],
"reportOutput": ["github"]
}
10 changes: 10 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,16 @@ jobs:
- js-binaries
- css-binaries
if: commit_message =~ /^((?!\[only argos\]).)*$/ # if commit message doesn't contain "[only argos]" string
- name: 'Bundlemon transpiled'
stage: 'test'
script:
- yarn bundlemon:transpiled
workspaces:
use:
- sprite-palette-binaries
- js-binaries
- css-binaries
if: commit_message =~ /^((?!\[only argos\]).)*$/ # if commit message doesn't contain "[only argos]" string
- name: 'Argos desktop'
stage: 'screenshots'
script: |
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@
"start:doc:kss": "nodemon --ext styl,md --watch stylus --exec 'yarn build:doc:kss && http-server build/styleguide -p 4242'",
"start": "yarn build --watch",
"removeEmptyCss": "node scripts/removeEmptyCss.js",
"optimizeIcons": "svgo -r --folder assets/icons"
"optimizeIcons": "svgo -r --folder assets/icons",
"bundlemon:transpiled": "bundlemon --config .bundlemon_transpiled"
},
"types": "dist/index.d.ts",
"sideEffects": [
Expand Down

0 comments on commit 3eafcc2

Please sign in to comment.