Skip to content

Commit 40f7ef0

Browse files
committed
Change namespace; chane include folder structure; bump version to 1.0.0.1
1 parent f2f650e commit 40f7ef0

29 files changed

+150
-109
lines changed

.github/workflow/ci.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
branches: [ main ]
8+
9+
permissions:
10+
contents: read
11+
12+
jobs:
13+
build-and-test:
14+
strategy:
15+
matrix:
16+
os: [ubuntu-latest, windows-latest, macos-latest]
17+
build_type: [Release, Debug]
18+
19+
runs-on: ${{ matrix.os }}
20+
21+
steps:
22+
- uses: actions/checkout@v4
23+
24+
- name: Configure CMake
25+
run: cmake -B build -DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
26+
27+
- name: Build
28+
run: cmake --build build --config ${{ matrix.build_type }}
29+
30+
- name: Run Tests
31+
working-directory: build
32+
run: ctest -C ${{ matrix.build_type }} --output-on-failure

CHANGELOG

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,7 @@
1-
v1.0.0.0 - [09/26/2025]
1+
#v1.0.0.1 - [10/21/2025]
2+
- Change include folder structure from include/slick_socket/ to include/slick/
3+
- Change namespace from slick_socket to slick::socket
4+
- Add GitHub CI workflow
5+
6+
#1.0.0.0 - [09/26/2025]
27
- Initial Release

CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ set(CMAKE_CXX_STANDARD 20)
44
set(CMAKE_CXX_STANDARD_REQUIRED ON)
55
set(CMAKE_CXX_EXTENSIONS OFF)
66

7-
set(BUILD_VERSION 1.0.0.0)
7+
set(BUILD_VERSION 1.0.0.1)
88
project(slick_socket VERSION ${BUILD_VERSION} LANGUAGES C CXX)
99

1010
if (NOT CMAKE_BUILD_TYPE)
@@ -38,8 +38,8 @@ if(ENABLE_ASAN)
3838
endif()
3939
else()
4040
# GCC/Clang AddressSanitizer
41-
add_compile_options(-fsanitize=address -fno-omit-frame-pointer)
42-
add_link_options(-fsanitize=address)
41+
add_compile_options(-fsanitize=address,undefined -fno-omit-frame-pointer)
42+
add_link_options(-fsanitize=address,undefined)
4343
endif()
4444
endif()
4545

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# slick_socket
22

