1
0
Fork 0
forked from fun/fun

Renamed ./examples/external to ./examples/extensions. No code changes. (0.40.6)

This commit is contained in:
Johannes Findeisen 2026-04-27 01:20:38 +02:00
commit c68244d6f6
32 changed files with 40 additions and 41 deletions

View file

@ -54,41 +54,41 @@ jobs:
- name: Run Examples (crypto)
run: ./scripts/run_examples.sh crypto
#- name: Run Examples (external/curl)
# run: ./scripts/run_examples.sh external/curl
#- name: Run Examples (extensions/curl)
# run: ./scripts/run_examples.sh extensions/curl
#- name: Run Examples (external/ini)
# run: ./scripts/run_examples.sh external/ini
#- name: Run Examples (extensions/ini)
# run: ./scripts/run_examples.sh extensions/ini
- name: Run Examples (external/json)
run: ./scripts/run_examples.sh external/json
- name: Run Examples (extensions/json)
run: ./scripts/run_examples.sh extensions/json
#- name: Run Examples (external/libressl)
# run: ./scripts/run_examples.sh external/libressl
#- name: Run Examples (extensions/libressl)
# run: ./scripts/run_examples.sh extensions/libressl
#- name: Run Examples (external/libsql)
# run: ./scripts/run_examples.sh external/libsql
#- name: Run Examples (extensions/libsql)
# run: ./scripts/run_examples.sh extensions/libsql
#- name: Run Examples (external/notcurses)
# run: ./scripts/run_examples.sh external/notcurses
#- name: Run Examples (extensions/notcurses)
# run: ./scripts/run_examples.sh extensions/notcurses
- name: Run Examples (external/openssl)
run: ./scripts/run_examples.sh external/openssl
- name: Run Examples (extensions/openssl)
run: ./scripts/run_examples.sh extensions/openssl
#- name: Run Examples (external/pcre2)
# run: ./scripts/run_examples.sh external/pcre2
#- name: Run Examples (extensions/pcre2)
# run: ./scripts/run_examples.sh extensions/pcre2
#- name: Run Examples (external/pcsc)
# run: ./scripts/run_examples.sh external/pcsc
#- name: Run Examples (extensions/pcsc)
# run: ./scripts/run_examples.sh extensions/pcsc
#- name: Run Examples (external/sqlite)
# run: ./scripts/run_examples.sh external/sqlite
#- name: Run Examples (extensions/sqlite)
# run: ./scripts/run_examples.sh extensions/sqlite
#- name: Run Examples (external/tcltk)
# run: ./scripts/run_examples.sh external/tcltk
#- name: Run Examples (extensions/tcltk)
# run: ./scripts/run_examples.sh extensions/tcltk
#- name: Run Examples (external/xml2)
# run: ./scripts/run_examples.sh external/xml2
#- name: Run Examples (extensions/xml2)
# run: ./scripts/run_examples.sh extensions/xml2
- name: Run Examples (functions)
run: ./scripts/run_examples.sh functions

View file

