Skip to content
New issue

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

On saving page only regenerates once #132

Closed
joshuarule opened this issue May 4, 2016 · 26 comments
Closed

On saving page only regenerates once #132

joshuarule opened this issue May 4, 2016 · 26 comments
Labels

Comments

@joshuarule
Copy link

Tried to set up a site today and kept running into something i'm not sure how to resolve. It seems when running running either gulp or gulp --prod I can save a change to a file once and then my site will no longer regenerate.

I'm getting this in the console which i'm not really sure how to make sense of and was hoping you might have an idea where to look

Configuration file: _config.yml
Configuration file: _config.build.yml
               Source: src
         Destination: dist
Incremental build: disabled. Enable with --incremental
      Generating...
                    done in 0.17 seconds.
Auto-regeneration: disabled. Use --watch to enable.
@sondr3
Copy link
Owner

sondr3 commented May 4, 2016

Not sure either, what OS and version of Node and such are you running? Haven't seen anything like this for a long, long while.

@joshuarule
Copy link
Author

I'm on OSX 10.11.4, Node v4.4.3, Ruby 2.0.0p648.

@sondr3
Copy link
Owner

sondr3 commented May 5, 2016

Would it be possible for you to try this in Ruby 2.3 and Node 6?

@grshane
Copy link

grshane commented May 5, 2016

I am having the same issue. Mine will regenerate scss changes but not any changes to html files.
OSX 10.11.4 Node 6 Ruby 2.3.1.

@peepshow
Copy link

peepshow commented May 6, 2016

Ditto.
OSX 10.11.4, Node v4.2.6, Ruby 2.0.0

Content or template edits only inject once on save.
SCSS does continue to update on save however.

@sondr3
Copy link
Owner

sondr3 commented May 6, 2016

Bah, strange. Haven't seen this myself before. I'll look into it.

@sondr3 sondr3 added the bug label May 6, 2016
@sondr3
Copy link
Owner

sondr3 commented May 6, 2016

I think something has changes with how gulp watches files/runs commands. I'm looking into it but due to exams I have very little time until the end of May.

@joshuarule
Copy link
Author

I just upgraded and had similar results.

@nsocrates
Copy link

A temporary fix for this would be to do a manual reload.

gulp.watch(['src/**/*.md', 'src/**/*.html', 'src/**/*.yml'], gulp.series('jekyll')).on('change', reload)

gulp.watch('src/assets/images/**/*').on('change', reload)

@sondr3
Copy link
Owner

sondr3 commented May 7, 2016

Yeah, I used to do that but I think it's not technically correct and has some strange behavior. But I might just revert to it.

@peepshow
Copy link

peepshow commented May 7, 2016

@nsocrates thank you very much, that works fine for now.
Much appreciated.

@wihodges
Copy link

wihodges commented May 9, 2016

I'm having this problem too. The gulp file modification sorta works but having to save multiple times before its refreshes.

@sondr3
Copy link
Owner

sondr3 commented May 9, 2016

You can change your gulpfile to what was posted below, it'll work. Just to confirm, it's only for HTML and markdown it's not working?

@wihodges
Copy link

wihodges commented May 9, 2016

Yea just HTML

@mitchrenton
Copy link

I'm having the same problem with the page changes only regenerating once.

I also get the following warning, seems related...

WARN: Unresolved specs during Gem::Specification.reset: listen (< 3.1, ~> 3.0) WARN: Clearing out unresolved specs.

@sondr3
Copy link
Owner

sondr3 commented May 10, 2016

That error usually comes from Jekyll being upgraded and having older gems in your system. Try to clean out old gems.

@mitchrenton
Copy link

Thanks for the tip there. I've actually reverted Jekyll to 3.0.5 and cleared out older gems. Here's my gem list now...

