How to get rid of "WARNING: no homepage content found in homepage.md"? - html

I'm getting started with KSS using CSS in Depth by Keith Grant as a reference.
At 10.1.4, the author writes
Inside the css directory, create a new file at css/homepage.md. This will be a file in markdown that serves as an introduction to the pattern library. Copy this listing into the file.
# Pattern library
Page heading This is a collection of all the modules in our stylesheet. You may use any of these
modules when constructing a page.
Now run npm run build and the warning about home page content should be gone.
The point is that the warning is not gone for me,
WARNING: no homepage content found in homepage.md.
and indeed opening docs/index.html in the browser shows the content of the directory.
In case it might be related, here's the full output of the npm run kss command:
> simplemodule#1.0.0 kss
> kss --config kss-config.json
Version 9 of Highlight.js has reached EOL and is no longer supported.
Please upgrade or ask whatever dependency you are using to upgrade.
https://github.com/highlightjs/highlight.js/issues/2877
WARNING: no homepage content found in homepage.md

I have solved this problem.For details,please refer to the official demo homepage.md
note:The homepage.md file should be placed at the project root directory
to visit official demo

Related

How to install this Jekyll theme correctly in order to make custom adjustments?

I'm a total newbie when it comes to Jekyll, and have encountered a big problem. I'm probably doing something wrong or missing something, but what?
I find it very confusing trying to install the "Agency Jekyll Theme" which is the first theme I'm trying out. Mostly because there are several ways to do it, the commands don't add up and there is a lot of "you can do this" embedded into what you actually have to do to install it.
These are the guides I've been following:
https://jekyllrb.com/docs/step-by-step/01-setup/
https://www.rubydoc.info/gems/jekyll-agency/1.2.0
http://jekyllthemes.org/themes/agency/
Basically, I've tried all the 3 possible ways to install it without success.
I'm running on Windows.
My problem:
jekyll serve (ran in my site folder) creates a _site folder and content in the subfolders css, img and js. Nothing else is created, not index.html, and other files needed directly under _site folder.
In my site root folder, there are only _config.yml and Gemfile, after completing the initial steps.
There seems to be a problem with actually downloading the full theme into my root folder. When I manually download the agency-jekyll-theme-starter-master.zip and extract the entire content in my root site folder, there is index.html, _data folder, etc. However, in the assets folder, there is only an img folder.
As a result, when I open http://localhost:4000/agency-jekyll-theme-starter/ in a browser there is only a directory listing with the folder "assets".
Where do the css folder and its content come from that generates under _site?
My workaround:
I run jekyll build so that the site in its entirety is placed under _site folder. However, with this process, the whole point of using Jekyll is lost because I have to edit the generated HTML files, CSS files, etc. To change simple stuff like renaming the page/navigation "Services" to another word I have to go through the HTML file and replace all occurrences
My successful attempt to reproduce your issue:
I tried this method from http://jekyllthemes.org/themes/agency/
Using the Starter Template
This is the fastest and easiest way to get up and running on GitHub Pages. Simply generate your own repository by clicking here, then replace the sample content with your own and configure for your needs.
The starter template (that is also linked on the page above) allowed me to start a code space and commit the repo content into my new branch.
I could reproduce your problem, there were no styles when running jekyll serve.
The reason for the issue:
The problem is the baseurl in the _config.yml file. It points to a relative path that does not exist in your repository. Your baseurl / path is "", because you run your server from the root folder, most probably both locally and later remotely using GitHub pages.
The solution for the issue:
In the _config.yml file in your repo, change this one line
from
baseurl: "/agency-jekyll-theme-starter" # the subpath of your site, e.g. /blog
to
baseurl: "" # the subpath of your site, e.g. /blog
Check out https://github.com/cadamini/jekyll-agency-test if you like.
I hope this was understandable and helpful and that you can solve your issue with these instructions. Don't hesitate to comment for further clarification.

How do I correctly start using .readthedocs.yml

