]> Softwares of Agnibho - statin.git/blob - README
Bumped version to 1.1
[statin.git] / README
1 Statin
2 ======
3
4 What is Statin?
5 ================
6
7 Statin is a python command line utility to generate static html websites. It
8 implements SSI (Server Side Inclusion) commands to generate the static files for
9 deployment.
10
11 Installation
12 ============
13
14 Download the package distribution and install it to your computer. You can
15 install the package with pip by running 'pip install statin.tar.gz'. You may
16 require superuser persmission to install the package. Alternatively you can
17 clone the repository to your computer and exucute the script named 'run'.
18
19 You need to have Python 3 installed in order to use the script.
20
21 Usage
22 =====
23
24 Create your website in html. The files containing SSI directives should have the
25 extension ".shtml", ".shtm", or ".sht". After creating the website change
26 directory to the document root of the site and run the script. By default the
27 static site will be generated in a subdirectory named statin-output.
28
29 A number of command line options are also available.
30
31 positional arguments:
32 files List of files to be processed
33
34 optional arguments:
35 -h, --help show this help message and exit
36 -q, --quiet Suppress text output to console
37 -v, --verbose Verbose text output to console
38 -s, --safe Disable python eval of strings
39 -r, --recursive Process files recursively
40 -l LEVEL, --level LEVEL
41 Maximum recursion level
42 -p PATTERN, --pattern PATTERN
43 Filename patterns to be processed
44 -o OUTPUT, --output OUTPUT
45 Specify the output directory
46
47 Supported Directives
48 ====================
49
50 A directive is written as <!--#directive parameter="value" -->
51
52 The supported directives and parameters are listed below:
53
54 Directives | Parameters
55 -----------|---------------------------
56 include | file / virtual
57 exec | cgi / cmd
58 echo | var
59 config | timefmt / sizefmt / errmsg
60 flastmod | file / virtual
61 fsize | file / virtual
62 printenv | (none)
63 if | expr
64 elif | expr
65 else | (none)
66 endif | (none)
67 set | var & value
68
69 Defualt Variables
70 =================
71
72 DATE_LOCAL
73 DATE_GMT
74 DOCUMENT_URI
75 DOCUMENT_NAME
76 LAST_MODIFIED
77
78 Configuration
79 =============
80
81 The default configuration is stored in the file conf.py. Available configuration
82 options are:
83
84 OUTPUT_DIR : The directory where the statin output files will be saved.
85 PROCESS_PAT : The filename extensions recognized by statin for processing.
86 TIMEFMT : The default time format.
87 SIZEFMT : The default size format.
88 ERRMSG : The default error message.
89
90 Licensing
91 =========
92
93 Copyright (c) 2018 Agnibho Mondal
94 All rights reserved
95
96 This file is part of Statin.
97
98 Statin is free software: you can redistribute it and/or modify
99 it under the terms of the GNU General Public License as published by
100 the Free Software Foundation, either version 3 of the License, or
101 (at your option) any later version.
102
103 Statin is distributed in the hope that it will be useful,
104 but WITHOUT ANY WARRANTY; without even the implied warranty of
105 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
106 GNU General Public License for more details.
107
108 You should have received a copy of the GNU General Public License
109 along with Statin. If not, see <http://www.gnu.org/licenses/>.
110
111 Contacts
112 ========
113
114 Agnibho Mondal
115 contact@agnibho.com
116 www.agnibho.com