jekyll / jekyll-sitemap

Jekyll plugin to silently generate a sitemaps.org compliant sitemap for your Jekyll site

Home Page:http://rubygems.org/gems/jekyll-sitemap

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Possibility to add pages that are not in the project

ltraveler opened this issue · comments

Is that any way to manually add external pages (pages that don't exist in the current project) into the sitemap of the webpage?
It would be a very useful functionality, especially for GitHub pages, when you are making a root page on username.github.io with an index of all projects that you have made because the home page of each of the projects, in that case, would be username.github.io/projectname.

This issue has been automatically marked as stale because it has not been commented on for at least two months.

The resources of the Jekyll team are limited, and so we are asking for your help.

If this is a bug and you can still reproduce this error on the master branch, please reply with all of the information you have about it in order to keep the issue open.

If this is a feature request, please consider whether it can be accomplished in another way. If it cannot, please elaborate on why it is core to this project and why you feel more than 80% of users would find this beneficial.

This issue will automatically be closed in two months if no further activity occurs. Thank you for all your contributions.

I am also interested in this functionality. My use case is the same: Main homepage (via github pages) made with Jekyll, and it would be good to be able to link other sub-projects (or sub-sitemaps).

Note: A viable workaround might be:

  • Create a robots.txt manually (see also #292 ).
  • In that robots.txt, reference a sitemap-index.xml instead of the sitemap.xml created by this plugin, and also deploy this manually.
  • In that sitemap-index.xml, reference the sitemaps of the sub-projects and the sitemap.xml of the main page (via sitemapindex / sitemap tags).

Found this too: #252

I think this is a pretty urgent issue. Could someone please take a look at this? @ashmaroli @DirtyF pinging because I see you have recent commits (sorry if you are the wrong people to ping).

So, as @olifre @ltraveler mentioned, it is very common for people to have their main webpage built on Jekyll, and then have multiple projects with gh-pages.

Today I was trying to search my project on Google (astroautomata.com/PySR - which is hosted by GitHub), and was surprised that the webpage wasn't popping up anywhere on Google. I looked at the sitemap, and lo and behold none of those project pages are in any sitemaps generated by Jekyll! My guess is that a significant number of users have had reduced traffic to their project pages because of this, and simply never knew it.

I agree this function is very important!

Me three!

This issue has been automatically marked as stale because it has not been commented on for at least two months.

The resources of the Jekyll team are limited, and so we are asking for your help.

If this is a bug and you can still reproduce this error on the master/main branch, please reply with all of the information you have about it in order to keep the issue open.

If this is a feature request, please consider whether it can be accomplished in another way. If it cannot, please elaborate on why it is core to this project and why you feel more than 80% of users would find this beneficial.

This issue will automatically be closed in two months if no further activity occurs. Thank you for all your contributions.

As described before, this issue is still relevant. Several users commented on the importance already, so we now have 6 comments stating this is important for a larger community, and two comments by stalebot. The automated staleness comments are making this issue quite hard to read and ask for further comments distracting from the issue itself, sadly.

This issue has been automatically marked as stale because it has not been commented on for at least two months.

The resources of the Jekyll team are limited, and so we are asking for your help.

If this is a bug and you can still reproduce this error on the master/main branch, please reply with all of the information you have about it in order to keep the issue open.

If this is a feature request, please consider whether it can be accomplished in another way. If it cannot, please elaborate on why it is core to this project and why you feel more than 80% of users would find this beneficial.

This issue will automatically be closed in two months if no further activity occurs. Thank you for all your contributions.

I know it is repititive (but so is stalebot). As outlined earlier, this issue is relevant for a large community, and there is no good workaround.

To everyone here, Jekyll doesn't read (and therefore have no clue) about content outside current source_directory. So, this plugin cannot inject such metadata.
The alternative would be to have hand-crafted sitemaps without depending on this plugin.

@ashmaroli There is no need for Jekyll to read data outside of the source_directory to implement the functionality requested here, to my understanding. Doing so would also defeat the common use case for GitHub pages, which usually means several independent repositories will be used.

To elaborate, one approach would be to implement what is described in my earlier comment natively, another approach would be to allow to specify specific other pages or other sitemaps to reference via configuration. In short, I see two ways:

  1. Allow to add entries to the sitemap generated by this plugin "manually", via configuration.
  2. Allow to generate an index-sitemap with this plugin, which references the sitemap generated by it and other sitemaps specified by configuration.

Maybe others can contribute more ideas for a potential implementation or contribute one?

Allow to generate an index-sitemap with this plugin, which references the sitemap generated by it and other sitemaps specified by configuration.

@olifre This sounds like a doable request than requesting to add files outside the project directory. Then again, the validity of the entries would solely be on the user providing the values.

Submitted pull request to resolve this. Do check it out and leave feedback. Thanks.