Commit graph

314 commits

Author SHA1 Message Date
Bjørn Erik Pedersen 8aec5ee2dd hugolib: Some more unexports 2016-03-25 03:12:31 +01:00
Bjørn Erik Pedersen fa1a9653e5 hugolib: Taxonomy GoDoc cleanup 2016-03-24 16:01:25 +01:00
Bjørn Erik Pedersen faf2e50685 Do some minor code cleaning of Site
* Unexport some methods/fields
* Add some godoc

Still plenty to do here.
2016-03-23 09:43:04 +01:00
Bjørn Erik Pedersen dc7d8a9eac Spring cleaning of the menu code 2016-03-23 00:29:39 +01:00
Bjørn Erik Pedersen de8fc8761a Re-render shortcode on template or data file change
Fixes  #1971
2016-03-21 21:09:25 -04:00
Bjørn Erik Pedersen 3529152efe Return early from appendThemeTemplates 2016-03-17 23:36:11 +01:00
Bjørn Erik Pedersen 70739c972e Remove unnecessary type conversions 2016-03-14 20:35:50 +01:00
Bjørn Erik Pedersen dea185aa9b hugolib: Remove unused code 2016-03-14 15:41:03 +01:00
Ján Koščo be3519fac0 Use default sitemap configuration for homepage
Fixes #1304
2016-03-10 11:02:00 +01:00
Bjørn Erik Pedersen 973393c99e Create template clone for late template execution
Fixing some breaking blogs on Go 1.6

Fixes #1879
2016-03-09 14:37:58 +01:00
Bjørn Erik Pedersen c7acc318b5 Add some missing resets on rebuild
Fixes #1928
Fixes #1929
2016-03-06 16:33:32 +01:00
Bjørn Erik Pedersen 023992abad Unexport the target handlers
These are of no interest outside the package.
2016-03-05 20:56:38 +01:00
Bjørn Erik Pedersen 27f8d8f963 Allow URL with extension in frontmatter
Fixes #1923
2016-03-05 20:50:53 +01:00
Bjørn Erik Pedersen ccd2f4c32b Prevent capitalized taxonomy labels
Fixes #1880
2016-03-03 21:54:23 +01:00
Bjørn Erik Pedersen 6b922750f3 Revert "Create template clone for late template execution"
This reverts commit 93b04e67f6.
2016-02-28 12:15:33 +01:00
Bjørn Erik Pedersen 93b04e67f6 Create template clone for late template execution
Fixing some breaking blogs on Go 1.6

Fixes #1879
2016-02-28 11:51:51 +01:00
Bjørn Erik Pedersen 804603155f Check for the presence of pages before setting dates
See #1903
2016-02-27 23:25:41 +01:00
Bjørn Erik Pedersen 75cf324322 Set Date and Lastmod for main home page
Fixes #1903
2016-02-27 23:21:07 +01:00
Tatsushi Demachi e9853642e5 Listen channel before sending values to it
The 'results' channel is not listend before sending error values in a
loop checking IsRenderable or not. This fixes it.
2016-02-20 14:03:06 +09:00
Bjørn Erik Pedersen 50182cd06b Remove superfluous Errorf 2016-02-16 02:05:59 +01:00
Derek Perkins bac1ba4655 Fix spelling and go vet errors 2016-02-13 19:08:48 +08:00
Tatsushi Demachi 68e2e63d92 Fix Hugo hang up with empty content directory
Site.ReadPagesFromSource returns nil chan error value when a site
content directory is empty but its receiver expects to be passed
something error values via the channel.

This fixes it by returning a channel which will be immediately closed.

