aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
11 daysRelease ciigo v0.17.0 (2026-04-04)HEADv0.17.0mainShulhan
**🌱 cmd/ciigo: add option to set base path and shutdown idle duration** The `-base-path` option set the URL prefix for serving HTTP request. This allow serving the content under the prefix other than "/". The `-shutdown-idle` option set the duration when server will stop accepting new connections and shutting down. This option can be helpful to reduce the resources on local environment. **🌼 all: make the anchor symbol position on the right side of headers** Previously, when `:sectanchors:` is set, the default anchor symbol position is absolute on the left side of heading text with block display option (the symbol located outside of box area of headers). In special case, this cause an overflow when the generated HTML are rendered inside flex with fixed height (the body is scrollable with empty content on bottom). This module changes the anchor symbol position to the right side of heading text to prevent scroll on such layout, without absolute position and normal inline layout.
11 daysgo.mod: update all dependenciesShulhan
This set the minimum Go version to 1.26.0.
11 days_static: remove the flex-direction in headingsShulhan
The fix for anchor position has been updated in asciidoctor-go, so lets remove the quick fix in here.
2026-03-26all: make the anchor symbol position on the right side of headersShulhan
Previously, when `:sectanchors:` is set, the default anchor symbol position is absolute on the left side of heading text with block display option (the symbol located outside of box area of headers). In special case, this cause an overflow when the generated HTML are rendered inside flex with fixed height (the body is scrollable with empty content on bottom). This module changes the anchor symbol position to the right side of heading text to prevent scroll on such layout, without absolute position and normal inline layout.
2026-02-11cmd/ciigo: add option to set base path and shutdown idle durationShulhan
The `-base-path` option set the URL prefix for serving HTTP request. This allow serving the content under the prefix other than "/". The `-shutdown-idle` option set the duration when server will stop accepting new connections and shutting down. This option can be helpful to reduce the resources on local environment.
2026-02-09Release ciigo v0.16.0 (2026-02-09)v0.16.0Shulhan
**🌱 all: embed CSS and index HTML template using memfs** Previously, with direct embed, every time we change the CSS or index template, we need to restart the "ciigo serve" command. Using memfs make us easy to update and see the changes directly, without restarting the server. **🌼 all: improve the default stylesheet and template** Add common styles for asciidoctor elements with dark theme. Common styles including title, header, anchor, lists, table, and footer. The foreground color changes to conform with color-contrast ratio threshold, with score AAA. [1] Add ARIA role to each section of pages: banner for topbar, main for page, and contentinfo for footer. This is to make the webpage more robust and functional no matter what screen reader technology is used. [2] For touch devices, increase the line height on Table of Contents. This is to help users who may have difficulty in confidently targeting or operating small controls. [3] In the default template, instead of splitting the topbar into top-heading and menu, breaking it down by class item. [1]: https://dequeuniversity.com/rules/axe/4.11/color-contrast + [2]: https://dequeuniversity.com/rules/axe/4.11/landmark-one-main + [3]: https://dequeuniversity.com/rules/axe/4.11/target-size **🌱 all: allow combination of default and custom stylesheet** To combine default stylesheet with custom CSS, set the value to "default" and the file name of custom CSS, separated by comma. This is the recommended way to use custom stylesheet since it can be set only on specific pages. ---- // In asciidoctor: :stylesheet: default, custom.css // In markdown: stylesheet: default, custom.css ---- To disable default stylesheet and only using custom CSS, set the value only to the file name of custom CSS. Another way to use custom stylesheet is by creating your own template and pass it to `serve` or `convert` command. This method makes the stylesheet applied to all pages. **🌼 all: add field Listener to ServeOptions** The field Listener allow passing [net.Listener] instance for accepting HTTP connection. One of the use case is to activate the ciigo serve using systemd.socket(5). **🌱 all: redirect request for .adoc or .md to the HTML file** During serve, onGet method, if the node does not exist and the request path end with .adoc or .md, redirect the client to the .html location with status 303 (See Other). **🪵 all: embed struct [lib/http.ServerOptions] directly to [ServeOptions]** At this point, all of the fields in the struct ServeOptions is the same with [lib/http.ServerOptions] except IsDevelopment and ConvertOptions. For field IsDevelopment we keep in the struct. For field ConvertOptions we remove it and let the caller pass it on Serve function or InitHTTPServer method.
2026-02-09go.mod: update all dependenciesShulhan
This update affect the test on onGet, where request to directory that does not end with slash will be redirected with status code 301 (Moved Permanently) instead of 302 (Found).
2026-02-07all: embed struct [lib/http.ServerOptions] directly to [ServeOptions]Shulhan
At this point, all of the fields in the struct ServeOptions is the same with [lib/http.ServerOptions] except IsDevelopment and ConvertOptions. For field IsDevelopment we keep in the struct. For field ConvertOptions we remove it and let the caller pass it on Serve function or InitHTTPServer method.
2026-02-05server: enable ServerOptions HandleFS by defaultShulhan
This allow request for .adoc/.md get redirected to .html in production environment, as we have in https://golang-id.org/proposal/ .
2026-02-05all: redirect request for .adoc or .md to the HTML fileShulhan
During serve, onGet method, if the node does not exist and the request path end with .adoc or .md, redirect the client to the .html location with status 303 (StatusSeeOther).
2026-02-04_static: update the default styleShulhan
Changes, * Set the anchor text-decoration back to none but with hover set to underline * Set only h2 to have border bottom * Increase top margin for headings * Set the topbar layout using flex and remove margin and padding for form elements * Change the sectanchor indicator to display on hover. Minimize unncessary text displayed on screen. * Add style for block quotes
2026-02-02all: add field Listener to ServeOptionsShulhan
The field Listener allow passing [net.Listener] instance for accepting HTTP connection. One of the use case is to activate the ciigo serve using systemd.socket(5).
2026-02-02all: allow combination of default and custom stylesheetShulhan
To combine default stylesheet with custom CSS, set the value to "default" and the file name of custom CSS, separated by comma. This is the recommended way to use custom stylesheet since it can be set only on specific pages. ---- // In asciidoctor: :stylesheet: default, custom.css // In markdown: stylesheet: default, custom.css ---- To disable default stylesheet and only using custom CSS, set the value only to the file name of custom CSS. Another way to use custom stylesheet is by creating your own template and pass it to `serve` or `convert` command. This method makes the stylesheet applied to all pages.
2026-01-29_doc: add the test content for markdownShulhan
The content is the same with adoc one, with style updated to use basic and [extended] syntax. Many syntax are not worked, like tables and admonition. [extended]: https://www.markdownguide.org/extended-syntax/
2026-01-29_static: improve styling on header and table of contentsShulhan
In the header, we made the authors, version, date, remark to be italic. In the ToC, we show the "Table of Contents" title back, re-align it to match with the top and bottom elements.
2026-01-28_static: fix pre style on HTML generated by markdownShulhan
While at it, add padding bottom to the #footnotes in HTML generated by asciidoctor-go.
2026-01-26_static: fix page rendering on markdownShulhan
On HTML output of markdown, there is no .container #header and #content so the page content will not get centered (using margin). To fix this, we set the margin auto on .container class and use the default background on #footer.
2026-01-24all: fix test on GoEmbedShulhan
Seems like we use "find ... -delete" for a reason that I forgot. It should not be like that, we will fix it later.
2026-01-24go.mod: update asciidoctor-go moduleShulhan
Changes, * all: add aria-label to the anchor when sectanchor enabled * all: update default CSS to asciidoctor v2.0.26 * all: use separate file with go:embed for default CSS * all: reformat README with prettier and simplify license
2026-01-24all: conform with Lighthouse recommendationsShulhan
The foreground color changes to conform with color-contrast ratio threshold, with score AAA. [1] Add ARIA role to each section of pages: banner for topbar, main for page, and contentinfo for footer. This is to make the webpage more robust and functional no matter what screen reader technology is used. [2] For touch devices, increase the line height on Table of Contents. This is to help users who may have difficulty in confidently targeting or operating small controls. [3] [1]: https://dequeuniversity.com/rules/axe/4.11/color-contrast [2]: https://dequeuniversity.com/rules/axe/4.11/landmark-one-main [3]: https://dequeuniversity.com/rules/axe/4.11/target-size
2026-01-24_static: second round for cleaning up stylesShulhan
* Reordering the styles based on the HTML layout. * Changes the background color for verbatim and source code * Add background color to footer * Set the topbar and footer width to full
2026-01-24_static: simplify the topbar sectionShulhan
Instead of splitting the topbar into top-heading and menu, breaking it down by class item.
2026-01-24all: improve default stylesheetShulhan
Add common styles for asciidoctor elements with dark theme. Common styles including title, header, anchor, lists, table, and footer.
2026-01-24all: move _example/ directory under _doc/ directoryShulhan
This allow us to inspect the example using the serve-doc task, along with the content of _doc/.
2026-01-24all: embed CSS and index HTML template using memfsShulhan
Previously, with direct embed, every time we change the CSS or index template, we need to restart the "ciigo serve" command. Using memfs make us easy to update and see the changes directly, without restarting the server.
2026-01-23all: format README with prettierShulhan
While at it, simplify the license text to reference only the license name instead of snippet.
2026-01-16go.mod: update pakakeh.go to v0.60.3-0.20260115103415-806359d5462fShulhan
This update have changes on [lib/http.FSHandler] that return second parameter, status code.
2025-12-27Release ciigo v0.15.3 (2025-12-27)v0.15.3Shulhan
This is the last release for year 2025. In the README, we fix broken "Change log" link when rendered on pkg.go.dev and sr.ht sites. The go.mod has been updated to use minimum Go 1.24.0; and all dependencies has been updated to latest release. Happy holidays!
2025-12-27all: update missing licenses and copyright informationShulhan
2025-12-27go.mod: set minimum Go to 1.24.0 and update all dependenciesShulhan
2025-06-29go.mod: update all dependenciesShulhan
2025-06-29all: update README for pkg.go.dev and sr.htShulhan
The [Change log] link is broken when rendered on pkg.go.dev and sr.ht sites.
2025-04-18Release ciigo v0.15.2 (2025-04-18)v0.15.2Shulhan
This release update the core asciidoctor-go module that brings several new features. [NEW FEATURE] **Support include directive inside block code.** Example of block code with include directive, ---- ... include::file[] ... ---- [NEW FEATURE] **Support document attribute "docdir".** The "docdir" attribute contains the full path of the directory that contains the source document. By default it is set to the directory where the Document resided. [NEW FEATURE] **Add default HTML stylesheet**. The generated HTML now contains the default stylesheet. The stylesheet is copied from HTML file generated by Asciidoctor v2.0.23.
2025-04-18go.mod: update asciidoctor-go module to fix default embedded CSSShulhan
By default, the document contains ":stylesheet:" attribute, which means using the default embedded CSS. To disable it, unset the attribute using ":stylesheet!:". To overwrite it, set the attribute to path of CSS file ":stylesheet: my.css".
2025-04-18testdata: disable generating HTML meta "generator"Shulhan
The "generator" meta will changes when the asciidoctor-go release new version. This causes unnecessary chores on test data that needs to be updated on every new releases.
2025-04-18go.mod: update all dependenciesShulhan
2025-02-03server: fix log prefix on InitHTTPServer methodShulhan
2025-02-01Release ciigo v0.15.1 (2025-02-01)v0.15.1Shulhan
[BUG FIX] Fix section detected as paragraph after list and comment. Previously, given the following markup, ---- * Sub list + Sub list content. //}}} //{{{ == Sub 2 //}} ---- The section "Sub 2" will be parsed as paragraph instead of new section. [CHORE] In the linter, we replace the fieldalignment and shadow using our internal gocheck command. This linters actually have an API that can be combined into a program, which provided by package "pakakeh.go/lib/goanalysis".
2025-02-01make: derive GOBIN using "go env GOBIN"Shulhan
The environment variable GOBIN may not set by user explicitly.
2025-02-01all: replace external linters with internal linterShulhan
The fieldalignment and shadow is linter from golang.org/x/tools. This linters actually have an API that can be combined into a program, which provided by package "pakakeh.go/lib/goanalysis".
2025-02-01go.mod: update asciidoctor-goShulhan
The latest release fix parsing section that is not detected after list items.
2025-01-08Release ciigo v0.15.0 (2025-01-08)v0.15.0Shulhan
This is the first major release of ciigo on the new year of 2025. We bring many enhancements and update on the documentation. [ENHANCEMENT] The first changes is refactoring to use watchfs/v2. The [watchfs/v2] bring new enhancements by watching only single file instead of all markup files for changes. This minimize number of goroutine calling [os.Stat] on each markup files. [BUG FIX] When listing the file markups, if the node is symlink (either file or directory) and target its not exist, continue to the next node instead of returning error. The same is true for directory that cannot be opened, probably due to broken symlink or permission. [ENHANCEMENT] In development mode, where [ServeOptions.IsDevelopment] is set to true or when running "ciigo serve", the ciigo HTTP server will check if the new markup file is newer than HTML file when user press refresh or reload on the browser. If its newer, it will convert the markup file and return the new content of HTML file. This allow quick preview without waiting for watcher to complete. [ENHANCEMENT] The README has been revamped to include section on how to install ciigo as program, how to running ciigo convert and serve, how to write content and view it live on browser, and how to deploy it. On the section "ciigo as library" we point the user the sample code at "internal/cmd/ciigo-example" instead of writing long code at the front. [BUG FIX] This release also fix Exclude option does not get processed when calling GoEmbed, or running "ciigo embed".
2025-01-07all: update README simplify section "ciigo as library"Shulhan
Instead of writing the code manually, show the where to look for example, which is at "internal/cmd/ciigo-example".
2025-01-07all: fix GoEmbed that does not excludes options from ConvertOptionsShulhan
2025-01-07all: move example for ciigo as library to internal/cmd/ciigo-exampleShulhan
While at it, update the example index by removing unnecessary external image, and update links to open in new tab/window.
2025-01-07all: update README for running ciigo as CLIShulhan
In the README we add list of ciigo features, describe how to install ciigo, reformat the Usage, add an example of running ciigo convert and serve, how to write content and view it live on browser, and how to deploy it using rsync.
2025-01-07file_markup: convert extension to lowercase on markupKind onlyShulhan
Converting extension to lowercase before trimming it may not remove the extension itself since the string has changes.
2025-01-07all: change the "serve-doc" and default address to prevent conflictsShulhan
Using port 8080 as the default address for "serve" is too common and may conflict with other services in user local environment. While at it, also change the "serve-doc" with other random ports to allow us test running "ciigo serve" and viewing doc at the same time.
2025-01-07all: auto convert markup when HTTP client request GET to HTML fileShulhan
In development mode, where [ServeOptions.IsDevelopment] is set to true or when running "ciigo serve", the ciigo HTTP server will check if the new markup file is newer than HTML file when user press refresh or reload on the browser. If its newer, it will convert the markup file and return the new content of HTML file.
2025-01-07all: run task "test" after "lint" and "build"Shulhan
Task for "lint" and "build" is much more faster than "test". So if we lint or build failed, we did not waste too much times waiting for all tests to pass. While at it, remove linter "revive" we will use the standard linters from Go tools itself.