When running bundle exec jekyll serve, I get the following: Server address: http://0.0.0.0:4000//
Where does // come from in my config? How do I get rid of it to get http://0.0.0.0:4000/ ?
_config.yaml
url: https://blabla.com
source: .
destination: ./_site
plugins_dir: ./_plugins
layouts_dir: ./_layouts
include: ['.htaccess']
exclude: []
timezone: UTC+1
plugins: [jekyll-paginate]
# Show future posts
future: true
show_drafts: nil
limit_posts: 500
highlighter: rouge
relative_permalinks: false
permalink: pretty
paginate_path: 'posts/:num'
paginate: 5
markdown: kramdown
markdown_ext: kramdown, markdown,mkd,mkdn,md
textile_ext: textile
kramdown:
input: GFM
syntax_highlighter: rouge
excerpt_separator: "<!-- more -->"
safe: false
host: 0.0.0.0
port: 4000
baseurl: /
lsi: false
rdiscount:
extensions: []
redcarpet:
extensions: []
kramdown:
auto_ids: true
footnote_nr: 1
entity_output: as_char
toc_levels: 1..6
smart_quotes: lsquo,rsquo,ldquo,rdquo
enable_coderay: false
input: GFM
syntax_highlighter_opts:
coderay:
coderay_wrap: div
coderay_line_numbers: inline
coderay_line_numbers_start: 1
coderay_tab_width: 4
coderay_bold_every: 10
coderay_css: style
redcloth:
hard_breaks: true
#
# jekyll-assets: see more at https://github.com/ixti/jekyll-assets
# bundle exec jekyll serve
#
assets:
dirname: assets
baseurl: /assets/
sources:
- _assets/javascripts
- _assets/stylesheets
- _assets/images
- _assets/fonts
js_compressor: uglifier
css_compressor: sass
cachebust: none
cache: true
gzip: [ text/css, application/javascript ]
debug: true
compressors:
uglifier:
harmony: true
compress:
unused: false
Jekyll default config : baseurl: "" # the subpath of your site, e.g. /blog
Your baseurl must be empty.
Related
In my Github actions CI workflow I am using GitVersion to determine the build versions. Specifically I am using the plugin
gittools/actions/gitversion/execute#v0.9.15
What I would like to achieve is the following gitversion behavior:
When I create a release branch release-1.3.3 from dev, then the calculated version should be 1.3.3
When I merge a fix branch fix/some-fix into release-1.3.3 , then the calculated version should be 1.3.3-1
I.e. I want to be able to set no tag when the release branch version is calculated the first time and then have some custom suffix that's incremented automatically, e.g. -1, -2, etc..
Is this possible? Right now, I configured a patch increment on the release branch, i.e. any commits to release-1.3.3 would uptick the version to 1.3.4, 1.3.5, etc.
Please see my version config file that is used by gittools/actions/gitversion:
tag-prefix: 'demo\-'
mode: ContinuousDelivery
branches:
dev:
regex: ^dev(elop)?(ment)?$
mode: ContinuousDeployment
tag: "dev"
increment: Patch
prevent-increment-of-merged-branch-version: true
track-merge-target: false
source-branches: []
tracks-release-branches: true
is-release-branch: false
is-mainline: true
pre-release-weight: 0
release:
regex: ^releases?[/-]
mode: ContinuousDelivery
tag: ""
increment: Patch
prevent-increment-of-merged-branch-version: true
track-merge-target: false
source-branches: [ 'dev' ]
tracks-release-branches: false
is-release-branch: true
is-mainline: false
pre-release-weight: 30000
feature:
regex: ^features?[/-]
mode: ContinuousDelivery
tag: useBranchName
increment: Inherit
prevent-increment-of-merged-branch-version: false
track-merge-target: false
source-branches: [ 'dev', 'release', 'feature', 'fix' ]
tracks-release-branches: false
is-release-branch: false
is-mainline: false
pre-release-weight: 30000
fix:
regex: ^fix[/-]
mode: ContinuousDelivery
tag: useBranchName
increment: Inherit
prevent-increment-of-merged-branch-version: false
track-merge-target: false
source-branches: [ 'dev', 'release', 'feature', 'fix' ]
tracks-release-branches: false
is-release-branch: false
is-mainline: false
pre-release-weight: 30000
I'm self-taught/totally new to Jekyll and Github Pages and was wondering how to go about opening a URL in a new tab with markdown in the config.yml page.
This is the website theme I'm using. I want the last 'github' link to open in a new tab, instead of the default, which is opening in the current tab.
The _config.yml looks like this:
# # # # # # # # # # # # #
# K i k o - p l u s #
# # # # # # # # # # # # #
# Basic
name: "Kiko Plus"
author:
facebook: your-id
youtubeUser: your-id
youtubeChannel: your-id
twitter: your-id
github: your-id
stackoverflow: your-id
quora: your-id
linkedin: your-id
pinterest: your-id
googlePlus: your-id
instagram: your-id
reddit: your-id
medium: your-id
tumblr: your-id
email: your-id#your-email.com
copyright:
year: 2017
name: Kiko
# Google-analytics
google-analytics:
id: ""
# Disqus
disqus:
id: "kiko-plus"
# URL
url: "https://AWEEKJ.github.io" # the base
hostname & protocol for your site
# url: "http://localhost:4000" # use this url when
you develop
baseurl: "/Kiko-plus" # the subpath of your site
# http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
timezone: Asia/Seoul
permalink: /:year-:month-:day/:title/
# Pagination
paginate: 5
paginate_path: /page:num/
# Markdown
markdown: kramdown
kramdown:
input: GFM
# Navigation
nav:
- name: "About"
url: "/about"
- name: "Archive"
url: "/archive"
- name: "Tags"
url: "/tags"
- name: "Github"
url: "https://github.com/AWEEKJ/Kiko-plus"
# Sass
sass:
sass_dir: _sass
style: :compressed
# Scopes
defaults:
-
scope:
path: ""
type: "pages"
values:
layout: "page"
-
scope:
path: ""
type: "posts"
values:
layout: "post"
# jekyll-seo-tag,
gems:
- jekyll-seo-tag
- jekyll-paginate
- jekyll-admin
exclude: [vendor]
To do this in any basic markdown post, naturally you'd do
[a link](http://example.com){:target="_blank"}
But since this link is in the site setup, that doesn't work. I've searched a ton and tried 5 or 6 different recommendations but to no avail.
Any ideas? Would be uber appreciated!!!!
You need to add target="_blank" to index.html line 12 as follow:
{{ nav.name }}
I found a plugin that automatically sets any external URL to open in a new tab:
https://rubygems.org/gems/jekyll-target-blank
Add the following to your site's Gemfile
gem 'jekyll-target-blank'
and add the following to your site's
_config.yml
plugins:
- jekyll-target-blank
You may also need to run bundle install to install the new Gem
{:target="_blank"} works for me:
[text](http://url){:target="_blank"}
I am setting up symfony 3 apache 2.4 and mysql environment for API development... I have just started and the index.html.twig page appears like this:
and my response header looks json format instead of html
my config.yml has FOSRest Configuration as:
# FOSRest Configuration
fos_rest:
body_listener: true
format_listener:
rules:
- { path: '^/', priorities: ['json'], fallback_format: json, prefer_extension: false }
param_fetcher_listener: true
view:
view_response_listener: 'force'
formats:
json: true
# Nelmio CORS Configuration
nelmio_cors:
defaults:
allow_credentials: false
allow_origin: ['*']
allow_headers: ['*']
allow_methods: ['GET', 'POST', 'PUT', 'DELETE', 'OPTIONS']
max_age: 3600
hosts: []
origin_regex: false
my question: how can I make my page rendered as html ?
In your FOSRest configuration, you tell him to handle the response when the URL match ^/ which is every URLs.
If you want to use FOSRest formatting for everything but the main page, you can configure it as follow :
fos_rest:
# ...
format_listener:
rules:
- { path: '^/.+', priorities: ['json'], fallback_format: json, prefer_extension: false }
- { path: '^/', stop: true }
How can I pull a default scope/value from my Jekyll _config.yml file into my default layout?
Here is part of the _config.yml
# default settings
defaults:
-
scope:
path: "" # an empty string here means all files in the project
type: posts
values:
author: ME
layout: post
class: article
I want to print something simple like {{ site.defaults.scope.type }}
You can simply get the value class by using page.class in a page that conforms to the path and type specified. For example:
config.yml
defaults:
-
scope:
path: ""
type: posts
values:
class: a post
-
scope:
path: ""
type: not_posts
values:
class: not a post
_posts/****-**-**-post.html
---
layout: post
---
{{ page.class }}
Output
a post
We have a pretty basic Jekyll site, lots of posts all divided up into categories. We're using the generate categories plugin.
Our categories were accessible at http://fake.com/categories/cat_index
After upgrading from 0.12.1 to 1.0.0, all of the category posts now have a url of http://fake.com/categories/cat_index/categories/cat_index
The only big thing I know changes between versions was the addition of the baseUrl being exposed to the liquid templates, but I can't figure out how that would have affected the post generation.
Searching this site and the rest of the internet I haven't been able to find anyone else having a similar error. I tried using a different category plugin, but had the same error.
A stripped version of the _congig.yml (just took out actual category/post names to maintain client anonymity)
exclude: [Gemfile, Gemfile.lock, Procfile]
safe: false
permalink: /:title
pygments: false
source: .
destination: ./_site
plugins: ./_plugins
relative_permalinks: false
primary_nav:
- label: 'Home'
href: ''
secondary_nav:
# - label: 'Example 1'
# href: link1.html
# - label: 'Example 2'
# href: link2.html
sections:
- key: 'fake'
label: 'Fake'
children:
- key: 'post-title'
label: 'Post Title'
- key: 'fake2'
label: 'Fake2'
children:
- key: 'post-title2'
label: 'Post Title2'
# configs for unwrapped.rb plugin
unwrapped_dest_directory: 'unwrapped'
unwrapped_template_path: '_includes/styleguide'
unwrapped_template_file: 'unwrapped.html'