Fix #1797
2016-02-03 08:19:02 +09:00
Anthony Fok 57eebbf243 Use FEEDBACK instead of ERROR for empty home page warning
jww.ERROR.Println() seems to have become too verbose,
making the warning message intended for new users
a lot less readable.
2016-01-30 17:39:17 +08:00
Bjørn Erik Pedersen 5def6d9aee Make the watch logger less chatty 2016-01-28 15:33:41 +01:00
Steve Francia 9413cf8499 Handle self rename operations gracefully 2016-01-26 14:33:08 -05:00
Steve Francia 7e196a8294 Handle remove & rename source operations incrementally 2016-01-26 14:30:28 -05:00
Steve Francia e01c340915 A single file can be replaced in site.Files 2016-01-26 14:29:37 -05:00
Steve Francia 45e5091428 Process only the source content that has changed 2016-01-26 14:28:53 -05:00
Steve Francia 9f3796a31d Read/reread individual source content files
next is incremental conversion
2016-01-26 14:26:23 -05:00
Steve Francia ca6ca4f4fc Separate handling content, data and template changes
Data & Templates reading independently
Need to work on page source reading and other source files
2016-01-26 14:25:39 -05:00
Steve Francia bcc42c0549 Separate reading source and processing source operations 2016-01-25 14:41:47 -05:00
Bjørn Erik Pedersen 3526afc773 Fix some Go vet errors 2016-01-16 00:28:48 +01:00
Ivan Fraixedes 9a6dc6c791 Add embeded template for robots.txt 2016-01-05 23:36:16 +01:00
Daniel Martí 7c5a1fd16b Replace *bytes.Buffer with io.Writer in rendering
Found via github.com/mvdan/interfacer.
2016-01-05 23:32:03 +01:00
Alexandre Bourget dcad066025 Small refactor: don't call p.Permalink() for all aliases, call it only
once and only if necessary.
2016-01-04 12:41:06 -05:00
Gerben Castel 6cdb8109cf Allow renaming of sitemap.xml 2016-01-04 12:28:49 -05:00
Sven Dowideit 0f6b334b67 Source file based relative linking
ala GitHub repository markdown for both md files and non-md files

Signed-off-by: Sven Dowideit <SvenDowideit@home.org.au>
2016-01-01 15:23:11 -05:00
digitalcraftsman 47587321d9 Add themesDir option to configuration
themesDir can be used to change the default
path of the themes folder.

Fixes 1556
2016-01-01 14:46:40 -05:00
Bjørn Erik Pedersen 8cea428802 Fix data race in non-renderable pages
Fixes #1601
2015-12-18 11:24:35 +01:00
Bjørn Erik Pedersen e445c35d6a Fix copyright headers in source files
Still need to add some missing headers and an AUTHORS file.

See #1646
2015-12-07 19:57:01 +01:00
Anthony Fok f13db9328b Sort and remove "" from "Available templates" list 2015-12-06 23:23:54 -07:00
gunnaraasen d35d82060f Remove transformation of menu URLs
Fixes #1239
2015-12-06 15:25:23 +01:00
Bjørn Erik Pedersen 3f0f7eed68 Improve error handling in commands
Cobra, the CLI commander in use in Hugo, has some long awaited improvements in the error handling department.
This enables a more centralized error handling approach.

This commit introduces that by changing all the command funcs to `RunE`:

* The core part of the error logging, usage logging and `os.Exit(-1)` is now performed in one place and that one place only.
* The usage text is now only shown on invalid arguments etc. (user errors)

Fixes #1502
2015-12-02 07:07:05 -07:00
Anthony Fok 0d1d33d7f3 Print error when /index.html is zero-length
Also print warning (in verbose mode) for other empty pages.

See #947
2015-12-01 21:03:17 -07:00
Anthony Fok f8302768c7 Run go fmt hugolib/site.go 2015-12-01 21:01:19 -07:00
Steve Francia f045d7a611 Change the license to Apache 2.0 2015-11-23 22:16:36 -05:00
Kato Kazuyoshi 99acbb2eb2 Permalink on Node and Page should be of string
This change fixes #1384.
2015-11-23 17:41:29 +01:00
Cameron Moore 3abb2675c5 Add RSSLink to SiteInfo 2015-11-20 23:38:15 +01:00
spf13 5c1204c24b simplify rssuri logic 2015-11-15 11:05:16 -05:00
digitalcraftsman 9dbb6dc50d Add internal Google Analytics template
This commits also adds the GoogleAnalytics
variable to insert the tracking code.

Fixes #1424.
2015-11-04 17:11:38 -05:00