Jekyll not generating files from deeply nested folder - jekyll

I am trying to generate a site that contains javadoc.
The structure looks like this:
|
|--com
| |--myproduct
| |--mypackage
| |--notgenerated.html
|--index.html
In the _site folder I get only
|
|--index.html
When I add a dummy file in the com directory
|
|--com
| |--myproduct
| | |--mypackage
| | |--notgenerated.html
| |--generated.html
|--index.html
The _site folder now looks like this
|
|--com
| |--generated.html
|--index.html
How can I get Jekyll to copy these deeply nested files to the _site directory without having to place dummy files in the intermediate directories?
I am using Ruby 1.9.1 with Jekyll 0.11.2 on Win7-x64.

The kind souls at Github support found the cause.
It turns out that I had a mistake in _config.yml.
I used
exclude: dir1, dir2, file1
instead of
exclude: [dir1, dir2, file1]
And this caused the site generation to fail. Silently.

Related

href to PDF stored on GitHub repository

I'm building a personal page with GitHub Pages and I would like to have a link that displays some PDF files on browser.
The PDF files are on a private repository with the following structure:
PDF-Repository
|__ Folder1
| |__ file11.notpdf
| |__ file12.pdf
|__ Folder2
| |__ file21.notpdf
| |__ file22.pdf
I couldn't use href to link to the repository files directly because it's private.
Neither I can copy the PDF files on the GH Pages repository manually since the PDF-Repository (and PDF files therein) gets updated regularly.
Is there a way I can include those files on the GH Pages repository so that , every time the PDF-Repository gets updated, there is an updated version on the GH Pages repository?

Changing Jekyll's source directory and keeping other directorys there they are

I would like to change Jekyll's source directory but in the same moment I would like to keep the other relevant directorys like _includes at the same place.
To achive this I set source in _config.yml to _source. This works but it seems that all other configuration values like includes_dir are always relative to source.
How can I configure includes_dir and all the other values independently of source?
My desired directory structure looks like this:
+- _source
+- _includes
+- _posts
+- ...
\ _config.yml
Jekyll expects all directorys below the source directory.
I found that out by looking into Jekyll's source code. The class Site contains several methods dealing with the configured directorys. All of them use the method in_source_dir to determine the effective path.
The method configure_include_paths is a good example for this.
def configure_include_paths
#includes_load_paths = Array(in_source_dir(config["includes_dir"].to_s))
#includes_load_paths << theme.includes_path if theme&.includes_path
end

Gulp+PUG: get all filenames in directory, tranform and inject them in another file

I have a PUG filestructure that looks something like this:
.
├── _modules
| ├── _footer
| | └── footer.pug
| └── _header
| | └── header.pug
| └── includes.pug
├── _layouts
| ├── default.pug
| └── post.pug
└── index.pug
The main idea is that I want to write a watch task for this, that will get all the filenames in _modules subdirectories and write them into includes.pug file so it would look something like this:
include _footer/footer
include _header/header
I've found some gulp packages that could get the filenames and store them in some variables (array), but I don't know, how to transform them to a string and to inject them into another file (well, I can do foreach of array with filenames and then get a string like 'include '+ filename, but the main problem is that I can't find a package that could insert that strings in a file while I'm doing foreach). Any suggestions how can I do this?
I would appreciate any help. Thank you.

PowerShell- Create html link (href) for each pdf from a directory (folder) of .pdf files

I am somewhat new to PowerShell and I have been asked to use PowerShell to add a list (folder) of pdf files to a webpage. I have searched the web over and haven’t had any luck. There has been a few forums and articles that come close but nothing so far that would really help with this specific task.
Purpose: I have separated my html into sections; top, working, bottom. I created a PowerShell script that takes the 3 separate .html files and combines them into one. The goal behind this is to pack the working html file with the all of the pdf files from one folder. The pdf folder is being updated on a daily basis and the script will run on the same timeline.
Normally I would post the code I have but so far it has been miss directed and would probably only make onlookers scratch their head. I do have a feeling I am supposed to use one of these too;
Select-Object FileName,#{name="Link"; expression={"Link"}} | Out-File C:\
Or
#{Label="Link";Expression={"<a href='$($_.Value)'>$($_.Name)</a>"}}
The problem is that I don’t know how to properly use either of these two.
Just pumping it out into an .html file won’t help me make usable links.
[System.IO.Directory]::EnumerateFiles('C:\Users\sample\GPDF','*.PDF')| Out-File C:\sample.html
Your question is not very clear but here is what might be helpful.
First get the list of pdf files in folder_name directory. Create a expression from the results.
Get-ChildItem "C:\Folder_Name\" | Where-Object {$_.Extension -eq ".pdf"} | Select-Object #{name="Link"; expression={"a href='$($_.FullName)'>$($_.Name)</a>"}} | Out-File C:\FileName.html
Results
Link
----
a href='C:\Folder_Name\1.pdf'>1.pdf</a>
a href='C:\Folder_Name\2.pdf'>2.pdf</a>
I am also new to powershell so any feedback to improve this script will be appreciated. Is this what you are looking for?
Just to tweak NepCoder's answer a bit:
Get-ChildItem "C:\Folder_Name\" | Where-Object {$_.Extension -eq ".pdf"} |
Select-Object #{name="Link"; expression={"<a href='http://mypath/$($_.Name)'>$($_.Name)</a><br/>"}} | Out-File C:\FileName.html

Jekyll: Using multiple .md files per directory and have them available as files, not sub-directories?

I am looking for a way to have multiple markdown files (.md) in a directory and have them available as files (not sub-directories).
Example:
├── about/
| └── index.md
| └── history.md
| └── vision.md
I want these to become urls like this (treated as files (no trailing slash))
base.url/about/
base.url/about/history
base.url/about/vision
instead of (directories (trailing slash)):
base.url/about/
base.url/about/history/
base.url/about/vision/
How can I achieve that?
You can do this with Jekyll 3.x using permalinks in your files front matter. But, if you want to use this with Jekyll 2.4+ and Github pages, it seems that there is a problem.
Permalinks with trailing slash are the way to go for now.