Skip to content

Commit 08e2b95

Browse files
Basic Setup
0 parents  commit 08e2b95

File tree

7 files changed

+397
-0
lines changed

7 files changed

+397
-0
lines changed

.github/workflows/production.yml

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
# This is a basic workflow to help you get started with Actions
2+
3+
name: reference.aspose.com(tutorials-html)(family)(Production)
4+
5+
# Controls when the action will run.
6+
on:
7+
# Triggers the workflow on push or pull request events but only for the master branch
8+
push:
9+
branches: [ main ]
10+
paths:
11+
- 'content/**'
12+
pull_request:
13+
branches: [ main ]
14+
paths:
15+
- 'content/**'
16+
17+
# Allows you to run this workflow manually from the Actions tab
18+
workflow_dispatch:
19+
20+
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
21+
jobs:
22+
# This workflow contains a single job called "build"
23+
build:
24+
# The type of runner that the job will run on
25+
runs-on: macos-latest
26+
27+
# Steps represent a sequence of tasks that will be executed as part of the job
28+
steps:
29+
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
30+
- name: Checkout
31+
uses: actions/checkout@v2
32+
with:
33+
submodules: true # Fetch Hugo themes
34+
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
35+
- name: Checkout theme repo
36+
uses: actions/checkout@main
37+
with:
38+
repository: Aspose/api-theme
39+
token: ${{ secrets.REPO_TOKEN }}
40+
fetch-depth: 0
41+
path: themes/api-theme
42+
# Step 2 - Sets up the latest version of Hugo
43+
- name: Setup Hugo
44+
uses: peaceiris/actions-hugo@v2
45+
with:
46+
hugo-version: '0.97.3'
47+
extended: true
48+
- name: Install Dependicies1
49+
run: npm install -D --save autoprefixer
50+
- name: Install Dependicies2
51+
run: npm install -D --save postcss-cli
52+
# Also specifies the theme we want to use
53+
- name: Build
54+
run: hugo --configDir config/html --environment production --minify
55+
56+
- name: Deploy apireference2.aspose.com(tutorials-html)(family)(Production) to S3
57+
run: hugo --configDir config/html --environment production deploy --target "Production" --maxDeletes 0
58+
env:
59+
AWS_ACCESS_KEY_ID: ${{ secrets.ACCESS_KEY }}
60+
AWS_SECRET_ACCESS_KEY: ${{ secrets.SECRET_ACCESS }}
61+
# Invalidate Cloudfront
62+
- name: invalidate
63+
uses: chetan/invalidate-cloudfront-action@v2
64+
env:
65+
DISTRIBUTION: ${{ secrets.AWS_DISTRIBUTION_PROD }}
66+
PATHS: /tutorials/html/*
67+
AWS_REGION: 'us-west-2'
68+
AWS_ACCESS_KEY_ID: ${{ secrets.ACCESS_KEY }}
69+
AWS_SECRET_ACCESS_KEY: ${{ secrets.SECRET_ACCESS }}

.github/workflows/staging.yml

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
# This is a basic workflow to help you get started with Actions
2+
3+
name: reference2.aspose.com(tutorials-html)(family)(Stage)
4+
5+
# Controls when the action will run.
6+
on:
7+
# Triggers the workflow on push or pull request events but only for the master branch
8+
push:
9+
branches: [ staging ]
10+
paths:
11+
- 'content/**'
12+
pull_request:
13+
branches: [ staging ]
14+
paths:
15+
- 'content/**'
16+
17+
# Allows you to run this workflow manually from the Actions tab
18+
workflow_dispatch:
19+
20+
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
21+
jobs:
22+
# This workflow contains a single job called "build"
23+
build:
24+
# The type of runner that the job will run on
25+
runs-on: macos-latest
26+
27+
# Steps represent a sequence of tasks that will be executed as part of the job
28+
steps:
29+
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
30+
- name: Checkout
31+
uses: actions/checkout@v2
32+
with:
33+
submodules: true # Fetch Hugo themes
34+
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
35+
- name: Checkout theme repo
36+
uses: actions/checkout@main
37+
with:
38+
repository: Aspose/api-theme
39+
token: ${{ secrets.REPO_TOKEN }}
40+
ref: beta
41+
fetch-depth: 0
42+
path: themes/api-theme
43+
# Step 2 - Sets up the latest version of Hugo
44+
- name: Setup Hugo
45+
uses: peaceiris/actions-hugo@v2
46+
with:
47+
hugo-version: '0.97.3'
48+
extended: true
49+
- name: Install Dependicies1
50+
run: npm install -D --save autoprefixer
51+
- name: Install Dependicies2
52+
run: npm install -D --save postcss-cli
53+
# Also specifies the theme we want to use
54+
- name: Build
55+
run: hugo --configDir config/html --environment staging --minify
56+
57+
- name: Deploy apireference2.aspose.com(tutorials-html)(family)(Stage) to S3
58+
run: hugo --configDir config/html --environment staging deploy --target "Stage" --maxDeletes 0
59+
env:
60+
AWS_ACCESS_KEY_ID: ${{ secrets.ACCESS_KEY }}
61+
AWS_SECRET_ACCESS_KEY: ${{ secrets.SECRET_ACCESS }}
62+
# Invalidate Cloudfront
63+
- name: invalidate
64+
uses: chetan/invalidate-cloudfront-action@v2
65+
env:
66+
DISTRIBUTION: ${{ secrets.AWS_DISTRIBUTION }}
67+
PATHS: /tutorials/html/*
68+
AWS_REGION: 'us-west-2'
69+
AWS_ACCESS_KEY_ID: ${{ secrets.ACCESS_KEY }}
70+
AWS_SECRET_ACCESS_KEY: ${{ secrets.SECRET_ACCESS }}

config/html/_default/config.toml

Lines changed: 213 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,213 @@
1+
baseURL = "/tutorials/html"
2+
title = "Aspose API References"
3+
staticdir = 'content/static'
4+
enableRobotsTXT = true
5+
enableGitInfo = true
6+
disableKinds = ["taxonomy", "taxonomyTerm", "page", "RSS"]
7+
8+
# Hugo allows theme composition (and inheritance). The precedence is from left to right.
9+
theme = ["api-theme"]
10+
11+
[params.menu]
12+
zh = "aspose-zh"
13+
ru = "aspose-ru"
14+
ar = "aspose-ar"
15+
cs = "aspose-cs"
16+
de = "aspose-de"
17+
el = "aspose-el"
18+
es = "aspose-es"
19+
fr = "aspose-fr"
20+
hi = "aspose-hi"
21+
hu = "aspose-hu"
22+
id = "aspose-id"
23+
it = "aspose-it"
24+
ja = "aspose-ja"
25+
ko = "aspose-ko"
26+
nl = "aspose-nl"
27+
pl = "aspose-pl"
28+
pt = "aspose-pt"
29+
sv = "aspose-sv"
30+
th = "aspose-th"
31+
tr = "aspose-tr"
32+
vi = "aspose-vi"
33+
zh-hant = "aspose-zht"
34+
35+
defaultContentLang = 'en'
36+
[languages]
37+
[languages.en]
38+
contentDir = 'content/english'
39+
languageName = 'English'
40+
languageCode = "en"
41+
flag = "flag-us"
42+
weight = 10
43+
[languages.ru]
44+
contentDir = 'content/russian'
45+
languageName = 'Русский'
46+
languageCode = "ru"
47+
flag = "flag-ru"
48+
weight = 11
49+
[languages.zh]
50+
contentDir = 'content/chinese'
51+
languageName = "简体中文"
52+
languageCode = "zh"
53+
flag = "flag-cn"
54+
weight = 12
55+
[languages.ar]
56+
contentDir = 'content/arabic'
57+
languageName = "عربي"
58+
languageCode = "ar"
59+
flag = "flag-sa"
60+
weight = 13
61+
[languages.fr]
62+
contentDir = 'content/french'
63+
languageName = "Français"
64+
languageCode = "fr"
65+
flag = "flag-fr"
66+
weight = 14
67+
[languages.de]
68+
contentDir = 'content/german'
69+
languageName = "Deutsch"
70+
languageCode = "de"
71+
flag = "flag-de"
72+
weight = 15
73+
[languages.it]
74+
contentDir = 'content/italian'
75+
languageName = "Italiano"
76+
languageCode = "it"
77+
flag = "flag-it"
78+
weight = 16
79+
[languages.es]
80+
contentDir = 'content/spanish'
81+
languageName = "Español"
82+
languageCode = "es"
83+
flag = "flag-es"
84+
weight = 17
85+
[languages.sv]
86+
contentDir = 'content/swedish'
87+
languageName = "Svenska"
88+
languageCode = "sv"
89+
flag = "flag-se"
90+
weight = 18
91+
[languages.tr]
92+
contentDir = 'content/turkish'
93+
languageName = "Türkçe"
94+
languageCode = "tr"
95+
flag = "flag-tr"
96+
weight = 19
97+
98+
ignoreFiles = ["(?i:readme.md)", '\.spin$']
99+
100+
# Image processing configuration.
101+
[imaging]
102+
resampleFilter = "CatmullRom"
103+
quality = 75
104+
anchor = "smart"
105+
106+
[services]
107+
[services.googleAnalytics]
108+
# Comment out the next line to disable GA tracking. Also disables the feature described in [params.ui.feedback].
109+
# id = "UA-00000000-0"
110+
111+
[markup]
112+
[markup.tableOfContents]
113+
endLevel = 2
114+
ordered = true
115+
startLevel = 2
116+
[markup.goldmark]
117+
[markup.goldmark.renderer]
118+
unsafe = true
119+
[markup.highlight]
120+
anchorLineNos = false
121+
codeFences = true
122+
guessSyntax = false
123+
hl_Lines = ""
124+
lineAnchors = ""
125+
lineNoStart = 1
126+
lineNos = false
127+
lineNumbersInTable = true
128+
noClasses = false
129+
tabWidth = 4
130+
131+
# Everything below this are Site Params
132+
133+
[params]
134+
copyright = "The Aspose Authors"
135+
privacy_policy = "https://policies.google.com/privacy"
136+
topbar_search_active = false
137+
logo_rel_link = ""
138+
139+
# Containerize Menu
140+
[params.containerize]
141+
menu = "aspose-en"
142+
143+
[params.meta]
144+
msapplication_TileColor = "#2b5797"
145+
msapplication_config = "https://cms.admin.containerize.com/templates/asposecloud/images/browserconfig.xml"
146+
theme_color = "#ffffff"
147+
author = "Aspose"
148+
149+
# Title of 404 page
150+
title_404_page = "404 - Page Not Found | Aspose API References"
151+
152+
# Open Grapgh settings
153+
title = "Aspose API References"
154+
images = ["images/Aspose-image-for-open-graph.jpg"]
155+
description = "Class Libraries & REST APIs for the developers to manipulate & process Files from Word, Excel, PowerPoint, Visio, PDF, CAD & several other categories in Web, Desktop or Mobile apps. Develop & deploy on Windows, Linux, MacOS & Android platforms."
156+
157+
# Specify a value here if your content directory is not in your repo's root directory
158+
# github_subdir = ""
159+
160+
# Google Custom Search Engine ID. Remove or comment out to disable search.
161+
# gcs_engine_id = "011737558837375720776:fsdu1nryfng"
162+
163+
# User interface configuration
164+
[params.ui]
165+
# Enable to show the side bar menu in its compact state.
166+
sidebar_menu_compact = true
167+
# Set to true to disable breadcrumb navigation.
168+
breadcrumb_disable = false
169+
# Set to true to hide the sidebar search box (the top nav search box will still be displayed if search is enabled)
170+
sidebar_search_disable = true
171+
# Set to false if you don't want to display a logo (/assets/icons/logo.svg) in the top nav bar
172+
navbar_logo = false
173+
# Set to true to disable the About link in the site footer
174+
footer_about_disable = false
175+
176+
177+
[minify]
178+
disableCSS = false
179+
disableHTML = false
180+
disableJS = false
181+
disableJSON = false
182+
disableSVG = false
183+
disableXML = false
184+
minifyOutput = true
185+
[minify.tdewolff]
186+
[minify.tdewolff.css]
187+
decimals = -1
188+
keepCSS2 = true
189+
[minify.tdewolff.html]
190+
keepConditionalComments = true
191+
keepDefaultAttrVals = true
192+
keepDocumentTags = true
193+
keepEndTags = true
194+
keepQuotes = false
195+
keepWhitespace = false
196+
[minify.tdewolff.js]
197+
[minify.tdewolff.json]
198+
[minify.tdewolff.svg]
199+
decimals = -1
200+
[minify.tdewolff.xml]
201+
keepWhitespace = false
202+
203+
[Taxonomies]
204+
205+
[deployment]
206+
[[deployment.matchers]]
207+
# Set custom content type for /sitemap.xml
208+
#pattern = "^sitemap\\.xml$"
209+
#pattern = "^[a-z]\\.xml$"
210+
pattern = "^.+\\.(xml)$"
211+
contentType = "application/xml"
212+
gzip = true
213+
force = true

config/html/production/config.toml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
baseURL = "https://reference.aspose.com/tutorials/html"
2+
3+
# Google Tag Manager settings
4+
[params.gtm]
5+
gtm_id = "GTM-NJMHSH"
6+
7+
[[deployment.targets]]
8+
name = "Production"
9+
URL = "s3://reference.aspose.com/?prefix=tutorials/html/&region=us-west-2"

config/html/staging/config.toml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
baseURL = "https://reference2.aspose.com/tutorials/html"
2+
3+
[[deployment.targets]]
4+
name = "Stage"
5+
URL = "s3://reference2.aspose.com/?prefix=tutorials/html/&region=us-west-2"
6+
7+
8+

layouts/404.html

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{{ define "main"}}
2+
<main id="main">
3+
<div class="error404">
4+
<div class="content404">
5+
<h4>Page Not Found</h4>
6+
<h2>404</h2>
7+
<p>The page you are looking for does not exist</p>
8+
<span><a href="javascript:history.go(-1)" class="backButton">Go Back</a> <a href='{{ "/" | relURL }}'>Home Page</a> </span>
9+
</div>
10+
</div>
11+
</main>
12+
{{ end }}

0 commit comments

Comments
 (0)