https://github.com/jabolol/apricot
Simple Socket.io demo written in C++
https://github.com/jabolol/apricot
echo-server socket-io websocket
Last synced: 14 days ago
JSON representation
Simple Socket.io demo written in C++
- Host: GitHub
- URL: https://github.com/jabolol/apricot
- Owner: Jabolol
- License: mit
- Created: 2024-01-14T22:16:31.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-21T18:38:15.000Z (over 2 years ago)
- Last Synced: 2025-01-26T11:15:00.055Z (over 1 year ago)
- Topics: echo-server, socket-io, websocket
- Language: C++
- Homepage:
- Size: 13.7 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# apricot
Simple **Socket.io** demo written in `C++`. Its aim is to provide a simple
working example of how to use the **Socket.io** library in a `C++` project,
using git `submodules` to manage dependencies and `CMake` as the build system.
```
apricot :: echo server
type 'exit' to quit
-----------------------------------
hello world!
<< hello world!
whoami
<< aiW_1pW3z1nVphxDAAAD
cowsay
<<
______
< Moo! >
------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||
exit
-----------------------------------
```
## getting started
To get started with the demo, follow these steps:
1. Clone the repository with submodules recursively:
```bash
git clone --recurse-submodules https://github.com/Jabolol/apricot.git .
```
2. Create a build directory and navigate into it:
```bash
mkdir build
cd build
```
3. Generate the build files using CMake:
```bash
cmake ..
```
4. Initialize the server by running the following command in one terminal:
```bash
deno run -A www/main.ts
```
5. In another terminal, run the compiled Apricot executable:
```bash
./apricot
```
6. Type `help` to see a list of available commands.
## contributing
Contributions are welcome! If you find any issues or have suggestions for
improvements, please open an issue or submit a pull request.
## license
This project is licensed under the [MIT License](LICENSE).