Skip to content

Commit 4b44f6e

Browse files
Your NameAlloyed
authored andcommitted
ci
1 parent 0eff976 commit 4b44f6e

File tree

6 files changed

+38
-9
lines changed

6 files changed

+38
-9
lines changed

.github/workflows/build-apps.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
extra-flags:
3939
- name: Windows-sentry
4040
os: windows-2025
41-
extra-flags: -DKITSBLIPS_ENABLE_SENTRY="ON"
41+
extra-flags: -DKITSBLIPS_ENABLE_SENTRY="ON" -DKITSBLIPS_RETAIL="ON"
4242

4343
steps:
4444
- name: Set up Linux deps
@@ -55,6 +55,7 @@ jobs:
5555
- uses: ./.github/actions/cmake
5656
env:
5757
KITSBLIPS_SENTRY_DSN: ${{ secrets.KITSBLIPS_SENTRY_DSN }}
58+
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
5859
with:
5960
source: ${{github.workspace}}/daw
6061
build: ${{github.workspace}}/build

daw/src/entry.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,12 +48,12 @@ bool initSentry(const char* path) {
4848
sentry_options_set_dsn(opts, KITSBLIPS_SENTRY_DSN);
4949
sentry_options_set_release(opts, PRODUCT_ID "@" PRODUCT_VERSION);
5050
sentry_options_set_debug(opts, 1);
51+
sentry_options_set_enable_logs(opts, 1);
5152

5253
auto pluginPath = std::filesystem::path(path);
5354
auto dbPath = getSentryDbPath(PRODUCT_NAME).generic_string();
5455
#if _WIN32
55-
auto crashpadPath =
56-
std::filesystem::absolute(pluginPath.parent_path() / "./crashpad_handler.exe").generic_string();
56+
auto crashpadPath = std::filesystem::absolute(pluginPath.parent_path() / "./crashpad_handler.exe").generic_string();
5757
#else
5858
auto crashpadPath = std::filesystem::absolute(pluginPath.parent_path() / "./crashpad_handler").generic_string();
5959
#endif
@@ -67,7 +67,7 @@ bool initSentry(const char* path) {
6767
extern "C" const clap_plugin_entry_t clap_entry = (clap_plugin_entry_t{
6868
CLAP_VERSION_INIT,
6969
[](const char* path) -> bool {
70-
if(!initSentry(path)) {
70+
if (!initSentry(path)) {
7171
return false;
7272
}
7373
return clapeze::EntryPoint::_init(path);

daw/src/kitskeys/kitskeys.cpp

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#include <kitdsp/osc/blepOscillator.h>
1515
#include <memory>
1616

17+
#include "clapeze/pluginHost.h"
1718
#include "descriptor.h"
1819
#include "kitdsp/filters/onePole.h"
1920
#include "kitdsp/math/util.h"
@@ -28,6 +29,10 @@
2829
#include "kitgui/gfx/scene.h"
2930
#endif
3031

32+
#if KITSBLIPS_ENABLE_SENTRY
33+
#include <sentry.h>
34+
#endif
35+
3136
namespace {
3237
enum class Params : clap_id {
3338
OscOctave,
@@ -598,6 +603,28 @@ class Plugin : public InstrumentPlugin {
598603

599604
protected:
600605
void Config() override {
606+
#if KITSBLIPS_ENABLE_SENTRY
607+
GetHost().SetLogFn([](clapeze::LogSeverity severity, const std::string& message) {
608+
switch (severity) {
609+
case LogSeverity::Debug:
610+
sentry_log_debug(message.c_str());
611+
break;
612+
case LogSeverity::Info:
613+
sentry_log_info(message.c_str());
614+
break;
615+
case LogSeverity::Warning:
616+
sentry_log_warn(message.c_str());
617+
break;
618+
case LogSeverity::Error:
619+
sentry_log_error(message.c_str());
620+
break;
621+
case LogSeverity::Fatal:
622+
sentry_log_fatal(message.c_str());
623+
break;
624+
}
625+
});
626+
#endif
627+
601628
InstrumentPlugin::Config();
602629

603630
ParamsFeature& params = ConfigFeature<ParamsFeature>(GetHost(), Params::Count)
@@ -630,14 +657,14 @@ class Plugin : public InstrumentPlugin {
630657
.Parameter<Params::VcaLfoAmount>();
631658
ConfigFeature<clapeze::TomlStateFeature<ParamsFeature>>();
632659
// ConfigFeature<clapeze::NoopStateFeature<ParamsFeature>>();
660+
633661
#if KITSBLIPS_ENABLE_GUI
634662
ConfigFeature<clapeze::AssetsFeature>(GetHost());
635663
// aspect ratio 1.5
636664
kitgui::SizeConfig cfg{750, 500, false, true};
637665
ConfigFeature<KitguiFeature>(
638666
GetHost(), [&params](kitgui::Context& ctx) { return std::make_unique<GuiApp>(ctx, params); }, cfg);
639667
#endif
640-
641668
ConfigProcessor<Processor>(params.GetProcessorHandle());
642669
}
643670
};

kitdsp/include/kitdsp/math/util.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
#include <cmath>
44
#include <cstdint>
55
#include <cstring>
6+
#include <memory>
67
#include "kitdsp/macros.h"
78

89
namespace kitdsp {

kitgui/src/impl/sdl/contextImpl.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
#include "kitgui/kitgui.h"
2020
#include "log.h"
2121

22-
#define LOG_SDL_ERROR_STATIC(ctx) do kitgui::log::defaultLogger(ctx, SDL_GetError())
23-
#define LOG_SDL_ERROR(ctx) kitgui::log::error(ctx, SDL_GetError())
22+
#define LOG_SDL_ERROR_STATIC(ctx) do {kitgui::log::defaultLogger(SDL_GetError());} while(0)
23+
#define LOG_SDL_ERROR(ctx) do{kitgui::log::error(ctx, SDL_GetError());} while(0)
2424

2525
// linux-specific platform details
2626
#ifdef __linux__
@@ -111,7 +111,7 @@ void checkSupportedApis_(bool& outHasX11, bool& outHasWayland) {
111111
hasWayland = true;
112112
}
113113
}
114-
kitgui::log::info(fmt::format("Checking supported video drivers. x11: {}, wayland: {}", hasX11, hasWayland));
114+
//kitgui::log::info(fmt::format("Checking supported video drivers. x11: {}, wayland: {}", hasX11, hasWayland));
115115
hasChecked = true;
116116
}
117117
outHasX11 = hasX11;
@@ -353,7 +353,7 @@ bool ContextImpl::GetSizeInPixels(uint32_t& widthOut, uint32_t& heightOut) const
353353
return success;
354354
}
355355
bool ContextImpl::SetSizeDirectly(uint32_t width, uint32_t height, bool resizable) {
356-
kitgui::log::TimeRegion r("ContextImpl::SetSizeDirectly()");
356+
kitgui::log::TimeRegion r(mContext, "ContextImpl::SetSizeDirectly()");
357357
if (!SDL_SetWindowResizable(mWindow, resizable)) {
358358
LOG_SDL_ERROR(mContext);
359359
return false;

sdk/sentry-cli/sentry-cli-Linux-x86_64

100644100755
File mode changed.

0 commit comments

Comments
 (0)