I have a basic ReadTheDocs repository. As per the advice of the build page, I sought to use a .readthedocs.yml to configure it:
Configure your documentation builds! Adding a .readthedocs.yml file to your project is the recommended way to configure your documentation builds. You can declare dependencies, set up submodules, and many other great features.
I added a basic .readthedocs.yml:
version: 2
sphinx:
builder: dirhtml
fail_on_warning: true
and got a build failure:
Problem in your project's configuration. Invalid "sphinx.builder": .readthedocs.yml: Your project is configured as "Sphinx Html" in your admin dashboard, but your "sphinx.builder" key does not match.
This was surprising as it seemed contrary to the guidance in the admin dashboard at https://readthedocs.org/dashboard/PROJECTNAME/advanced/ which led me to assume that I could set whatever I liked in the admin dashboard, but it would be overridden by my .readthedocs.yml (which is the behaviour I expected and wanted):
These settings can be configured using a configuration file. That's the recommended way to set up your project. Settings in the configuration file override the settings listed here.
I updated the setting in the admin dashboard to match the .readthedocs.yml and then got a build error:
Sphinx error:
master file /home/docs/checkouts/readthedocs.org/user_builds/PROJECT_NAME/checkouts/latest/source/contents.rst not found
which looks like https://github.com/readthedocs/readthedocs.org/issues/2569 (RTD not finding Sphinx configuration) - but it's not clear why that's happening because prior to adding .readthedocs.yml, the project built just fine.
I'm struggling to model what's actually going on here:
The config file isn't acting as an "overlay" / "override" onto the web settings - as per the first error, some forms of disagreement are a build failure
It's almost like if the config file exists, the web config is ignored - this would explain the contents.rst issue arising, but this isn't consistent with the first error
Adding a python.install entry to .readthedocs.yml eventually got the site building, but it's still not clear to me if I'm generally doing the right thing, and/or how successful future config changes will be.
The reason you're getting the error is that the sphinx version you're using locally doesn't match with the version readthedocs is using at the time you initiated the build process.
See here: You can use a requirements.txt file to use the same version of sphinx you use locally. I had the same issue. I've solved it by simply adding my version Sphinx==3.1.2
Also, I added a .readthedocs.yml file in my project directory where docs/ resides, pointing to where the conf.py because
I was using an extension sphinxcontrib.napoleon which readthedocs build process fails to recognize.
Wanted readthedocsbuild process to use a specific version on Sphinx.
# .readthedocs.yml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
# Required
version: 1
# Build documentation in the docs/ directory with Sphinx
sphinx:
configuration: docs/source/conf.py
# Build documentation with MkDocs
#mkdocs:
# configuration: mkdocs.yml
# Optionally build your docs in additional formats such as PDF
formats:
- pdf
# Optionally set the version of Python and requirements required to build your docs
python:
version: 3.7
install:
- requirements: docs/requirements.txt
a
and added all the dependencies needed to generate the documentation in docs/requirement.txt
Babel==2.8.0
imagesize==1.2.0
readme-renderer==26.0
Sphinx==3.1.2
sphinx-argparse==0.2.5
sphinx-rtd-theme==0.5.0
sphinxcontrib-applehelp==1.0.2
sphinxcontrib-devhelp==1.0.2
sphinxcontrib-htmlhelp==1.0.3
sphinxcontrib-images==0.9.2
sphinxcontrib-jsmath==1.0.1
sphinxcontrib-napoleon==0.7
sphinxcontrib-qthelp==1.0.3
sphinxcontrib-serializinghtml==1.1.4

"Page Not Found" upon deploying site to Netlify via Github repo

