first commit
This commit is contained in:
parent
b05b315485
commit
5258eaa6ca
10 changed files with 134 additions and 0 deletions
3
.gitignore
vendored
Normal file
3
.gitignore
vendored
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
build
|
||||||
|
cache
|
||||||
|
public
|
10
LICENSE
Normal file
10
LICENSE
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
The text of and illustrations in this document are licensed by Red Hat
|
||||||
|
under a Creative Commons Attribution–Share Alike 3.0 Unported license
|
||||||
|
("CC-BY-SA"). An explanation of CC-BY-SA is available at
|
||||||
|
http://creativecommons.org/licenses/by-sa/3.0/. In accordance with
|
||||||
|
CC-BY-SA, if you distribute this document or an adaptation of it, you
|
||||||
|
must provide the URL for the original version.
|
||||||
|
|
||||||
|
Red Hat, as the licensor of this document, waives the right to
|
||||||
|
enforce, and agrees not to assert, Section 4d of CC-BY-SA to the
|
||||||
|
fullest extent permitted by applicable law.
|
16
antora.yml
Normal file
16
antora.yml
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
# Name will be mostly visible in the URL. Treat it as an indentifier.
|
||||||
|
# Tip: If you want to use the local preview scripts that come with this repository, please change this value in the site.yml file as well. (under site/start_page)
|
||||||
|
name: localization # <---- PLEASE MODIFY
|
||||||
|
|
||||||
|
# Title will be visible on the page.
|
||||||
|
title: Localization help and stats # <---- PLEASE MODIFY
|
||||||
|
|
||||||
|
# If you don't plan to have multiple versions of the docs (for example, to document multiple versions of some software), you can ignore this field. Otherwise, change "master" to a specific version.
|
||||||
|
version: master
|
||||||
|
|
||||||
|
# We encourage you to name the index page as "index.adoc". If you absolutely have to use a different name, please reflect it here. You can ignore this field otherwise.
|
||||||
|
start_page: ROOT:index
|
||||||
|
|
||||||
|
# This lists all the menu definitions of your component.
|
||||||
|
nav:
|
||||||
|
- modules/ROOT/nav.adoc
|
46
build.sh
Executable file
46
build.sh
Executable file
|
@ -0,0 +1,46 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
image="docker.io/antora/antora"
|
||||||
|
cmd="--html-url-extension-style=indexify site.yml"
|
||||||
|
|
||||||
|
if [ "$(uname)" == "Darwin" ]; then
|
||||||
|
# Running on macOS.
|
||||||
|
# Let's assume that the user has the Docker CE installed
|
||||||
|
# which doesn't require a root password.
|
||||||
|
echo ""
|
||||||
|
echo "This build script is using Docker container runtime to run the build in an isolated environment."
|
||||||
|
echo ""
|
||||||
|
docker run --rm -it -v $(pwd):/antora $image $cmd
|
||||||
|
|
||||||
|
elif [ "$(expr substr $(uname -s) 1 5)" == "Linux" ]; then
|
||||||
|
# Running on Linux.
|
||||||
|
# Check whether podman is available, else faill back to docker
|
||||||
|
# which requires root.
|
||||||
|
|
||||||
|
if [ -f /usr/bin/podman ]; then
|
||||||
|
echo ""
|
||||||
|
echo "This build script is using Podman to run the build in an isolated environment."
|
||||||
|
echo ""
|
||||||
|
podman run --rm -it -v $(pwd):/antora:z $image $cmd
|
||||||
|
|
||||||
|
elif [ -f /usr/bin/docker ]; then
|
||||||
|
echo ""
|
||||||
|
echo "This build script is using Docker to run the build in an isolated environment."
|
||||||
|
echo ""
|
||||||
|
|
||||||
|
if groups | grep -wq "docker"; then
|
||||||
|
docker run --rm -it -v $(pwd):/antora:z $image $cmd
|
||||||
|
else
|
||||||
|
echo ""
|
||||||
|
echo "This build script is using $runtime to run the build in an isolated environment. You might be asked for your password."
|
||||||
|
echo "You can avoid this by adding your user to the 'docker' group, but be aware of the security implications. See https://docs.docker.com/install/linux/linux-postinstall/."
|
||||||
|
echo ""
|
||||||
|
sudo docker run --rm -it -v $(pwd):/antora:z $image $cmd
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
echo ""
|
||||||
|
echo "Error: Container runtime haven't been found on your system. Fix it by:"
|
||||||
|
echo "$ sudo dnf install podman"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
fi
|
0
modules/ROOT/nav.adoc
Normal file
0
modules/ROOT/nav.adoc
Normal file
5
modules/ROOT/pages/index.adoc
Normal file
5
modules/ROOT/pages/index.adoc
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
= Stats
|
||||||
|
|
||||||
|
===
|
||||||
|
include::test.csv[]
|
||||||
|
===
|
2
modules/ROOT/pages/test.csv
Normal file
2
modules/ROOT/pages/test.csv
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
header one, header to
|
||||||
|
text 1, text 2
|
|
14
nginx.conf
Normal file
14
nginx.conf
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
server {
|
||||||
|
listen 80;
|
||||||
|
server_name localhost;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
root /antora/public;
|
||||||
|
index index.html index.htm;
|
||||||
|
}
|
||||||
|
|
||||||
|
error_page 500 502 503 504 /50x.html;
|
||||||
|
location = /50x.html {
|
||||||
|
root /usr/share/nginx/html;
|
||||||
|
}
|
||||||
|
}
|
18
preview.sh
Executable file
18
preview.sh
Executable file
|
@ -0,0 +1,18 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
if [ "$(uname)" == "Darwin" ]; then
|
||||||
|
# Running on macOS.
|
||||||
|
# Let's assume that the user has the Docker CE installed
|
||||||
|
# which doesn't require a root password.
|
||||||
|
echo "The preview will be available at http://localhost:8080/"
|
||||||
|
docker run --rm -v $(pwd):/antora:ro -v $(pwd)/nginx.conf:/etc/nginx/conf.d/default.conf:ro -p 8080:80 nginx
|
||||||
|
|
||||||
|
elif [ "$(expr substr $(uname -s) 1 5)" == "Linux" ]; then
|
||||||
|
# Running on Linux.
|
||||||
|
# Fedora Workstation has python3 installed as a default, so using that
|
||||||
|
echo ""
|
||||||
|
echo "The preview is available at http://localhost:8080"
|
||||||
|
echo ""
|
||||||
|
cd ./public
|
||||||
|
python3 -m http.server 8080
|
||||||
|
fi
|
20
site.yml
Normal file
20
site.yml
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
site:
|
||||||
|
title: Local Preview
|
||||||
|
start_page: localization::index
|
||||||
|
content:
|
||||||
|
sources:
|
||||||
|
- url: .
|
||||||
|
branches: HEAD
|
||||||
|
ui:
|
||||||
|
bundle:
|
||||||
|
url: https://asamalik.fedorapeople.org/ui-bundle.zip
|
||||||
|
snapshot: true
|
||||||
|
default_layout: with_menu
|
||||||
|
output:
|
||||||
|
clean: true
|
||||||
|
dir: ./public
|
||||||
|
destinations:
|
||||||
|
- provider: archive
|
||||||
|
runtime:
|
||||||
|
pull: true
|
||||||
|
cache_dir: ./cache
|
Loading…
Add table
Add a link
Reference in a new issue