smui-example-rollup icon indicating copy to clipboard operation
smui-example-rollup copied to clipboard

yarn build after cloning fresh on Linux does not work (until you run yarn add postcss)

Open xrd opened this issue 4 years ago • 1 comments

I cloned the repository and then ran yarn && yarn build. I get an error with postcss.

chrisdawson@pop-os:~/tmp$ git clone https://github.com/hperrin/smui-example-rollup.git
Cloning into 'smui-example-rollup'...
remote: Enumerating objects: 47, done.
remote: Counting objects: 100% (47/47), done.
remote: Compressing objects: 100% (29/29), done.
remote: Total 47 (delta 22), reused 38 (delta 13), pack-reused 0
Unpacking objects: 100% (47/47), 99.45 KiB | 960.00 KiB/s, done.
chrisdawson@pop-os:~/tmp$ cd smui-example-rollup/
chrisdawson@pop-os:~/tmp/smui-example-rollup$ yarn
yarn install v1.22.10
info No lockfile found.
warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json.
[1/4] Resolving packages...
warning [email protected]: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-commonjs.
warning [email protected]: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-node-resolve.
[2/4] Fetching packages...
info [email protected]: The platform "linux" is incompatible with this module.
info "[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning " > [email protected]" has unmet peer dependency "[email protected]".
warning "rollup-plugin-postcss > [email protected]" has unmet peer dependency "postcss@^8.0.0".
warning "rollup-plugin-postcss > postcss-modules > [email protected]" has unmet peer dependency "postcss@^8.1.0".
warning "rollup-plugin-postcss > postcss-modules > [email protected]" has unmet peer dependency "postcss@^8.1.0".
warning "rollup-plugin-postcss > postcss-modules > [email protected]" has unmet peer dependency "postcss@^8.1.0".
warning "rollup-plugin-postcss > postcss-modules > [email protected]" has unmet peer dependency "postcss@^8.1.0".
warning "rollup-plugin-postcss > postcss-modules > postcss-modules-local-by-default > [email protected]" has unmet peer dependency "postcss@^8.1.0".
[4/4] Building fresh packages...
success Saved lockfile.
Done in 7.52s.
chrisdawson@pop-os:~/tmp/smui-example-rollup$ yarn build
yarn run v1.22.10
$ rollup -c rollup.config.js

index.js → dist/bundle.js...
[!] (plugin postcss) Error: PostCSS plugin postcss-noop-plugin requires PostCSS 8.
Migration guide for end-users:
https://github.com/postcss/postcss/wiki/PostCSS-8-for-end-users
App.scss
Error: PostCSS plugin postcss-noop-plugin requires PostCSS 8.
Migration guide for end-users:
https://github.com/postcss/postcss/wiki/PostCSS-8-for-end-users
    at Processor.normalize (/home/chrisdawson/tmp/smui-example-rollup/node_modules/postcss/lib/processor.js:167:15)
    at new Processor (/home/chrisdawson/tmp/smui-example-rollup/node_modules/postcss/lib/processor.js:56:25)
    at Object.postcss [as default] (/home/chrisdawson/tmp/smui-example-rollup/node_modules/postcss/lib/postcss.js:55:10)
    at /home/chrisdawson/tmp/smui-example-rollup/node_modules/rollup-plugin-postcss/dist/index.js:322:55
    at Generator.next (<anonymous>)
    at asyncGeneratorStep (/home/chrisdawson/tmp/smui-example-rollup/node_modules/rollup-plugin-postcss/dist/index.js:29:24)
    at _next (/home/chrisdawson/tmp/smui-example-rollup/node_modules/rollup-plugin-postcss/dist/index.js:51:9)

error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
chrisdawson@pop-os:~/tmp/smui-example-rollup$ 

https://github.com/hperrin/smui-example-rollup.git

Running yarn add postcss fixes this issue.

xrd avatar Apr 27 '21 06:04 xrd

Same with npm: npm i postcss is required.

robsch avatar May 27 '21 15:05 robsch