@ -89,14 +89,14 @@ See [./lib/](https://git.xw3.org/fun/fun/src/branch/main/lib) for what the stand
### Optional extensions (build-time selectable / only testing this on Linux actually):
- [CGI](https://en.wikipedia.org/wiki/Common_Gateway_Interface) support builtin using [kcgi](https://kristaps.bsd.lv/kcgi/) (optional) ☐
- [cURL (libcurl)](./docs/extensions/curl.md) (optional) ☑
- [INI (iniparser)](./docs/extensions/ini.md) (optional) ☑
- [JSON (json-c)](./docs/extensions/json.md) (optional) ☑
- [PCRE2](./docs/extensions/pcre2.md) (optional) ☑
- [PCSC (smart cards)](./docs/extensions/pcsc.md) (optional) ☑
- [OpenSSL](./docs/extensions/openssl.md) (optional) ☑
- [SQLite](./docs/extensions/sqlite.md) (optional) ☑
- [XML (libxml2)](./docs/extensions/xml2.md) (optional) ☑
- [cURL (libcurl)](./web/documentation/extensions/curl/curl.md) (optional) ☑
- [INI (iniparser)](./web/documentation/extensions/ini/ini.md) (optional) ☑
- [JSON (json-c)](./web/documentation/extensions/json/json.md) (optional) ☑
- [PCRE2](./web/documentation/extensions/pcre2/pcre2.md) (optional) ☑
- [PCSC (smart cards)](./web/documentation/extensions/pcsc/pcsc.md) (optional) ☑
- [OpenSSL](./web/documentation/extensions/openssl/openssl.md) (optional) ☑
- [SQLite](./web/documentation/extensions/sqlite/sqlite.md) (optional) ☑
- [XML (libxml2)](./web/documentation/extensions/xml2/xml2.md) (optional) ☑
☑ = Done (or basics implemented) / ☐ = Planned or in progress.

View file

@ -19,13 +19,13 @@ Create a sample database
Run the server
- Set FUN_LIB_DIR to the repos lib directory or install Fun libs system-wide
- Example (Debug profile path may differ):
FUN_LIB_DIR="$(pwd)/lib" ./build/fun ./examples/sqlited/server.fun 127.0.0.1 5555
FUN_LIB_DIR="$(pwd)/lib" ./build/fun ./examples/extensions/sqlite/sqlited/server.fun 127.0.0.1 5555
Run the client
- Query:
FUN_LIB_DIR="$(pwd)/lib" ./build/fun ./examples/sqlited/client.fun 127.0.0.1 5555 "SELECT id, title FROM tasks;"
FUN_LIB_DIR="$(pwd)/lib" ./build/fun ./examples/extensions/sqlite/sqlited/client.fun 127.0.0.1 5555 "SELECT id, title FROM tasks;"
- Exec/DDL:
FUN_LIB_DIR="$(pwd)/lib" ./build/fun ./examples/sqlited/client.fun 127.0.0.1 5555 "UPDATE tasks SET done=1 WHERE id=1;"
FUN_LIB_DIR="$(pwd)/lib" ./build/fun ./examples/extensions/sqlite/sqlited/client.fun 127.0.0.1 5555 "UPDATE tasks SET done=1 WHERE id=1;"
Protocol summary
- Client sends one line with SQL ended by a newline (\n)

View file

@ -18,7 +18,6 @@ tags:
- examples
- extension
- extensions
- extensions
- integrations
- optional
- required

View file

@ -408,7 +408,7 @@ UnixClient:
- connect(path), is_connected(), send(data), recv(maxlen), close()
Examples: tcp_http_get.fun, tcp_http_get_class.fun, unix_socket_echo.fun, extra/tcp_echo_server_class.fun
Examples: tcp_http_get.fun, tcp_http_get_class.fun, unix_socket_echo.fun, blocking/tcp_echo_server_class.fun
### io.thread
@ -711,13 +711,13 @@ Highlights (not exhaustive):
- if_else_test.fun — branching
- include_lib.fun, include_local.fun, include_namespace.fun — includes and namespacing
- interactive/input_example.fun — console input
- extra/json_showcase.fun — JSON usage
- extra/curl_get_json.fun, extra/curl_post.fun, extra/curl_download.fun — HTTP via CURL
- extensions/json_showcase.fun — JSON usage
- extensions/curl_get_json.fun, extensions/curl_post.fun, extensions/curl_download.fun — HTTP via CURL
- loops_break_continue.fun, nested_loops.fun, while_test.fun — loops
- crypto/md5_demo.fun, crypto/sha1_demo.fun, crypto/sha256_demo.fun, crypto/sha256_str_demo.fun, crypto/sha384_example.fun, crypto/sha512_demo.fun, crypto/sha512_str_demo.fun — hashing
- objects_basic.fun, objects_more.fun — map/object patterns
- os_env.fun — environment variables
- extra/pcsc_example.fun — smart card demo
- extensions/pcsc_example.fun — smart card demo
- process_example.fun — running external commands
- regex_demo.fun, regex_procedural.fun — regex usage
- stdlib_showcase.fun — tour through stdlib
@ -729,7 +729,7 @@ Highlights (not exhaustive):
- type_safety.fun, type_safety_fails.fun — type safety
- types_integers.fun, signed_ints.fun, uint_types.fun — integers
- unix_socket_echo.fun — UNIX domain sockets
- extra/sqlite_example.fun — SQLite usage
- extensions/sqlite_example.fun — SQLite usage
Notes: