Using bundler for Jekyll?

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Using bundler for Jekyll?

Holden Karau
One of the things which comes up when folks update the Spark website is that we often get lots of unnecessarily changed files. I _think_ some of this might come from different jekyll versions on different machines, would folks be OK if we added a requirements that folks use bundler so we can have more consistent versions?

--
Reply | Threaded
Open this post in threaded view
|

Re: Using bundler for Jekyll?

Felix Cheung
Also part of the problem is that the latest news panel is static on each page, so any new link added changes hundreds of files?


From: [hidden email] <[hidden email]> on behalf of Holden Karau <[hidden email]>
Sent: Thursday, March 1, 2018 6:36:43 PM
To: dev
Subject: Using bundler for Jekyll?
 
One of the things which comes up when folks update the Spark website is that we often get lots of unnecessarily changed files. I _think_ some of this might come from different jekyll versions on different machines, would folks be OK if we added a requirements that folks use bundler so we can have more consistent versions?

--
Reply | Threaded
Open this post in threaded view
|

Re: Using bundler for Jekyll?

Holden Karau
Ah yeah bundler wouldn't fix that issue :( Do we happen to have any Jekyll enthusiast lurking on the list who could help out?

On Thu, Mar 1, 2018 at 6:46 PM, Felix Cheung <[hidden email]> wrote:
Also part of the problem is that the latest news panel is static on each page, so any new link added changes hundreds of files?


From: [hidden email] <[hidden email]> on behalf of Holden Karau <[hidden email]>
Sent: Thursday, March 1, 2018 6:36:43 PM
To: dev
Subject: Using bundler for Jekyll?
 
One of the things which comes up when folks update the Spark website is that we often get lots of unnecessarily changed files. I _think_ some of this might come from different jekyll versions on different machines, would folks be OK if we added a requirements that folks use bundler so we can have more consistent versions?

--



--
Reply | Threaded
Open this post in threaded view
|

Re: Using bundler for Jekyll?

Sean Owen-2
In reply to this post by Holden Karau
If a header changes or news changes -- anything that causes a change on the common parts of pages -- yeah you'll get tons of modified files. No way around that as far as I know.

However I've certainly observed differences that seem to be due to differing jekyll versions. To solve that I've always requested we just all use the very latest version. I'm on 3.7.3 for example. If there's a way to enforce that at all, yes, that's good.

On Thu, Mar 1, 2018 at 8:36 PM Holden Karau <[hidden email]> wrote:
One of the things which comes up when folks update the Spark website is that we often get lots of unnecessarily changed files. I _think_ some of this might come from different jekyll versions on different machines, would folks be OK if we added a requirements that folks use bundler so we can have more consistent versions?
Reply | Threaded
Open this post in threaded view
|

Re: Using bundler for Jekyll?

attilapiros
This post was updated on .
I run into the same problem today and tried to find the version where the
diff is minimal, so I wrote a script:

```
#!/bin/zsh

versions=('3.7.3' '3.7.2' '3.7.0' '3.6.3' '3.6.2' '3.6.1' '3.6.0' '3.5.2'
'3.5.1' '3.5.0' '3.4.5' '3.4.4' '3.4.3' '3.4.2' '3.4.1' '3.4.0')

for i in $versions; do
  gem uninstall -a -x jekyll rouge
  gem install jekyll --version $i
  jekyll build
  git diff --stat
  git reset --hard HEAD
done
```

Based on this the best version is: jekyll-3.6.3:

```
site/community.html |  2 +-
 site/sitemap.xml    | 14 +++++++-------
 2 files changed, 8 insertions(+), 8 deletions(-)
```

What about changing the README.md [1] and specifying this exact version?

Moreover changing the command to install it to:
 
```
 gem install jekyll --version 3.6.3
```
 
This installs the right rouge version as it is dependency.

Finally I would give this command too as a prerequisite:

```
  gem uninstall -a -x jekyll rouge
```

Because gem keeps all the installed versions and only one is used.

 
[1]
https://github.com/apache/spark-website/blob/6a5fc2ccaa5ad648dc0b25575ff816c10e648bdf/README.md#L5



--
Sent from: http://apache-spark-developers-list.1001551.n3.nabble.com/

---------------------------------------------------------------------
To unsubscribe e-mail: dev-unsubscribe@spark.apache.org

Reply | Threaded
Open this post in threaded view
|

Re: Using bundler for Jekyll?

Sean Owen-2
Seems fine to me. How about just regenerating the whole site once with the latest version and requiring that?

On Fri, Feb 12, 2021 at 7:09 AM attilapiros <[hidden email]> wrote:
I run into the same problem today and tried to find the version where the
diff is minimal, so I wrote a script:

```
#!/bin/zsh

versions=('3.7.3' '3.7.2' '3.7.0' '3.6.3' '3.6.2' '3.6.1' '3.6.0' '3.5.2'
'3.5.1' '3.5.0' '3.4.5' '3.4.4' '3.4.3' '3.4.2' '3.4.1' '3.4.0')

for i in $versions; do
  gem uninstall -a -x jekyll rouge
  gem install jekyll --version $i
  jekyll build
  git diff --stat
  git reset --hard HEAD
done
```

Based on this the best version is: jekyll-3.6.3:

```
site/community.html |  2 +-
 site/sitemap.xml    | 14 +++++++-------
 2 files changed, 8 insertions(+), 8 deletions(-)
```

What about changing the README.md [1] and specifying this exact version?

Moreover changing the command to install it to:

```
 gem install jekyll --version 3.6.3
```

This installs the right rouge version as it is dependency.

Finally I would give this command too as prequest:

```
  gem uninstall -a -x jekyll rouge
```

Because gem keeps all the installed versions and only one is used.


[1]
https://github.com/apache/spark-website/blob/6a5fc2ccaa5ad648dc0b25575ff816c10e648bdf/README.md#L5



--
Sent from: http://apache-spark-developers-list.1001551.n3.nabble.com/

---------------------------------------------------------------------
To unsubscribe e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Using bundler for Jekyll?

attilapiros
Sure I will do that, too.



--
Sent from: http://apache-spark-developers-list.1001551.n3.nabble.com/

---------------------------------------------------------------------
To unsubscribe e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Using bundler for Jekyll?

attilapiros
Managed to improve the site building a bit more: with a Gemfile we can pin
Jekyll to an exact version. For this we just have to call Jekyll via `bundle
exec jekyll`.
 
The PR [1] is opened.

[1] https://github.com/apache/spark-website/pull/303



--
Sent from: http://apache-spark-developers-list.1001551.n3.nabble.com/

---------------------------------------------------------------------
To unsubscribe e-mail: [hidden email]