I'm a complete beginner to web development and am trying to deploy my first site via Netlify. Despite my site working fine when being displayed from my local machine, I'm given the following error when navigating to my site's URL:
Page Not FoundLooks like you've followed a broken link or entered a URL that doesn't exist on this site.Back to our site
Since my page is functional on my local machine, I believe the error lies within my Github repo and/or my deploy settings. Here's my repo:
https://github.com/Cotton0419/TestSite
And my deploy settings:
Repository: github.com/Cotton0419/TestSite
Base directory: acme
Build command: Not set
Publish directory: acme/disp
Deploy log visibility: Logs are public
Any help would be greatly appreciated, I can supplement more information if need be.
The Base directory on Netlify is only used by the build environment for a reference to your code base (defaults to root of the repository if not given).
The Publish directory would be relative to the base directory. So in your case disp or acme/disp if using the default.
You are referencing assets in a location that does not exist in your published paths, so they would not exist in your deploy to the CDN.
<link rel="stylesheet" href="../css/style.css">
You should move your assets into your deploy disp folder and edit the correct paths into your code files.
Similar problem I encountered today. I decided to upload an old portfolio I had made a while back. Then for some reason after running the URL on Netlify, nothing happened. The only thing that showed up was a prompt similar to yours -
Page Not Found
Looks like you've followed a broken link or entered a URL that doesn't exist on this site.
Back to our site
After revisiting the HTML and CSS files, I realized that I had set the title for my HTML file to porfolio.html instead of index.html which solved my problem!
For this kind of error please kindly check the HTML filename change it into index.html it worked for me!

Jekyll not finding blog posts

Source Code
I am new to Jekyll and got it installed with Grunt and SASS. My issues is that while my test site will show my new posts, When I click on the post link I get an error "Cannot GET /blog/example-post-name".
Grunt doesn't show any errors when running Grunt Serve. However if I run Jekyll serve I get the following errors:
Build Warning: Layout 'article' requested in app/_posts/2015-01-31-optimized-jekyll-site-with-grunt.markdown does not exist.
Build Warning: Layout 'article' requested in app/_posts/2017-03-20-welcome-to-jekyll.markdown does not exist.
Liquid Exception: Could not locate the included file 'blog.html' in any of ["/Users/rich/jekyll-site/_includes"]. Ensure it exists in one of those directories and, if it is a symlink, does not point outside your site source. in app/index.html
jekyll 3.4.2 | Error: Could not locate the included file 'blog.html' in any of ["/Users/rich/jekyll-site/_includes"]. Ensure it exists in one of those directories and, if it is a symlink, does not point outside your site source.
It appears that it cannot find anything in my: _includes, _layouts, ect... folders.
Any help would be appreciated.
Since your template files are in the app/ directory, simply build with app as the source directory.
Add the following to your _config.yml:
source: app
Then run jekyll serve as usual.
Try adding blog.html file in _includes folder or use layout: default in your posts 2015-01-31-optimized-jekyll-site-with-grunt.markdown etc.

Silverstripe - adding a blog?

Need some help adding a blog for this client in Silver stripe CMS.
The client is http://arborwinsys.co.uk/
and the SilverStripe version is - 2.3.7
Would it work installing this module?
https://github.com/silverstripe/silverstripe-blog
The git master branch that you are looking at contains changes for SilverStripe 3. To make the blog work with your SilveStripe version you'll have to go back to the blog module 0.4 or 0.3 by switching the branches.
Steps to adding the blog module to silverstripe 2.3
Download the .zip from https://github.com/silverstripe/silverstripe-blog/tree/0.3
(later versions of the module require later versions of silverstripe)
Extract the contents of the .zip file (it may be within one directory in the .zip file) to a new folder called "blog" in your silverstripe install (it should be at the root level - that is, it should be in the same folder as your "mysite", "cms" and "sapphire" folders
Run a /dev/build on your silverstripe install
Run a ?flush=all on your silverstripe site
if you have any issues:
Ensure you downloaded the correct file (later versions of the module will not work unless you update your silverstripe install)
ensure that you have extracted the files correctly:
e.g. if your website is www,mysite,com and you can access your admin from www,mysite,com/admin - you should have your files in www,mysite,com/blog
ensure you have done a rebuild on your site
try doing a flush
if all else fails, post the error you're receiving back on here.
Good luck!