packaging

This commit is contained in:
Udo 2022-02-11 02:35:06 +00:00
parent 6f6919f3f0
commit defc628204
7 changed files with 59 additions and 7 deletions

BIN
dist/uce_0.1.1.deb vendored

Binary file not shown.

10
doc/pages/float_val.txt Normal file
View File

@ -0,0 +1,10 @@
:sig
f64 float_val(String s)
:params
s : string to be converted
return value : a f64 containing the number (0 if no number could be identified).
:desc
Extracts a floating point number from a String.

View File

@ -0,0 +1,15 @@
[Unit]
Description=UCE FastCGI Server
Wants=network.target
After=syslog.target network-online.target
[Service]
Type=simple
ExecStart=/opt/uce/bin/uce_fastcgi.linux.bin
Restart=on-failure
RestartSec=10
KillMode=mixed
[Install]
WantedBy=multi-user.target

20
etc/uce/settings.cfg Normal file
View File

@ -0,0 +1,20 @@
# UCE WORKING DIRECTORIES
BIN_DIRECTORY=/tmp/uce/work
TMP_UPLOAD_PATH=/tmp/uce/uploads
SESSION_PATH=/tmp/uce/sessions
# LISTEN ON SOCKETS
SOCKET_PATH=/run/uce.sock
LISTEN_PORT=9993
# PRECOMPILE .uce FILES
PRECOMPILE_FILES_IN=
# SPAWN WORKERS
WORKER_COUNT=4
# MAX MEMORY PER REQUEST
MAX_MEMORY=16777216
# LIFETIME OF SESSION COOKIES IN SECONDS
SESSION_TIME=2592000

View File

@ -29,11 +29,12 @@ cp scripts/control "pkg/$PKG_NAME/DEBIAN/"
echo "Version: $VERSION" >> "pkg/$PKG_NAME/DEBIAN/control"
echo "" >> "pkg/$PKG_NAME/DEBIAN/control"
cp -r bin "pkg/$PKG_NAME/opt/"
cp -r doc "pkg/$PKG_NAME/opt/"
cp -r examples "pkg/$PKG_NAME/opt/"
cp -r scripts "pkg/$PKG_NAME/opt/"
cp -r test "pkg/$PKG_NAME/opt/"
cp -r bin "pkg/$PKG_NAME/opt/uce/"
cp -r doc "pkg/$PKG_NAME/opt/uce/"
cp -r examples "pkg/$PKG_NAME/opt/uce/"
cp -r scripts "pkg/$PKG_NAME/opt/uce/"
cp -r test "pkg/$PKG_NAME/opt/uce/"
cp -r etc "pkg/$PKG_NAME/"
du -sh "pkg/$PKG_NAME/"*

View File

@ -150,7 +150,7 @@ StringMap split_kv(String s, char separator, bool trim_whitespace)
u8 mode = 0;
k = "";
v = "";
for(auto c : s)
if(s[0] != '#') for(auto c : s)
{
if(mode == 0)
{
@ -309,7 +309,12 @@ String html_escape(f64 a)
u64 int_val(String s, u32 base)
{
return(strtoll(s.c_str(), 0, base));
return(strtol(s.c_str(), 0, base));
}
f64 float_val(String s)
{
return(strtod(s.c_str(), 0));
}
String nibble(String& haystack, String delim)

View File

@ -2,6 +2,7 @@
u8 char_to_u8(char input);
u8 hex_to_u8(String src);
u64 int_val(String s, u32 base = 10);
f64 float_val(String s);
String to_lower(String s);
String to_upper(String s);
String replace(String s, String search, String replace_with);