No such file or directory css

Saved searches

Use saved searches to filter your results more quickly

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: ENOENT: no such file or directory #236

Error: ENOENT: no such file or directory #236

Comments

After the update I get the error

Error: ENOENT: no such file or directory, stat 'E:\OpenServer\domains\html\gulp-front\source\static\styles\main.css' at Error (native) Error: ENOENT: no such file or directory, stat 'E:\OpenServer\domains\html\gulp-front\source\static\styles\reset.css' at Error (native)

I’m use gulp-postcss wiht stylefmt, error is disappear if disable this plugin.

var plumber = require('gulp-plumber'); var sourcemaps = require('gulp-sourcemaps'); var stylus = require('gulp-stylus'); var combineMq = require('gulp-combine-mq'); var postcss = require('gulp-postcss'); var csso = require('gulp-csso'); var rename = require('gulp-rename'); var browserSync = require('browser-sync').create(); var rupture = require('rupture'); var autoprefixer = require('autoprefixer'); var stylefmt = require('stylefmt'); var postcssSorting = require('postcss-sorting'); var postcssSortingConfig = JSON.parse( fs.readFileSync( path.join(__dirname, './.postcss-sorting.json') ) ); var options =  browserSync:  server:  baseDir: './dest' > >, stylus:  use: [ rupture(), stylusFileExists() ], 'include css': true >, postcss: [ autoprefixer( cascade: false >), stylefmt(), postcssSorting(postcssSortingConfig) ], csso:  restructure: true, sourceMap: true > >; gulp.task('build:css', function()  return gulp.src([ '*.styl', '!_*.styl' ],  cwd: 'source/static/styles' >) .pipe(plumber(options.plumber)) .pipe(sourcemaps.init()) .pipe(stylus(options.stylus)) .pipe(combineMq( beautify: true >)) .pipe(postcss(options.postcss)) .pipe(gulp.dest('dest/assets/stylesheets')) .pipe(csso(options.csso)) .pipe(rename( suffix: '.min' >)) .pipe(sourcemaps.write('.')) .pipe(gulp.dest('dest/assets/stylesheets')) .pipe(browserSync.stream()); >);

Test on Windows 8.1 x64, Windows 7 x64, Windows 10 x64
NPM 3.5.3
Node.js 4.2.4 and 6.9.1

PS. Change task for readability

The text was updated successfully, but these errors were encountered:

Источник

Saved searches

Use saved searches to filter your results more quickly

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mix.version() error: Error: ENOENT: no such file or directory, open ‘/css/app.css’ #1326

mix.version() error: Error: ENOENT: no such file or directory, open ‘/css/app.css’ #1326

Comments

I’m using standalone version of laravel-mix@1.6.1 with npm@5.5.1 and I’m only compiling scss file:

let mix = require('laravel-mix'); mix .setPublicPath('/') .sass('scss/app.scss', 'css/') .sourceMaps() .version();

When run with version() it throws an error:

fs.js:646 return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode); ^ Error: ENOENT: no such file or directory, open '/css/app.css' at Object.fs.openSync (fs.js:646:18) at Object.fs.readFileSync (fs.js:551:33) . 

When I remove call to version() — it does compile without any issues, but of course, manifest does not have version parameter.

I also tried to changing the public path to the relative ./ :

let mix = require('laravel-mix'); mix .setPublicPath('./') .sass('scss/app.scss', 'css/') .sourceMaps() .version();

but this has resulted with the same error (except for the path, which now was showing as absolute) and mix-manifest.json has cut first letter from the directory — still without the version present:

The text was updated successfully, but these errors were encountered:

It seems I’ve closed it too early.
After compiling for production, I’ve noticed that it messed up some styling — adding :hover event to many elements — looks like standaloneSass might be having some trouble parsing some scss.

When I tried to compile for production with sass but without version — everything works fine except for the fact that I cannot have versioning in manifest, which is quite important for my project.

Also, using standaloneSass method did not product source maps.

The only time that I’ve managed to make it work with version is when I set public path to anything else than root of the project i.e. setPublicPath(‘./dist’) — this way everything renders fine.

Any update on this @JeffreyWay .. I am also having this problem. My config is

mix.setPublicPath(`./`); mix.sass('assets/sass/app.scss', 'css') .js('assets/js/app.js', 'js') .sourceMaps() .version(); 

it then creates the mix-manifest.json file as

I am doing this inside of a WordPress Theme.