activesupport (4.2.6) addressable (2.4.0) bigdecimal (1.2.6) bundler (1.12.3) chunky_png (1.3.4) classifier-reborn (2.0.4) coffee-script (2.4.1) coffee-script-source (1.10.0) colorator (0.1) compass (1.0.3) compass-core (1.0.3) compass-import-once (1.0.5) ethon (0.9.0) execjs (2.6.0) faraday (0.9.2) fast-stemmer (1.0.2) ffi (1.9.10) gemoji (2.1.0) github-pages (78) github-pages-health-check (1.1.0) html-pipeline (2.4.0) i18n (0.7.0) io-console (0.4.3) jekyll (3.0.5) jekyll-archives (2.1.0) jekyll-coffeescript (1.0.1) jekyll-feed (0.5.1) jekyll-gist (1.4.0) jekyll-github-metadata (1.11.1) jekyll-mentions (1.1.2) jekyll-paginate (1.1.0) jekyll-redirect-from (0.10.0) jekyll-sass-converter (1.3.0) jekyll-seo-tag (1.4.0) jekyll-sitemap (0.10.0) jekyll-textile-converter (0.1.0) jekyll-watch (1.4.0) jemoji (0.6.2) json (1.8.3, 1.8.1) kramdown (1.10.0) liquid (3.0.6) listen (3.0.6) mercenary (0.3.6) mini_portile2 (2.0.0) minitest (5.8.4) multi_json (1.11.0) multipart-post (2.0.0) net-dns (0.8.0) nokogiri (1.6.7.2) octokit (4.3.0) power_assert (0.2.2) psych (2.0.8) public_suffix (1.5.3) rake (10.4.2) rb-fsevent (0.9.7) rb-inotify (0.9.7) rdiscount (2.1.8) rdoc (4.2.0) redcarpet (3.3.4) RedCloth (4.2.9) rouge (1.10.1) safe_yaml (1.0.4) sass (3.4.22) sawyer (0.7.0) terminal-table (1.5.2) test-unit (3.0.8) thread_safe (0.3.5) typhoeus (0.8.0) tzinfo (1.2.2)

I actually deleted some of the newer version of gems I had that weren't in line with the github pages dependency versions .

Now I have an error Could not find jekyll-sass-converter-1.4.0 in any of the sources (Bundler::GemNotFound) which is looking for a newer version of the jekyll-sass-converter that my 1.3.0 version. When I update that gem, it updates all of the dependencies and I'm out of sync with GitHub pages jekyll dependencies again.

Any ideas what to do here?

@sondr3
Copy link
Owner

sondr3 commented May 10, 2016

Not really, I'd force clean all your gems and reinstall. That's what I usually do, nuke it from orbit 😄

@mitchrenton
Copy link

I'll give it a shot. I just noticed my local grunt CLI version is 1.2.1. Is that right?

@sondr3
Copy link
Owner

sondr3 commented May 10, 2016

Grunt? I hope you meant gulp :P I haven't actually looked at the version of that since I switched to gulp 4.0.

@mitchrenton
Copy link

Haha, sorry yes, I meant Gulp. So I nuked my gems, and re-installed, and that has removed any errors. I still only get the regeneration on the first page change though I'm afraid.

@sondr3
Copy link
Owner

sondr3 commented May 10, 2016

Yeah, I'm in the middle of my exams so I won't have time to fix it until next weekend in afraid :)

@mitchrenton
Copy link

No problem. Good luck with your exams!

@RomanHotsiy
Copy link

RomanHotsiy commented May 14, 2016

The reason is here: gulpjs/gulp#1626 (comment)

I've fixed this by creating function:

function doRealod(done) {
  reload();
  done();
}

and using it instead of reload:

gulp.watch(['src/**/*.md', 'src/**/*.html', 'src/**/*.yml'], gulp.series(log, 'jekyll', doReload));
// ....
gulp.watch('src/assets/images/**/*', doReload);

@sondr3
Copy link
Owner

sondr3 commented May 14, 2016

Yeah, I saw this pop up on the 'gulp' repo yesterday as a pull request on how to use Gulp 4 with BrowserSync. Thanks though! 😃

@sondr3 sondr3 closed this as completed in a28a5ea May 22, 2016
@sondr3
Copy link
Owner

sondr3 commented May 22, 2016

I've pushed a new version of jekyllized to NPM, you can update your settings with yo jekyllized:gulp [--rsync|amazon|pages] after you've updated to the latest version of jekyllized (npm install -g generator-jekyllized@next), but beware that it'll ask you to overwrite your package.json and gulpfile so back them up. From what I can see this works as it should on my end now, but if it doesn't please let me know! 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

8 participants