3+
[![C++20](https://img.shields.io/badge/C%2B%2B-20-blue.svg)](https://en.cppreference.com/w/cpp/20)
4+
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
5+
[![CI](https://github.com/SlickQuant/slick_socket/actions/workflows/ci.yml/badge.svg)](https://github.com/SlickQuant/slick_socket/actions/workflows/ci.yml)
6+
[![GitHub release](https://img.shields.io/github/v/release/SlickQuant/slick_socket)](https://github.com/SlickQuant/slick_socket/releases)
7+
38
A header-only C++20 networking library providing cross-platform TCP and UDP multicast communication.
49

510
## Features

examples/multicast_integration_example.cpp

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
#include "logger.h"
2-
#include <slick_socket/multicast_sender.h>
3-
#include <slick_socket/multicast_receiver.h>
2+
#include <slick/socket/multicast_sender.h>
3+
#include <slick/socket/multicast_receiver.h>
44
#include <iostream>
55
#include <string>
66
#include <thread>
77
#include <chrono>
88
#include <atomic>
99

10-
class MulticastReceiver : public slick_socket::MulticastReceiverBase<MulticastReceiver>
10+
class MulticastReceiver : public slick::socket::MulticastReceiverBase<MulticastReceiver>
1111
{
1212
public:
13-
MulticastReceiver(const slick_socket::MulticastReceiverConfig& config)
14-
: slick_socket::MulticastReceiverBase<MulticastReceiver>("IntegrationReceiver", config)
13+
MulticastReceiver(const slick::socket::MulticastReceiverConfig& config)
14+
: slick::socket::MulticastReceiverBase<MulticastReceiver>("IntegrationReceiver", config)
1515
{
1616
}
1717

@@ -25,11 +25,11 @@ class MulticastReceiver : public slick_socket::MulticastReceiverBase<MulticastRe
2525
std::atomic<int> messages_received_{0};
2626
};
2727

28-
class MulticastSender : public slick_socket::MulticastSenderBase<MulticastSender>
28+
class MulticastSender : public slick::socket::MulticastSenderBase<MulticastSender>
2929
{
3030
public:
31-
MulticastSender(const slick_socket::MulticastSenderConfig& config)
32-
: slick_socket::MulticastSenderBase<MulticastSender>("IntegrationSender", config)
31+
MulticastSender(const slick::socket::MulticastSenderConfig& config)
32+
: slick::socket::MulticastSenderBase<MulticastSender>("IntegrationSender", config)
3333
{
3434
}
3535
};
@@ -44,14 +44,14 @@ int main()
4444
const uint16_t port = 12347;
4545

4646
// Setup receiver
47-
slick_socket::MulticastReceiverConfig receiver_config;
47+
slick::socket::MulticastReceiverConfig receiver_config;
4848
receiver_config.multicast_address = multicast_address;
4949
receiver_config.port = port;
5050
receiver_config.reuse_address = true;
5151
receiver_config.receive_timeout = std::chrono::milliseconds(1000);
5252

5353
// Setup sender
54-
slick_socket::MulticastSenderConfig sender_config;
54+
slick::socket::MulticastSenderConfig sender_config;
5555
sender_config.multicast_address = multicast_address;
5656
sender_config.port = port;
5757
sender_config.ttl = 1; // Local network only

examples/multicast_receiver_example.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
#include "logger.h"
2-
#include <slick_socket/multicast_receiver.h>
2+
#include <slick/socket/multicast_receiver.h>
33
#include <iostream>
44
#include <string>
55
#include <thread>
66
#include <chrono>
77
#include <atomic>
88

9-
class MulticastReceiver : public slick_socket::MulticastReceiverBase<MulticastReceiver>
9+
class MulticastReceiver : public slick::socket::MulticastReceiverBase<MulticastReceiver>
1010
{
1111
public:
12-
MulticastReceiver(const slick_socket::MulticastReceiverConfig& config)
13-
: slick_socket::MulticastReceiverBase<MulticastReceiver>("MulticastReceiver", config)
12+
MulticastReceiver(const slick::socket::MulticastReceiverConfig& config)
13+
: slick::socket::MulticastReceiverBase<MulticastReceiver>("MulticastReceiver", config)
1414
{
1515
}
1616

@@ -28,7 +28,7 @@ class MulticastReceiver : public slick_socket::MulticastReceiverBase<MulticastRe
2828

2929
int main()
3030
{
31-
slick_socket::MulticastReceiverConfig config;
31+
slick::socket::MulticastReceiverConfig config;
3232
config.multicast_address = "224.0.0.100"; // Same as sender example
3333
config.port = 12345;
3434
config.reuse_address = true; // Allow multiple receivers

examples/multicast_sender_example.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
#include "logger.h"
2-
#include <slick_socket/multicast_sender.h>
2+
#include <slick/socket/multicast_sender.h>
33
#include <iostream>
44
#include <string>
55
#include <thread>
66
#include <chrono>
77

8-
class MulticastSender : public slick_socket::MulticastSenderBase<MulticastSender>
8+
class MulticastSender : public slick::socket::MulticastSenderBase<MulticastSender>
99
{
1010
public:
11-
MulticastSender(const slick_socket::MulticastSenderConfig& config)
12-
: slick_socket::MulticastSenderBase<MulticastSender>("MulticastSender", config)
11+
MulticastSender(const slick::socket::MulticastSenderConfig& config)
12+
: slick::socket::MulticastSenderBase<MulticastSender>("MulticastSender", config)
1313
{
1414
}
1515
};
1616

1717
int main()
1818
{
19-
slick_socket::MulticastSenderConfig config;
19+
slick::socket::MulticastSenderConfig config;
2020
config.multicast_address = "224.0.0.100"; // Test multicast address
2121
config.port = 12345;
2222
config.ttl = 1; // Local network only

examples/tcp_client_example.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#include "logger.h"
2-
#include <slick_socket/tcp_client.h>
2+
#include <slick/socket/tcp_client.h>
33
#include <iostream>
44
#include <string>
55
#include <thread>
@@ -9,11 +9,11 @@ namespace {
99
std::atomic_bool data_received_{false};
1010
}
1111

12-
class TCPClient : public slick_socket::TCPClientBase<TCPClient>
12+
class TCPClient : public slick::socket::TCPClientBase<TCPClient>
1313
{
1414
public:
15-
TCPClient(const slick_socket::TCPClientConfig& config)
16-
: slick_socket::TCPClientBase<TCPClient>("Tcp Client", config)
15+
TCPClient(const slick::socket::TCPClientConfig& config)
16+
: slick::socket::TCPClientBase<TCPClient>("Tcp Client", config)
1717
{
1818
}
1919

@@ -37,7 +37,7 @@ class TCPClient : public slick_socket::TCPClientBase<TCPClient>
3737

3838
int main()
3939
{
40-
slick_socket::TCPClientConfig config;
40+
slick::socket::TCPClientConfig config;
4141
config.server_address = "127.0.0.1"; // Server address
4242
config.server_port = 9090; // Server port (should match server example)
4343
config.receive_buffer_size = 4096;

examples/tcp_server_example.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
#include "logger.h"
2-
#include <slick_socket/tcp_server.h>
2+
#include <slick/socket/tcp_server.h>
33
#include <iostream>
44
#include <string>
55

6-
class TCPServer : public slick_socket::TCPServerBase<TCPServer>
6+
class TCPServer : public slick::socket::TCPServerBase<TCPServer>
77
{
88
public:
9-
TCPServer(const slick_socket::TCPServerConfig& config)
10-
: slick_socket::TCPServerBase<TCPServer>("Echo TCP Server", config)
9+
TCPServer(const slick::socket::TCPServerConfig& config)
10+
: slick::socket::TCPServerBase<TCPServer>("Echo TCP Server", config)
1111
{
1212
}
1313

@@ -31,7 +31,7 @@ class TCPServer : public slick_socket::TCPServerBase<TCPServer>
3131

3232
int main()
3333
{
34-
slick_socket::TCPServerConfig config;
34+
slick::socket::TCPServerConfig config;
3535
config.port = 9090; // Set custom port if needed
3636
config.max_connections = 50; // Set max connections
3737
config.receive_buffer_size = 8192; // Set receive buffer size

0 commit comments

Comments
 (0)