yarn run dev yarn run v0.27.5 $ npm run development > @ development /Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer > cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js 95% emitting DONE Compiled successfully in 1109ms 6:47:13 PM fs.js:652 return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode); ^ Error: ENOENT: no such file or directory, open '/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/ss/app.css' at Object.fs.openSync (fs.js:652:18) at Object.fs.readFileSync (fs.js:553:33) at File.read (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/laravel-mix/src/File.js:180:19) at File.version (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/laravel-mix/src/File.js:190:25) at Manifest.hash (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/laravel-mix/src/Manifest.js:55:65) at manifest.forEach.file (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/laravel-mix/src/plugins/CustomTasksPlugin.js:79:47) at Array.forEach () at CustomTasksPlugin.applyVersioning (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/laravel-mix/src/plugins/CustomTasksPlugin.js:79:18) at Compiler.compiler.plugin.stats (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/laravel-mix/src/plugins/CustomTasksPlugin.js:12:22) at Compiler.applyPlugins (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/tapable/lib/Tapable.js:61:14) at emitRecords.err (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/webpack/lib/Compiler.js:264:11) at Compiler.emitRecords (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/webpack/lib/Compiler.js:371:38) at emitAssets.err (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/webpack/lib/Compiler.js:258:10) at applyPluginsAsyncSeries1.err (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/webpack/lib/Compiler.js:364:12) at next (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/tapable/lib/Tapable.js:218:11) at Compiler.compiler.plugin (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/webpack/lib/performance/SizeLimitsPlugin.js:99:4) at Compiler.applyPluginsAsyncSeries1 (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/tapable/lib/Tapable.js:222:13) at Compiler.afterEmit (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/webpack/lib/Compiler.js:361:9) at require.forEach.err (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/webpack/lib/Compiler.js:350:15) at /Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/async/dist/async.js:473:16 at iteratorCallback (/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/async/dist/async.js:1050:13) at /Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/async/dist/async.js:958:16 at /Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/graceful-fs/graceful-fs.js:43:10 at FSReqWrap.oncomplete (fs.js:135:15) npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! @ development: `cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the @ development script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /Users/bretterer/.npm/_logs/2017-12-22T23_47_13_311Z-debug.log error Command failed with exit code 1. info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. 

And here is the full debug.log file

cat /Users/bretterer/.npm/_logs/2017-12-22T23_47_13_311Z-debug.log 0 info it worked if it ends with ok 1 verbose cli [ '/usr/local/Cellar/node/8.4.0/bin/node', 1 verbose cli '/usr/local/bin/npm', 1 verbose cli 'run', 1 verbose cli 'development' ] 2 info using npm@5.4.2 3 info using node@v8.4.0 4 verbose run-script [ 'predevelopment', 'development', 'postdevelopment' ] 5 info lifecycle @~predevelopment: @ 6 info lifecycle @~development: @ 7 verbose lifecycle @~development: unsafe-perm in lifecycle true 8 verbose lifecycle @~development: PATH: /usr/local/lib/node_modules/npm/bin/node-gyp-bin:/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/.bin:/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/.bin:/Users/bretterer/.config/yarn/link/node_modules/.bin:/Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer/node_modules/.bin:/Users/bretterer/.config/yarn/link/node_modules/.bin:/usr/local/Cellar/node/8.4.0/bin:/usr/local/Cellar/node/8.4.0/lib/node_modules/npm/bin/node-gyp-bin:/usr/local/Cellar/node/8.4.0/bin/node_modules/npm/bin/node-gyp-bin:/Users/bretterer/.rvm/gems/ruby-2.1.4/bin:/Users/bretterer/.rvm/gems/ruby-2.1.4@global/bin:/Users/bretterer/.rvm/rubies/ruby-2.1.4/bin:./vendor/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/Users/bretterer/.composer/vendor/bin:/Users/bretterer/.spark:/Users/bretterer/.rvm/bin 9 verbose lifecycle @~development: CWD: /Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer 10 silly lifecycle @~development: Args: [ '-c', 10 silly lifecycle 'cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js' ] 11 silly lifecycle @~development: Returned: code: 1 signal: null 12 info lifecycle @~development: Failed to exec development script 13 verbose stack Error: @ development: `cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js` 13 verbose stack Exit status 1 13 verbose stack at EventEmitter. (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:280:16) 13 verbose stack at emitTwo (events.js:125:13) 13 verbose stack at EventEmitter.emit (events.js:213:7) 13 verbose stack at ChildProcess. (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14) 13 verbose stack at emitTwo (events.js:125:13) 13 verbose stack at ChildProcess.emit (events.js:213:7) 13 verbose stack at maybeClose (internal/child_process.js:927:16) 13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5) 14 verbose pkgid @ 15 verbose cwd /Users/bretterer/Code/brianretterer/wp-content/themes/brianretterer 16 verbose Darwin 17.3.0 17 verbose argv "/usr/local/Cellar/node/8.4.0/bin/node" "/usr/local/bin/npm" "run" "development" 18 verbose node v8.4.0 19 verbose npm v5.4.2 20 error code ELIFECYCLE 21 error errno 1 22 error @ development: `cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js` 22 error Exit status 1 23 error Failed at the @ development script. 23 error This is probably not a problem with npm. There is likely additional logging output above. 24 verbose exit [ 1, true ] 

Running Laravel-Mix 1.7.2
Node: v8.4.0
NPM: 5.4.2
Yarn: v0.27.5

Источник

Читайте также:  Специалист мгту баумана python
Оцените статью